diff options
author | vamshi.nemalikonda <vn00480215@techmahindra.com> | 2020-02-24 13:06:49 +0000 |
---|---|---|
committer | vamshi.nemalikonda <vn00480215@techmahindra.com> | 2020-03-04 16:02:48 +0000 |
commit | e22e3d7253af689775f4f85dbb865c7587b04e4b (patch) | |
tree | e4187d2eaa5269491cf486e99c0a3b1d0e891897 /src/inventory/constants | |
parent | 219a7eab4129b3e500bcaf6c62819011580895ba (diff) |
Updating AAI wit resource info : part2
adding constants. Issue-ID: MULTICLOUD-457
Change-Id: Icf97d13a6c683b8f09491491ed2d2709f3800808
Signed-off-by: vamshi.nemalikonda <vn00480215@techmahindra.com>
Updating AAI wit resource info : part2
review comments fixed for constants. Issue-ID: MULTICLOUD-457
Change-Id: Icf97d13a6c683b8f09491491ed2d2709f3800808
Signed-off-by: vamshi.nemalikonda <vn00480215@techmahindra.com>
Diffstat (limited to 'src/inventory/constants')
-rw-r--r-- | src/inventory/constants/const.go | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/src/inventory/constants/const.go b/src/inventory/constants/const.go new file mode 100644 index 00000000..a1ba2334 --- /dev/null +++ b/src/inventory/constants/const.go @@ -0,0 +1,94 @@ +/* +Copyright 2020 Tech Mahindra. +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + http://www.apache.org/licenses/LICENSE-2.0 +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package constants + +import ( + +//corev1 "k8s.io/api/core/v1" + +) + +const ( + XFromAppId = "SO" + ContentType = "application/json" + Accept = "application/json" + XTransactionId = "get_aai_subscr" +) + +const ( + AAI_EP = "/aai/v14" + AAI_CREP = "/cloud-infrastructure/cloud-regions/" + AAI_NEP = "/network/generic-vnfs/generic-vnf/" +) + +const ( + MK8S_EP = "/api/multicloud-k8s/v1/v1/instance/" + MK8S_CEP = "/connectivity-info" +) + +type PodInfoToAAI struct { + VserverName string + VserverName2 string + ProvStatus string + I3InterfaceIPv4Address string + I3InterfaceIPvPrefixLength int32 + VnfId string + VfmId string + CloudRegion string +} + +type RData struct { + RelationshipKey string `json:"relationship-key"` + RelationshipValue string `json:"relationship-value"` +} + +type RelationList struct { + RelatedTo string `json:"related-to"` + RelatedLink string `json:"related-link"` + RelationshipData []RData `json:"relationship-data"` + RelatedToProperty []Property `json:"related-to-property"` +} + +type TenantInfo struct { + TenantId string `json:"tenant-id"` + TenantName string `json:"tenant-name"` +} + +type Tenant struct { + Tenants map[string][]TenantInfo `json:"tenants"` +} + +type Property struct { + PropertyKey string `json:"property-key"` + PropertyValue string `json:"property-value"` +} + +type VFModule struct { + VFModuleId string `json:"vf-module-id"` + VFModuleName string `json:"vf-module-name"` + HeatStackId string `json:"heat-stack-id"` + OrchestrationStatus string `json:"orchestration-status"` + ResourceVersion string `json:"resource-version"` + AutomatedAssignment string `json:"automated-assignment"` + IsBaseVfModule string `json:"is-base-vf-module"` + RelationshipList map[string][]RelationList `json:"relationship-list"` + ModelInvariantId string `json:"model-invariant-id"` + ModelVersionId string `json:"model-version-id"` + ModelCustomizationId string `json:"model-customization-id"` + ModuleIndex string `json:"module-index"` +} + +type VFModules struct { + VFModules []VFModule `json:"vf-module"` +} |