Update error message for missing sub mapping properties
[sdc.git] / docs / externaltesting.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. http://creativecommons.org/licenses/by/4.0
3
4 =======================================================
5 Externalized Testing & VTP Certifications Query Feature
6 =======================================================
7
8 The Certifications Query and VTP (External to SDC) testing
9 feature was added to Dublin to allow SDC onboarding to reach
10 outside of SDC for testing of VSPs being onboarded.
11
12 These tests include queries for existing certification
13 results for prior versions of the VSP and testing of
14 CSAR or HEAT metadata via tests in or downstream of VTP.
15 The design includes the ability to configure (see configuration below)
16 multiple endpoints that SDC onboarding reaches out to for
17 external testing.
18
19 This diagram presents the architecture to be achieved in Dublin
20 or a future release given the resources available.
21
22 .. image:: images/sdc-vtp-opnfv.png
23
24 New and Impacted Code
25 =====================
26
27 The new code for this feature follows the software design
28 of the existing onboarding BE. New code is isolated into two
29 new subprojects contained within openecomp-be within minimal hooks
30 elsewhere.
31
32 *New code*:
33
34 Code that creates an HTTP endpoint exposed to the SDC-FE for this feature is contained
35 in this package:
36   
37   package: api/openecomp-sdc-rest-webapp/externaltesting-rest/externaltesting-rest-services
38   
39 Code to hold data types for the VTP API and the implementation of the interface to VTP is contained
40 in these packages:
41
42 Provide the API and serialisation classes for the REST API to VTP
43
44   package: lib/openecomp-sdc-externaltesting-lib/openecomp-sdc-externaltesting-api
45   
46 Implementation of the interface to VTP and Registry that are available for the HTTP endpoint above.
47
48   package: lib/openecomp-sdc-externaltesting-lib/openecomp-sdc-externaltesting-impl
49
50 *Updated Code*:
51
52 To hook this new code into the web app, these additional changes were
53 made:
54
55 * api/openecomp-sdc-rest-webapp/pom.xml
56   - Updated pom to include new module to build.
57 * api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml
58   - Update pom to include externaltesting libraries.
59 * api/openecomp-sdc-rest-webapp/onboarding-rest-war
60   - Update src/main/webapp/WEB-INF/beans-services.xml so that the external testing service beans are instantiated.
61
62
63
64
65 Configuration
66 =============
67
68 Configuration was added to the onboarding backend yaml in
69 order to know the URLs to reach VTP and external testing sources.
70 The full configuration is documented in the configuration section
71 of this manual. For details, see the BE-onboarding-configuration.yaml
72 section. Here is an example of the yaml.
73
74 ::
75
76     # External Testing Configuration
77     externalTestingConfig:
78       #array of endpoints that SDC-BE should connect with for external testing
79       endpoints:
80         // ID for endpoint
81       - id: vtp
82         // what format of post request does the endpoint accept for runs - json or multi-part form
83         postStyle: application/json
84         // is this enpoint enabled or disabled.
85         enabled: false
86         // base URL for the endpoint
87         url: http://ec2-34-237-35-152.compute-1.amazonaws.com:9090
88         // optional api key to pass in header to endpoint
89         apiKey: blahblahblah
90        - id: certifications repository
91           postStyle: application/json
92           url: http://ec2-34-237-35-152.compute-1.amazonaws.com:9090
93           enabled: true
94           apiKey: blahblahblah2
95