Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 1 | .. This work is licensed under a Creative Commons Attribution 4.0 International License. |
| 2 | .. http://creativecommons.org/licenses/by/4.0 |
| 3 | .. Copyright (C) 2019 IBM. |
| 4 | |
Ezhilarasi | d01a3ee | 2019-03-20 20:57:04 +0530 | [diff] [blame] | 5 | Resource Definition |
| 6 | ------------------- |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 7 | .. toctree:: |
| 8 | :maxdepth: 1 |
| 9 | |
| 10 | Introduction: |
| 11 | ============= |
Ezhilarasi | 12ee060 | 2019-04-17 18:01:14 +0530 | [diff] [blame] | 12 | A Resource definition models the how a specific resource can be resolved. |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 13 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 14 | A resource is a variable/parameter in the context of the service. It can be anything, but it should not be confused with SDC or Openstack resources. |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 15 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 16 | A Resource definition can have multiple sources to handle resolution in different ways. The main goal of Resource definition is to define re-usable entity that could be shared. |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 17 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 18 | Creation of Resource definition is a standalone activity, separated from the blueprint design. |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 19 | |
Ezhilarasi | 12ee060 | 2019-04-17 18:01:14 +0530 | [diff] [blame] | 20 | As part of modelling a Resource definition entry, the following generic information should be provided: |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 21 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 22 | |image0| |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 23 | |
Ezhilarasi | 807bab1 | 2019-07-05 13:47:24 +0530 | [diff] [blame] | 24 | |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 25 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 26 | Below are properties that all the resource source have will have |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 27 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 28 | The modeling does allow for data translation between external capability and CDS for both input and output key mapping. |
Ezhilarasi | 68f9fea | 2019-03-08 19:32:42 +0530 | [diff] [blame] | 29 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 30 | |image1| |
| 31 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 32 | |
| 33 | Example: |
| 34 | ======== |
| 35 | |
| 36 | vf-module-model-customization-uuid and vf-module-label are two data dictionaries. A SQL table, VF_MODULE_MODEL, exist to correlate them. |
| 37 | |
| 38 | Here is how input-key-mapping, output-key-mapping and key-dependencies can be used: |
| 39 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 40 | .. toctree:: |
| 41 | :maxdepth: 1 |
| 42 | |
Ezhilarasi | aec7024 | 2019-08-19 20:44:09 +0530 | [diff] [blame] | 43 | resourcedefinitioncodesnip |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 44 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 45 | |
Ezhilarasi | fe6afae | 2019-04-15 19:55:07 +0530 | [diff] [blame] | 46 | Resource source: |
| 47 | ================ |
| 48 | |
| 49 | Defines the contract to resolve a resource. |
| 50 | |
Ezhilarasi | 12ee060 | 2019-04-17 18:01:14 +0530 | [diff] [blame] | 51 | A resource source is modeled, following TOSCA_ node type definition and derives from the Resource_ source. |
| 52 | |
Ezhilarasi | 09af94b | 2019-04-22 19:16:44 +0530 | [diff] [blame] | 53 | Also please click below for resource source available details |
Ezhilarasi | 12ee060 | 2019-04-17 18:01:14 +0530 | [diff] [blame] | 54 | |
| 55 | .. toctree:: |
| 56 | :maxdepth: 1 |
| 57 | |
| 58 | resourcesource |
| 59 | |
| 60 | .. _TOSCA: http://docs.oasis-open.org/tosca/TOSCA-Simple-Profile-YAML/v1.0/csprd01/TOSCA-Simple-Profile-YAML-v1.0-csprd01.html#DEFN_ENTITY_NODE_TYPE |
Ezhilarasi | 807bab1 | 2019-07-05 13:47:24 +0530 | [diff] [blame] | 61 | .. _Resource: https://wiki.onap.org/display/DW/Modeling+Concepts#ModelingConcepts-NodeResourceSource |
| 62 | |
| 63 | |
Ezhilarasi | 9a02d3c | 2019-07-19 19:45:40 +0530 | [diff] [blame] | 64 | .. |image0| image:: media/mandatory.JPG |
Ezhilarasi | 807bab1 | 2019-07-05 13:47:24 +0530 | [diff] [blame] | 65 | :width: 7.88889in |
| 66 | :height: 4.43750in |
| 67 | |
Ezhilarasi | 9a02d3c | 2019-07-19 19:45:40 +0530 | [diff] [blame] | 68 | .. |image1| image:: media/optional.JPG |
Ezhilarasi | 807bab1 | 2019-07-05 13:47:24 +0530 | [diff] [blame] | 69 | :width: 7.88889in |
| 70 | :height: 4.43750in |