Skip to content

Commit

Permalink
update to v2.14.0 schema
Browse files Browse the repository at this point in the history
  • Loading branch information
Sczlog committed Jan 4, 2024
1 parent 14a4417 commit 471559a
Show file tree
Hide file tree
Showing 11 changed files with 2,211 additions and 1,387 deletions.
43 changes: 43 additions & 0 deletions RELEASENOTE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,48 @@
# RELEASE NOTE

## release 日期 2024-01-04

v2.14.0 release (tower version 4.0.0)

### update

- [ContentLibraryImageApi]:
- [importContentLibraryImage]: 新增通过 url 导入内容库镜像 API
- [GpuDeviceApi]:
- [getDetailVmInfoByGpuDevices]: 新增获取 GPU 设备关联的虚拟机 API
- [HostApi]:
- [enterMaintenanceMode]: 新增进入维护模式 API
- [enterMaintenanceModePreCheck]: 新增进入维护模式预检 API
- [enterMaintenanceModePrecheckResult]: 新增获取进入维护模式预检结果 API
- [exitMaintenanceMode]: 新增离开维护模式 API
- [exitMaintenanceModePrecheckResult]: 新增离开维护模式预检 API
- [powerOffHost]: 新增主机电源操作 API,用于关闭、重启主机
- [IscsiLunAPi]:
- [copyIscsiLun]: 新增复制 iscsi lun API
- [NicApi]:
- [getNics]: 额外返回 iommu_status 以及关联的虚拟机
- [TaskApi]:
- [createTask]: 新增创建 Task API
- [updateTask]: 新增更新 Task API
- [UserAuditLogApi]:
- [createUserAuditLog]: 新增创建事件审计 API
- [VmApi]:
- [getVmGpuDeviceInfo]: 新增根据虚拟机获取其挂载的 GPU 设备信息 API
- [getVmVncInfo]: 新增获取 vm vnc 信息 API
- [migrateVmAcrossCluster]\: 优化了报错逻辑,当目标主机存在且不在目标集群上时,直接报错
- [rebuildVmFromSnapshot]: 重建虚拟机 API 支持配置 PCI 网卡
- [createVm], [createVmFromTemplate], [createVmFromContentLibraryTemplate], [cloneVm], [rebuildVmFromSnapshot]: 创建虚拟机时支持配置虚拟机所属用户

### bugfix

- [ContentLibraryImageApi]:
- [updateContentLibraryImage]: 修复了更新内容库镜像时,没有传递 name 会失败的问题
- [ElfImageApi]:
- [updateElfImage]: 修复了更新镜像时,没有传递 name 会失败的问题
- [vmApi]:
- [createVmFromContentLibraryTemplate]\: 修复模板卷存储策略包含三副本时,非完全克隆虚拟机失败,提示非完全克隆无法修改存储策略的问题


## release 日期 2023-11-07

