From 2953ef0a85f311e1c86db9455ebd47a4ef59b157 Mon Sep 17 00:00:00 2001 From: Nikita Sorokin Date: Tue, 3 Oct 2023 16:44:32 +0300 Subject: [PATCH] v1.6.4 --- CHANGELOG.md | 9 +++++++-- pkg/cloudapi/account/models.go | 6 +++--- pkg/cloudapi/compute/list_pci_device.go | 4 ++-- pkg/cloudapi/k8s/list_deleted.go | 4 ---- pkg/cloudapi/rg/affinity_groups_list.go | 8 ++++++++ pkg/cloudapi/rg/models.go | 6 +++--- 6 files changed, 23 insertions(+), 14 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 376e59e..1e501b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,9 @@ -## Version 1.6.3 +## Version 1.6.4 ### Bugfix -- Fixed fields SysctlParams and ACL models RecordLB in ca/lb/models and models RecordLB and ItemLBList in cb/lb/models +- Fixed type field DiskSizeMax in Resource model in cloudapi/account/models. Rename field ItemResourceConsumption model and rename json's tags in cloudapi/account/models +- Rename field in ListPCIDeviceRequest model in cloudapi/compute/list_pci_device +- Delete excess field in ListDeletedRequest model in cloudapi/k8s/list_deleted +- Add fields Page and Size in AffinityGroupsListRequest model in cloudapi/lb/affinity_groups_list +- Fixed type field Data in ListAffinityGroups model in cloudapi/lb/models +- Rename in ItemResourceConsumption model json's tags in cloudapi/rg/models diff --git a/pkg/cloudapi/account/models.go b/pkg/cloudapi/account/models.go index 3b3076f..871cc87 100644 --- a/pkg/cloudapi/account/models.go +++ b/pkg/cloudapi/account/models.go @@ -88,7 +88,7 @@ type Resource struct { DiskSize float64 `json:"disksize"` // Max disk size - DiskSizeMax uint64 `json:"disksizemax"` + DiskSizeMax float64 `json:"disksizemax"` // Number of External IPs ExtIPs int64 `json:"extips"` @@ -126,10 +126,10 @@ type RecordResourceConsumption struct { // Information about resources type ItemResourceConsumption struct { // Current information about resources - Current Resource `json:"Current"` + Consumed Resource `json:"consumed"` // Reserved information about resources - Reserved Resource `json:"Reserved"` + Reserved Resource `json:"reserved"` // Account ID AccountID uint64 `json:"id"` diff --git a/pkg/cloudapi/compute/list_pci_device.go b/pkg/cloudapi/compute/list_pci_device.go index c01df14..74b4a29 100644 --- a/pkg/cloudapi/compute/list_pci_device.go +++ b/pkg/cloudapi/compute/list_pci_device.go @@ -22,9 +22,9 @@ type ListPCIDeviceRequest struct { // Required: false DevID uint64 `url:"devId,omitempty" json:"devId,omitempty"` - // Find by type + // Find by name // Required: false - Type string `url:"type,omitempty" json:"type,omitempty"` + Name string `url:"name,omitempty" json:"name,omitempty"` // Find by status // Required: false diff --git a/pkg/cloudapi/k8s/list_deleted.go b/pkg/cloudapi/k8s/list_deleted.go index b37e8e9..ddb45d1 100644 --- a/pkg/cloudapi/k8s/list_deleted.go +++ b/pkg/cloudapi/k8s/list_deleted.go @@ -32,10 +32,6 @@ type ListDeletedRequest struct { // Required: false BasicServiceID uint64 `url:"basicServiceId,omitempty" json:"basicServiceId,omitempty"` - // Find by status - // Required: false - Status string `url:"status,omitempty" json:"status,omitempty"` - // Find by techStatus // Required: false TechStatus string `url:"techStatus,omitempty" json:"techStatus,omitempty"` diff --git a/pkg/cloudapi/rg/affinity_groups_list.go b/pkg/cloudapi/rg/affinity_groups_list.go index a851f34..458fcca 100644 --- a/pkg/cloudapi/rg/affinity_groups_list.go +++ b/pkg/cloudapi/rg/affinity_groups_list.go @@ -13,6 +13,14 @@ type AffinityGroupsListRequest struct { // Resource group ID // Required: true RGID uint64 `url:"rgId" json:"rgId" validate:"required"` + + // Page number + // Required: false + Page uint64 `url:"page,omitempty" json:"page,omitempty"` + + // Page size + // Required: false + Size uint64 `url:"size,omitempty" json:"size,omitempty"` } // AffinityGroupsList gets all currently defined affinity groups in this resource group with compute IDs diff --git a/pkg/cloudapi/rg/models.go b/pkg/cloudapi/rg/models.go index 2cb32da..71849ec 100644 --- a/pkg/cloudapi/rg/models.go +++ b/pkg/cloudapi/rg/models.go @@ -48,10 +48,10 @@ type Resources struct { // Detailed information about resource consumption type ItemResourceConsumption struct { // Consumed information about resources - Consumed Resource `json:"Consumed"` + Consumed Resource `json:"consumed"` // Reserved information about resources - Reserved Resource `json:"Reserved"` + Reserved Resource `json:"reserved"` // Resource limits ResourceLimits ResourceLimits `json:"resourceLimits"` @@ -333,7 +333,7 @@ type ListAffinityGroupsComputes []ItemAffinityGroupComputes type ListAffinityGroups struct { // Data - Data map[string][]uint64 `json:"data"` + Data []map[string][]uint64 `json:"data"` // Entry count EntryCount uint64 `json:"entryCount"`