diff --git a/api/cfm-openapi.yaml b/api/cfm-openapi.yaml index 108ca75..09d772f 100644 --- a/api/cfm-openapi.yaml +++ b/api/cfm-openapi.yaml @@ -188,8 +188,8 @@ paths: schema: $ref: "#/components/schemas/statusMessage" put: - description: Rename an appliance by new id. - operationId: appliancesRenameById + description: Update an appliance with a new id. + operationId: appliancesUpdateById parameters: - $ref: "#/components/parameters/applianceId" - name: newApplianceId @@ -364,8 +364,8 @@ paths: schema: $ref: "#/components/schemas/statusMessage" put: - description: Rename a blade by new id. - operationId: bladesRenameById + description: Update a blade with a new id. + operationId: bladesUpdateById parameters: - $ref: "#/components/parameters/applianceId" - $ref: "#/components/parameters/bladeId" @@ -880,8 +880,8 @@ paths: schema: $ref: "#/components/schemas/statusMessage" put: - description: Rename a CXL host by new id. - operationId: hostsRenameById + description: Update a CXL host with a new id. + operationId: hostsUpdateById parameters: - $ref: "#/components/parameters/hostId" - name: newHostId diff --git a/pkg/api/api_default_service.go b/pkg/api/api_default_service.go index e5ca9b6..611d1cc 100644 --- a/pkg/api/api_default_service.go +++ b/pkg/api/api_default_service.go @@ -143,8 +143,8 @@ func (cfm *CfmApiService) AppliancesPost(ctx context.Context, credentials openap return openapi.Response(http.StatusCreated, a), nil } -// AppliancesRenameById - -func (cfm *CfmApiService) AppliancesRenameById(ctx context.Context, applianceId string, newApplianceId string) (openapi.ImplResponse, error) { +// AppliancesUpdateById - +func (cfm *CfmApiService) AppliancesUpdateById(ctx context.Context, applianceId string, newApplianceId string) (openapi.ImplResponse, error) { // Make sure the newApplianceId doesn't exist _, exist := manager.GetApplianceById(ctx, newApplianceId) if exist == nil { @@ -522,8 +522,8 @@ func (cfm *CfmApiService) BladesGetPorts(ctx context.Context, applianceId string return openapi.Response(http.StatusOK, response), nil } -// BladesRenameById - -func (cfm *CfmApiService) BladesRenameById(ctx context.Context, applianceId string, bladeId string, newBladeId string) (openapi.ImplResponse, error) { +// BladesUpdateById - +func (cfm *CfmApiService) BladesUpdateById(ctx context.Context, applianceId string, bladeId string, newBladeId string) (openapi.ImplResponse, error) { appliance, err := manager.GetApplianceById(ctx, applianceId) if err != nil { return formatErrorResp(ctx, err.(*common.RequestError)) @@ -994,8 +994,8 @@ func (cfm *CfmApiService) HostsPost(ctx context.Context, credentials openapi.Cre return openapi.Response(http.StatusCreated, h), nil } -// HostsRenameById - -func (cfm *CfmApiService) HostsRenameById(ctx context.Context, hostId string, newHostId string) (openapi.ImplResponse, error) { +// HostsUpdateById - +func (cfm *CfmApiService) HostsUpdateById(ctx context.Context, hostId string, newHostId string) (openapi.ImplResponse, error) { // Make sure the hostId exists // Get the host information from the manager level and is used for renaming host, err := manager.GetHostById(ctx, hostId)