From ba45c4c4339fd7951e723e6c24bde2d032ef3392 Mon Sep 17 00:00:00 2001 From: Rohit Rajput <83547290+Rohit-R2000@users.noreply.github.com> Date: Wed, 19 Oct 2022 22:48:53 +0530 Subject: [PATCH 1/4] Update provisioning.go changed function name from CorePostMcisVm to CreateMcisVm --- src/core/mcis/provisioning.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/mcis/provisioning.go b/src/core/mcis/provisioning.go index 116fea1ba..32a4871e2 100644 --- a/src/core/mcis/provisioning.go +++ b/src/core/mcis/provisioning.go @@ -488,7 +488,7 @@ type TbVmRecommendInfo struct { // MCIS and VM Provisioning // CorePostMcisVm is func to post (create) McisVm -func CorePostMcisVm(nsId string, mcisId string, vmInfoData *TbVmInfo) (*TbVmInfo, error) { +func CreateMcisVm(nsId string, mcisId string, vmInfoData *TbVmInfo) (*TbVmInfo, error) { err := common.CheckString(nsId) if err != nil { From cddf1fb1e2704fc75a2ce5a8714646b1871eadea Mon Sep 17 00:00:00 2001 From: Rohit Rajput <83547290+Rohit-R2000@users.noreply.github.com> Date: Wed, 26 Oct 2022 14:26:27 +0530 Subject: [PATCH 2/4] changed name from CorePostMcisVm to CreateMcisVm --- src/core/mcis/orchestration.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/mcis/orchestration.go b/src/core/mcis/orchestration.go index 2e970fc48..1d25b1c2d 100644 --- a/src/core/mcis/orchestration.go +++ b/src/core/mcis/orchestration.go @@ -315,7 +315,7 @@ func OrchestrationController() { // ScaleOut MCIS according to the VM requirement. fmt.Println("[Generating VM]") - result, vmCreateErr := CorePostMcisVm(nsId, mcisPolicyTmp.Id, &autoAction.Vm) + result, vmCreateErr := CreateMcisVm(nsId, mcisPolicyTmp.Id, &autoAction.Vm) if vmCreateErr != nil { mcisPolicyTmp.Policy[policyIndex].Status = AutoStatusError UpdateMcisPolicyInfo(nsId, mcisPolicyTmp) From ec2bf47aacade5592d9760251bc6627bd72d5275 Mon Sep 17 00:00:00 2001 From: Rohit Rajput <83547290+Rohit-R2000@users.noreply.github.com> Date: Wed, 26 Oct 2022 14:28:23 +0530 Subject: [PATCH 3/4] changed function name from CorePostMcisVm to CreateMcisVm --- src/core/mcis/provisioning.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/mcis/provisioning.go b/src/core/mcis/provisioning.go index 32a4871e2..509062788 100644 --- a/src/core/mcis/provisioning.go +++ b/src/core/mcis/provisioning.go @@ -487,7 +487,7 @@ type TbVmRecommendInfo struct { // MCIS and VM Provisioning -// CorePostMcisVm is func to post (create) McisVm +// CreateMcisVm is func to post (create) McisVm func CreateMcisVm(nsId string, mcisId string, vmInfoData *TbVmInfo) (*TbVmInfo, error) { err := common.CheckString(nsId) From bb06ea94f75c91968bd77c6636d4265b880e39e9 Mon Sep 17 00:00:00 2001 From: Seokho Son Date: Tue, 1 Nov 2022 19:09:10 +0900 Subject: [PATCH 4/4] Refine CorePostMcisVm func name --- docs/images/cb-tb-call-core-mcis.svg | 58 ++++++++++++++-------------- docs/images/cb-tb-call-rest-mcis.svg | 10 ++--- src/api/grpc/server/mcis/control.go | 2 +- 3 files changed, 35 insertions(+), 35 deletions(-) diff --git a/docs/images/cb-tb-call-core-mcis.svg b/docs/images/cb-tb-call-core-mcis.svg index f2d5aa365..401d4c7c8 100644 --- a/docs/images/cb-tb-call-core-mcis.svg +++ b/docs/images/cb-tb-call-core-mcis.svg @@ -3973,71 +3973,71 @@ - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm -CorePostMcisVm +CreateMcisVm - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.CheckString +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.CheckString - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.GenMcisKey +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.GenMcisKey - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.GetMcisObject +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.GetMcisObject - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.AddVmToMcis +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.AddVmToMcis - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.PrintJsonPretty +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/common.PrintJsonPretty - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.GetVmStatus +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.GetVmStatus - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CheckDragonflyEndpoint +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CheckDragonflyEndpoint - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.InstallMonitorAgentToMcis +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.InstallMonitorAgentToMcis - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CheckVm +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CheckVm - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm->(*github.com/sirupsen/logrus.Logger).Error +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm->(*github.com/sirupsen/logrus.Logger).Error @@ -4048,9 +4048,9 @@ mcis RestPostMcisVm - + -github.com/cloud-barista/cb-tumblebug/src/api/rest/server/mcis.RestPostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +github.com/cloud-barista/cb-tumblebug/src/api/rest/server/mcis.RestPostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm @@ -6028,9 +6028,9 @@ - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.OrchestrationController->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +github.com/cloud-barista/cb-tumblebug/src/core/mcis.OrchestrationController->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm @@ -6529,9 +6529,9 @@ mcis CreateMcisVM - + -(*github.com/cloud-barista/cb-tumblebug/src/api/grpc/server/mcis.MCISService).CreateMcisVM->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +(*github.com/cloud-barista/cb-tumblebug/src/api/grpc/server/mcis.MCISService).CreateMcisVM->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm diff --git a/docs/images/cb-tb-call-rest-mcis.svg b/docs/images/cb-tb-call-rest-mcis.svg index 6c94a6fcc..dc49a03d1 100644 --- a/docs/images/cb-tb-call-rest-mcis.svg +++ b/docs/images/cb-tb-call-rest-mcis.svg @@ -1090,16 +1090,16 @@ - + -github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm mcis -CorePostMcisVm +CreateMcisVm - + -github.com/cloud-barista/cb-tumblebug/src/api/rest/server/mcis.RestPostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CorePostMcisVm +github.com/cloud-barista/cb-tumblebug/src/api/rest/server/mcis.RestPostMcisVm->github.com/cloud-barista/cb-tumblebug/src/core/mcis.CreateMcisVm diff --git a/src/api/grpc/server/mcis/control.go b/src/api/grpc/server/mcis/control.go index 2a2260bf1..e967aca08 100644 --- a/src/api/grpc/server/mcis/control.go +++ b/src/api/grpc/server/mcis/control.go @@ -236,7 +236,7 @@ func (s *MCISService) CreateMcisVM(ctx context.Context, req *pb.TbVmCreateReques return nil, gc.ConvGrpcStatusErr(err, "", "MCISService.CreateMcisVM()") } - result, err := mcis.CorePostMcisVm(req.NsId, req.McisId, &mcisObj) + result, err := mcis.CreateMcisVm(req.NsId, req.McisId, &mcisObj) if err != nil { return nil, gc.ConvGrpcStatusErr(err, "", "MCISService.CreateMcisVM()") }