Documentation
¶
Index ¶
- func CreateCloudModel(c echo.Context) error
- func CreateOnPremModel(c echo.Context) error
- func DeleteCloudModel(c echo.Context) error
- func DeleteOnPremModel(c echo.Context) error
- func GetCloudModel(c echo.Context) error
- func GetCloudModels(c echo.Context) error
- func GetModels(c echo.Context) error
- func GetModelsVersion(c echo.Context) error
- func GetOnPremModel(c echo.Context) error
- func GetOnPremModels(c echo.Context) error
- func RestCheckHTTPVersion(c echo.Context) error
- func RestGetReadyz(c echo.Context) error
- func UpdateCloudModel(c echo.Context) error
- func UpdateOnPremModel(c echo.Context) error
- type CloudModelReqInfo
- type CloudModelRespInfo
- type CreateCloudModelReq
- type CreateCloudModelResp
- type CreateOnPremModelReq
- type CreateOnPremModelResp
- type GetCloudModelResp
- type GetCloudModelsResp
- type GetModelsResp
- type GetModelsVersionResp
- type GetOnPremModelResp
- type GetOnPremModelsResp
- type ModelRespInfo
- type ModelsVersionRespInfo
- type OnPremModelReqInfo
- type OnPremModelRespInfo
- type ResHTTPVersion
- type ResReadyz
- type UpdateCloudModelReq
- type UpdateCloudModelResp
- type UpdateOnPremModelReq
- type UpdateOnPremModelResp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateCloudModel ¶
CreateCloudModel godoc @Summary Create a new cloud model @Description Create a new cloud model with the given information. @Tags [API] Cloud Migration User Models @Accept json @Produce json @Param Model body CreateCloudModelReq true "model information" @Success 201 {object} CreateCloudModelResp "(Sample) This is a sample description for success response in Swagger UI" @Failure 400 {object} object "Invalid Request" @Router /cloudmodel [post]
func CreateOnPremModel ¶
CreateOnPremModel godoc @Summary Create a new on-premise model @Description Create a new on-premise model with the given information. @Tags [API] On-Premise Migration User Models @Accept json @Produce json @Param Model body CreateOnPremModelReq true "model information" @Success 201 {object} CreateOnPremModelResp "(Sample) This is a sample description for success response in Swagger UI" @Failure 400 {object} object "Invalid Request" @Router /onpremmodel [post]
func DeleteCloudModel ¶
DeleteCloudModel godoc @Summary Delete a cloud model @Description Delete a cloud model with the given information. @Tags [API] Cloud Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Success 200 {string} string "Model deletion successful" @Failure 400 {object} object "Invalid Request" @Failure 404 {object} object "Model Not Found" @Router /cloudmodel/{id} [delete]
func DeleteOnPremModel ¶
DeleteOnPremModel godoc @Summary Delete a on-premise model @Description Delete a on-premise model with the given information. @Tags [API] On-Premise Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Success 200 {string} string "Model deletion successful" @Failure 400 {object} object "Invalid Request" @Failure 404 {object} object "Model Not Found" @Router /onpremmodel/{id} [delete]
func GetCloudModel ¶
GetCloudModel godoc @Summary Get a specific cloud model @Description Get a specific cloud model. @Tags [API] Cloud Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Success 200 {object} GetCloudModelResp "(Sample) a model" @Failure 404 {object} object "model not found" @Router /cloudmodel/{id} [get]
func GetCloudModels ¶
GetCloudModels godoc @Summary Get a list of cloud models @Description Get a list of cloud models. @Tags [API] Cloud Migration User Models @Accept json @Produce json @Success 200 {object} GetCloudModelsResp "(sample) This is a list of models" @Failure 404 {object} object "model not found" @Router /cloudmodel [get]
func GetModels ¶
GetModels godoc @Summary Get a list of all user models @Description Get a list of all user models. @Tags [API] Migration User Models @Accept json @Produce json @Param isTargetModel path bool true "Is TargetModel ?" @Success 200 {object} GetModelsResp "(sample) This is a list of models" @Failure 404 {object} object "model not found" @Router /model/{isTargetModel} [get]
func GetModelsVersion ¶
GetModelsVersion godoc @Summary Get the versions of all models(schemata of on-premise/cloud migration models) @Description Get the versions of all models(schemata of on-premise/cloud migration models) @Tags [API] Migration Models @Accept json @Produce json @Success 200 {object} GetModelsVersionResp "(sample) This is the versions of all models(schemata)" @Failure 404 {object} object "verson of models not found" @Router /model/version [get]
func GetOnPremModel ¶
GetOnPremModel godoc @Summary Get a specific on-premise model @Description Get a specific on-premise model. @Tags [API] On-Premise Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Success 200 {object} GetOnPremModelResp "(Sample) a model" @Failure 404 {object} object "model not found" @Router /onpremmodel/{id} [get]
func GetOnPremModels ¶
GetOnPremModels godoc @Summary Get a list of on-premise models @Description Get a list of on-premise models. @Tags [API] On-Premise Migration User Models @Accept json @Produce json @Success 200 {object} GetOnPremModelsResp "(sample) This is a list of models" @Failure 404 {object} object "model not found" @Router /onpremmodel [get]
func RestCheckHTTPVersion ¶
RestCheckHTTPVersion godoc @Summary Check HTTP version of incoming request @Description Checks and logs the HTTP version of the incoming request to the server console. @Tags [Admin] System management @Accept json @Produce json @Success 200 {object} ResHTTPVersion @Failure 404 {object} ResHTTPVersion @Failure 500 {object} ResHTTPVersion @Router /httpVersion [get]
func RestGetReadyz ¶
RestGetReadyz func check if CM-Damselfly server is ready or not. RestGetReadyz godoc @Summary Check Damselfly is ready @Description Check Damselfly is ready @Tags [Admin] System management @Accept json @Produce json @Success 200 {object} ResReadyz @Failure 503 {object} ResReadyz @Router /readyz [get]
func UpdateCloudModel ¶
UpdateCloudModel godoc @Summary Update a cloud model @Description Update a cloud model with the given information. @Tags [API] Cloud Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Param Model body UpdateCloudModelReq true "Model information to update" @Success 201 {object} UpdateCloudModelResp "(Sample) This is a sample description for success response in Swagger UI" @Failure 400 {object} object "Invalid Request" @Router /cloudmodel/{id} [put]
func UpdateOnPremModel ¶
UpdateOnPremModel godoc @Summary Update a on-premise model @Description Update a on-premise model with the given information. @Tags [API] On-Premise Migration User Models @Accept json @Produce json @Param id path string true "Model ID" @Param Model body UpdateOnPremModelReq true "Model information to update" @Success 201 {object} UpdateOnPremModelResp "(Sample) This is a sample description for success response in Swagger UI" @Failure 400 {object} object "Invalid Request" @Router /onpremmodel/{id} [put]
Types ¶
type CloudModelReqInfo ¶
type CloudModelReqInfo struct {
UserId string `json:"userId"`
IsTargetModel bool `json:"isTargetModel"`
IsInitUserModel bool `json:"isInitUserModel"`
UserModelName string `json:"userModelName"`
Description string `json:"description"`
UserModelVer string `json:"userModelVersion"`
CSP string `json:"csp"`
Region string `json:"region"`
Zone string `json:"zone"`
CloudInfraModel tbmodel.TbMciDynamicReq `json:"cloudInfraModel" validate:"required"`
}
type CloudModelRespInfo ¶
type CloudModelRespInfo struct {
Id string `json:"id"`
UserId string `json:"userId"`
IsTargetModel bool `json:"isTargetModel"`
IsInitUserModel bool `json:"isInitUserModel"`
UserModelName string `json:"userModelName"`
Description string `json:"description"`
UserModelVer string `json:"userModelVersion"`
CreateTime string `json:"createTime"`
UpdateTime string `json:"updateTime"`
CSP string `json:"csp"`
Region string `json:"region"`
Zone string `json:"zone"`
IsCloudModel bool `json:"isCloudModel"`
CloudModelVer string `json:"cloudModelVersion"`
CloudInfraModel tbmodel.TbMciDynamicReq `json:"cloudInfraModel" validate:"required"`
}
type CreateCloudModelReq ¶
type CreateCloudModelReq struct {
CloudModelReqInfo
}
[Note] Struct Embedding is used to inherit the fields of MyCloudModel
type CreateCloudModelResp ¶
type CreateCloudModelResp struct {
CloudModelRespInfo
}
[Note] Struct Embedding is used to inherit the fields of MyCloudModel
type CreateOnPremModelReq ¶
type CreateOnPremModelReq struct {
OnPremModelReqInfo
}
[Note] Struct Embedding is used to inherit the fields of MyOnPremModel
type CreateOnPremModelResp ¶
type CreateOnPremModelResp struct {
OnPremModelRespInfo
}
[Note] Struct Embedding is used to inherit the fields of MyOnPremModel
type GetCloudModelResp ¶
type GetCloudModelResp struct {
CloudModelRespInfo
}
type GetCloudModelsResp ¶
type GetCloudModelsResp struct {
Models []CloudModelRespInfo `json:"models"`
}
type GetModelsResp ¶
type GetModelsResp struct {
Models []ModelRespInfo `json:"models"`
}
type GetModelsVersionResp ¶
type GetModelsVersionResp struct {
ModelsVersion ModelsVersionRespInfo `json:"modelsVersion"`
}
type GetOnPremModelResp ¶
type GetOnPremModelResp struct {
OnPremModelRespInfo
}
type GetOnPremModelsResp ¶
type GetOnPremModelsResp struct {
Models []OnPremModelRespInfo `json:"models"`
}
type ModelRespInfo ¶
type ModelRespInfo struct {
Id string `json:"id"`
UserId string `json:"userId"`
IsInitUserModel bool `json:"isInitUserModel"`
UserModelName string `json:"userModelName"`
Description string `json:"description"`
UserModelVer string `json:"userModelVersion"`
CreateTime string `json:"createTime"`
UpdateTime string `json:"updateTime"`
IsTargetModel bool `json:"isTargetModel"`
IsCloudModel bool `json:"isCloudModel"`
OnPremModelVer string `json:"onpremModelVersion"`
CloudModelVer string `json:"cloudModelVersion"`
CSP string `json:"csp"`
Region string `json:"region"`
Zone string `json:"zone"`
OnpremInfraModel onprem.OnpremInfra `json:"onpremiseInfraModel" validate:"required"`
CloudInfraModel tbmodel.TbMciDynamicReq `json:"cloudInfraModel" validate:"required"`
}
type ModelsVersionRespInfo ¶
type OnPremModelReqInfo ¶
type OnPremModelReqInfo struct {
UserId string `json:"userId"`
IsInitUserModel bool `json:"isInitUserModel"`
UserModelName string `json:"userModelName"`
Description string `json:"description"`
UserModelVer string `json:"userModelVersion"`
OnpremInfraModel onprem.OnpremInfra `json:"onpremiseInfraModel" validate:"required"`
}
type OnPremModelRespInfo ¶
type OnPremModelRespInfo struct {
Id string `json:"id"`
UserId string `json:"userId"`
IsInitUserModel bool `json:"isInitUserModel"`
UserModelName string `json:"userModelName"`
Description string `json:"description"`
UserModelVer string `json:"userModelVersion"`
OnPremModelVer string `json:"onpremModelVersion"`
CreateTime string `json:"createTime"`
UpdateTime string `json:"updateTime"`
IsTargetModel bool `json:"isTargetModel"`
IsCloudModel bool `json:"isCloudModel"`
OnpremInfraModel onprem.OnpremInfra `json:"onpremiseInfraModel" validate:"required"`
}
type ResHTTPVersion ¶
type ResHTTPVersion struct {
model.SimpleMessage
}
type ResReadyz ¶
type ResReadyz struct {
model.SimpleMessage
}
type UpdateCloudModelReq ¶
type UpdateCloudModelReq struct {
CloudModelReqInfo
}
[Note] Struct Embedding is used to inherit the fields of MyCloudModel
type UpdateCloudModelResp ¶
type UpdateCloudModelResp struct {
CloudModelRespInfo
}
[Note] Struct Embedding is used to inherit the fields of MyCloudModel
type UpdateOnPremModelReq ¶
type UpdateOnPremModelReq struct {
OnPremModelReqInfo
}
[Note] Struct Embedding is used to inherit the fields of MyOnPremModel
type UpdateOnPremModelResp ¶
type UpdateOnPremModelResp struct {
OnPremModelRespInfo
}
[Note] Struct Embedding is used to inherit the fields of MyOnPremModel