v2.13.0 release (tower version 3.4.0)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cloudtower-node-sdk",
"version": "2.13.0",
"version": "2.14.0",
"description": "cloudtower operation api",
"main": "lib/index.js",
"typings": "typings/index.d.ts",
Expand Down
26 changes: 26 additions & 0 deletions src/generated/ContentLibraryImage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import {
ContentLibraryImage,
ContentLibraryImageConnection,
ContentLibraryImageDeletionParams,
ContentLibraryImageImportParams,
ContentLibraryImageUpdationClusterParams,
ContentLibraryImageUpdationParams,
ErrorBody,
Expand Down Expand Up @@ -154,6 +155,31 @@ export class ContentLibraryImageApi<SecurityDataType = unknown> {
format: "json",
...params,
});
/**
* No description
*
* @tags ContentLibraryImage
* @name ImportContentLibraryImage
* @request POST:/import-content-library-image
* @secure
* @response `200` `UploadTask`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
importContentLibraryImage = (
data: ContentLibraryImageImportParams,
params: RequestParams = {}
) =>
this.http.request<UploadTask, ErrorBody>({
path: `/import-content-library-image`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
Expand Down
27 changes: 27 additions & 0 deletions src/generated/GpuDevice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
GpuDeviceDescriptionUpdationParams,
GpuDeviceSriovSwitchParams,
GpuDeviceUsageUpdationParams,
GpuVmInfo,
WithTaskGpuDevice,
} from "./data-contracts";
import { ContentType, HttpClient, RequestParams } from "./http-client";
Expand Down Expand Up @@ -96,6 +97,32 @@ export class GpuDeviceApi<SecurityDataType = unknown> {
format: "json",
...params,
});
/**
* No description
*
* @tags GpuDevice
* @name GetDetailVmInfoByGpuDevices
* @request POST:/get-detail-vm-info-by-gpu-devices
* @secure
* @response `200` `(GpuVmInfo)[]`
* @response `304` `void` Not modified
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
getDetailVmInfoByGpuDevices = (
data: GetGpuDevicesRequestBody,
params: RequestParams = {}
) =>
this.http.request<GpuVmInfo[], void | ErrorBody>({
path: `/get-detail-vm-info-by-gpu-devices`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
Expand Down
156 changes: 156 additions & 0 deletions src/generated/Host.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
import {
EnterMaintenanceModeCheckParams,
EnterMaintenanceModeCheckResult,
EnterMaintenanceModeParams,
EnterMaintenanceModeResult,
EnterMaintenanceModeResultParams,
ErrorBody,
ExitMaintenanceModeParams,
ExitMaintenanceModeResult,
ExitMaintenanceModeResultParams,
GetHostsConnectionRequestBody,
GetHostsRequestBody,
Host,
HostConnection,
HostCreationParams,
HostUpdationParams,
OperateHostPowerParams,
TriggerDiskBlinkParams,
WithTaskBatchHosts,
WithTaskHost,
Expand Down Expand Up @@ -88,6 +97,153 @@ export class HostApi<SecurityDataType = unknown> {
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name PowerOffHost
* @request POST:/operate-host-power
* @secure
* @response `200` `WithTaskHost`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
powerOffHost = (data: OperateHostPowerParams, params: RequestParams = {}) =>
this.http.request<WithTaskHost, ErrorBody>({
path: `/operate-host-power`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name EnterMaintenanceModePreCheck
* @request POST:/enter-maintenance-mode-precheck
* @secure
* @response `200` `EnterMaintenanceModeCheckResult`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
enterMaintenanceModePreCheck = (
data: EnterMaintenanceModeCheckParams,
params: RequestParams = {}
) =>
this.http.request<EnterMaintenanceModeCheckResult, ErrorBody>({
path: `/enter-maintenance-mode-precheck`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name EnterMaintenanceModePrecheckResult
* @request POST:/enter-maintance-mode-precheck-result
* @secure
* @response `200` `EnterMaintenanceModeResult`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
enterMaintenanceModePrecheckResult = (
data: EnterMaintenanceModeResultParams,
params: RequestParams = {}
) =>
this.http.request<EnterMaintenanceModeResult, ErrorBody>({
path: `/enter-maintance-mode-precheck-result`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name EnterMaintenanceMode
* @request POST:/enter-maintance-mode
* @secure
* @response `200` `WithTaskHost`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
enterMaintenanceMode = (
data: EnterMaintenanceModeParams,
params: RequestParams = {}
) =>
this.http.request<WithTaskHost, ErrorBody>({
path: `/enter-maintance-mode`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name ExitMaintenanceModePrecheckResult
* @request POST:/exit-maintance-mode-precheck-result
* @secure
* @response `200` `ExitMaintenanceModeResult`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
exitMaintenanceModePrecheckResult = (
data: ExitMaintenanceModeResultParams,
params: RequestParams = {}
) =>
this.http.request<ExitMaintenanceModeResult, ErrorBody>({
path: `/exit-maintance-mode-precheck-result`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
* @tags Host
* @name ExitMaintenanceMode
* @request POST:/exit-maintance-mode
* @secure
* @response `200` `WithTaskHost`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
exitMaintenanceMode = (
data: ExitMaintenanceModeParams,
params: RequestParams = {}
) =>
this.http.request<WithTaskHost, ErrorBody>({
path: `/exit-maintance-mode`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
Expand Down
23 changes: 23 additions & 0 deletions src/generated/IscsiLun.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import {
CopyIscsiLunParams,
ErrorBody,
GetIscsiLunsConnectionRequestBody,
GetIscsiLunsRequestBody,
Expand Down Expand Up @@ -140,6 +141,28 @@ export class IscsiLunApi<SecurityDataType = unknown> {
format: "json",
...params,
});
/**
* No description
*
* @tags IscsiLun
* @name CopyIscsiLun
* @request POST:/copy-iscsi-lun
* @secure
* @response `200` `(WithTaskIscsiLun)[]`
* @response `400` `ErrorBody` Bad request
* @response `404` `ErrorBody` Not found
* @response `500` `ErrorBody` Server error
*/
copyIscsiLun = (data: CopyIscsiLunParams[], params: RequestParams = {}) =>
this.http.request<WithTaskIscsiLun[], ErrorBody>({
path: `/copy-iscsi-lun`,
method: "POST",
body: data,
secure: true,
type: ContentType.Json,
format: "json",
...params,
});
/**
* No description
*
Expand Down
Loading

0 comments on commit 471559a

Please sign in to comment.