From 1c59ca338ad99abcf36a8b0ba089ab3538dc480c Mon Sep 17 00:00:00 2001 From: Tim Tkachev Date: Tue, 15 Aug 2023 11:42:30 +0300 Subject: [PATCH] v1.5.3 --- CHANGELOG.md | 14 +++++--------- pkg/cloudapi/compute/disk_del.go | 2 +- pkg/cloudapi/disks/list_unattached.go | 8 ++++++++ pkg/cloudbroker/compute/disk_del.go | 2 +- pkg/cloudbroker/disks/list_unattached.go | 12 ++++++++---- pkg/cloudbroker/image/delete.go | 2 +- 6 files changed, 24 insertions(+), 16 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b633f9f..9c5c88a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,14 +1,10 @@ -## Version 1.5.2 +## Version 1.5.3 ### Bugfix -- Fix tag 'url' VINSID field in cloudbroker/account/list_vins +- Add a fields SEPID and Pool in ListUnattachedRequest struct in cloudbroker/disks/listUnattached and cloudapi/disks/listUnattached -- Made the field Reason not required in cloudbroker/account/enable and cloudbroker/account/disable +- Delete a field Shared in ListUnattachedRequest struct in cloudbroker/disks/listUnattached -- Made the field RecursiveDelete required in cloudbroker/account/deleteUser +- Delete tag Required at field Permanently in DiskDelRequest struct in cloudbroker/compute/disk_del and cloudapi/compute/disk_del -- Add a validator function to a workersGroupName field - must be 3 or more symbol - -- Add a token actuality check, add an error handler in client/client-transport and client/http-client - -- Add a fields SEPID and Pool in ListRequest struct in cloudbroker/disks/list and cloudapi/disks/list +- Delete tag omitempty at field Permanently in DeleteRequest struct in cloudbroker/image/delete \ No newline at end of file diff --git a/pkg/cloudapi/compute/disk_del.go b/pkg/cloudapi/compute/disk_del.go index 14a8120..41c56c6 100644 --- a/pkg/cloudapi/compute/disk_del.go +++ b/pkg/cloudapi/compute/disk_del.go @@ -20,7 +20,7 @@ type DiskDelRequest struct { // False if disk is to be deleted to recycle bin // Required: true - Permanently bool `url:"permanently" json:"permanently" validate:"required"` + Permanently bool `url:"permanently" json:"permanently"` } // DiskDel delete disk and detach from compute diff --git a/pkg/cloudapi/disks/list_unattached.go b/pkg/cloudapi/disks/list_unattached.go index 580364c..2c823d7 100644 --- a/pkg/cloudapi/disks/list_unattached.go +++ b/pkg/cloudapi/disks/list_unattached.go @@ -32,6 +32,14 @@ type ListUnattachedRequest struct { // Required: false AccountID uint64 `url:"accountId,omitempty" json:"accountId,omitempty"` + // Find by sep ID + // Required: false + SEPID uint64 `url:"sepId,omitempty" json:"sepId,omitempty"` + + // Find by pool name + // Required: false + Pool string `url:"pool,omitempty" json:"pool,omitempty"` + // Page number // Required: false Page uint64 `url:"page,omitempty" json:"page,omitempty"` diff --git a/pkg/cloudbroker/compute/disk_del.go b/pkg/cloudbroker/compute/disk_del.go index 86594ae..e7f9d17 100644 --- a/pkg/cloudbroker/compute/disk_del.go +++ b/pkg/cloudbroker/compute/disk_del.go @@ -20,7 +20,7 @@ type DiskDelRequest struct { // False if disk is to be deleted to recycle bin // Required: true - Permanently bool `url:"permanently" json:"permanently" validate:"required"` + Permanently bool `url:"permanently" json:"permanently"` // Reason for action // Required: false diff --git a/pkg/cloudbroker/disks/list_unattached.go b/pkg/cloudbroker/disks/list_unattached.go index 3aa7e63..28ad146 100644 --- a/pkg/cloudbroker/disks/list_unattached.go +++ b/pkg/cloudbroker/disks/list_unattached.go @@ -24,10 +24,6 @@ type ListUnattachedRequest struct { // Required: false Status string `url:"status,omitempty" json:"status,omitempty"` - // Find by shared, true or false - // Required: false - Shared bool `url:"shared,omitempty" json:"shared,omitempty"` - // Type of the disks // Required: false Type string `url:"type,omitempty" json:"type,omitempty"` @@ -36,6 +32,14 @@ type ListUnattachedRequest struct { // Required: false AccountID uint64 `url:"accountId,omitempty" json:"accountId,omitempty"` + // Find by sep ID + // Required: false + SEPID uint64 `url:"sepId,omitempty" json:"sepId,omitempty"` + + // Find by pool name + // Required: false + Pool string `url:"pool,omitempty" json:"pool,omitempty"` + // Page number // Required: false Page uint64 `url:"page,omitempty" json:"page,omitempty"` diff --git a/pkg/cloudbroker/image/delete.go b/pkg/cloudbroker/image/delete.go index 8463c22..4ff7228 100644 --- a/pkg/cloudbroker/image/delete.go +++ b/pkg/cloudbroker/image/delete.go @@ -20,7 +20,7 @@ type DeleteRequest struct { // Whether to completely delete the image // Required: false - Permanently bool `url:"permanently,omitempty" json:"permanently,omitempty"` + Permanently bool `url:"permanently" json:"permanently"` } // Delete deletes image by ID