ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
| 2 | <!-- |
| 3 | ============LICENSE_START======================================================= |
| 4 | ECOMP MSO |
| 5 | ================================================================================ |
| 6 | Copyright (C) 2017 AT&T Intellectual Property. All rights reserved. |
| 7 | ================================================================================ |
| 8 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 9 | you may not use this file except in compliance with the License. |
| 10 | You may obtain a copy of the License at |
xg353y | b6b7bef | 2017-04-11 13:30:42 +0200 | [diff] [blame] | 11 | |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 12 | http://www.apache.org/licenses/LICENSE-2.0 |
xg353y | b6b7bef | 2017-04-11 13:30:42 +0200 | [diff] [blame] | 13 | |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 14 | Unless required by applicable law or agreed to in writing, software |
| 15 | distributed under the License is distributed on an "AS IS" BASIS, |
| 16 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 17 | See the License for the specific language governing permissions and |
| 18 | limitations under the License. |
| 19 | ============LICENSE_END========================================================= |
| 20 | --> |
| 21 | |
| 22 | <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN" "http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd"> |
| 23 | |
| 24 | <hibernate-mapping package="org.openecomp.mso.db.catalog.beans"> |
| 25 | <class name="Service" table="SERVICE"> |
| 26 | <meta attribute="class-description"> |
| 27 | This class describes a Service that may be orchestrated |
| 28 | </meta> |
xg353y | b6b7bef | 2017-04-11 13:30:42 +0200 | [diff] [blame] | 29 | |
Arthur Martella | 62cd6aa | 2017-09-08 13:27:46 -0400 | [diff] [blame] | 30 | <id name="modelUUID" column="MODEL_UUID" type="string" length="200"/> |
| 31 | <property name="modelName" column="MODEL_NAME" type="string" length="200" not-null="true"/> |
| 32 | <property name="version" column="MODEL_VERSION" type="string" length="20" not-null="true"/> |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 33 | <property name="description" column="DESCRIPTION" type="string" length="1200"/> |
Arthur Martella | 62cd6aa | 2017-09-08 13:27:46 -0400 | [diff] [blame] | 34 | <property name="toscaCsarArtifactUUID" column="TOSCA_CSAR_ARTIFACT_UUID" type="string" length="200" /> |
xg353y | b6b7bef | 2017-04-11 13:30:42 +0200 | [diff] [blame] | 35 | |
Jim Hahn | 20e60c8 | 2017-10-12 11:32:34 -0400 | [diff] [blame] | 36 | <property name="created" type="timestamp" generated="insert" update="false" insert="false" not-null="true"> |
| 37 | <column name="CREATION_TIMESTAMP" default="CURRENT_TIMESTAMP"/> |
| 38 | </property> |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 39 | <property name="modelInvariantUUID" type="string"> |
| 40 | <column name="MODEL_INVARIANT_UUID" default="'MANUAL_RECORD'" not-null="true" length="200"/> |
| 41 | </property> |
c00149107 | 2a4218f | 2018-01-19 14:36:23 +0800 | [diff] [blame^] | 42 | <property name="category" column="SERVICE_CATEGORY" type="string" length="20"/> |
Arthur Martella | 62cd6aa | 2017-09-08 13:27:46 -0400 | [diff] [blame] | 43 | <property name="serviceType" column="SERVICE_TYPE" type="string" length="20"/> |
| 44 | <property name="serviceRole" column="SERVICE_ROLE" type="string" length="20"/> |
| 45 | |
| 46 | <map name="recipes" inverse="true" cascade="all"> |
| 47 | <key column="SERVICE_MODEL_UUID"/> |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 48 | <map-key column="action" type="string"/> |
| 49 | <one-to-many class="ServiceRecipe"/> |
| 50 | </map> |
Arthur Martella | 62cd6aa | 2017-09-08 13:27:46 -0400 | [diff] [blame] | 51 | |
| 52 | <set name="serviceResourceCustomizations" inverse="true" cascade="all"> |
| 53 | <key column="SERVICE_MODEL_UUID" not-null="true" /> |
| 54 | <one-to-many class="ServiceToResourceCustomization" /> |
| 55 | </set> |
ChrisC | 025301d | 2017-01-31 11:40:03 +0100 | [diff] [blame] | 56 | </class> |
Arthur Martella | 62cd6aa | 2017-09-08 13:27:46 -0400 | [diff] [blame] | 57 | </hibernate-mapping> |