mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/yunionio/cloudpods.git
synced 2026-09-20 08:03:53 +08:00
fix(region): vendor update (#23903)
This commit is contained in:
4
go.mod
4
go.mod
@@ -27,6 +27,7 @@ require (
|
||||
github.com/go-yaml/yaml v2.1.0+incompatible
|
||||
github.com/golang-plus/uuid v1.0.0
|
||||
github.com/golang/mock v1.4.4
|
||||
github.com/golang/protobuf v1.5.4
|
||||
github.com/google/cadvisor v0.38.5
|
||||
github.com/google/gopacket v1.1.17
|
||||
github.com/google/uuid v1.6.0
|
||||
@@ -98,7 +99,7 @@ require (
|
||||
k8s.io/cri-api v0.28.15
|
||||
k8s.io/klog/v2 v2.20.0
|
||||
moul.io/http2curl/v2 v2.3.0
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251202110347-66e60ae88e4f
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251205085757-3dc9b243b5c2
|
||||
yunion.io/x/executor v0.0.0-20250518005516-5402e9e0bed0
|
||||
yunion.io/x/jsonutils v1.0.1-0.20250507052344-1abcf4f443b1
|
||||
yunion.io/x/log v1.0.1-0.20240305175729-7cf2d6cd5a91
|
||||
@@ -233,7 +234,6 @@ require (
|
||||
github.com/gogo/protobuf v1.3.2 // indirect
|
||||
github.com/golang-plus/errors v1.0.0 // indirect
|
||||
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
|
||||
github.com/golang/protobuf v1.5.4 // indirect
|
||||
github.com/golang/snappy v0.0.4 // indirect
|
||||
github.com/google/btree v1.1.2 // indirect
|
||||
github.com/google/go-querystring v1.0.0 // indirect
|
||||
|
||||
4
go.sum
4
go.sum
@@ -1661,8 +1661,8 @@ sigs.k8s.io/structured-merge-diff/v4 v4.0.1/go.mod h1:bJZC9H9iH24zzfZ/41RGcq60oK
|
||||
sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
|
||||
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
|
||||
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251202110347-66e60ae88e4f h1:XbF3dPkwrLs9ndX8QP23EGFljbnkII76UjPDKeIJvhA=
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251202110347-66e60ae88e4f/go.mod h1:aWRX5Phwz3nbHUNnIAm1oVogjguXPYDDgCOy/9Hnnvk=
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251205085757-3dc9b243b5c2 h1:Im0mZviWDEU5EN1fPoWJwcrGb6u9OxY7oqyYE0PLlHg=
|
||||
yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251205085757-3dc9b243b5c2/go.mod h1:aWRX5Phwz3nbHUNnIAm1oVogjguXPYDDgCOy/9Hnnvk=
|
||||
yunion.io/x/executor v0.0.0-20250518005516-5402e9e0bed0 h1:msG4SiDSVU7CrXH06WuHlNEZXIooTcmNbfrIGHuIHBU=
|
||||
yunion.io/x/executor v0.0.0-20250518005516-5402e9e0bed0/go.mod h1:Uxuou9WQIeJXNpy7t2fPLL0BYLvLiMvGQwY7Qc6aSws=
|
||||
yunion.io/x/jsonutils v0.0.0-20190625054549-a964e1e8a051/go.mod h1:4N0/RVzsYL3kH3WE/H1BjUQdFiWu50JGCFQuuy+Z634=
|
||||
|
||||
@@ -94,20 +94,20 @@ func (self *SBaiduGuestDriver) GetInstanceCapability() cloudprovider.SInstanceCa
|
||||
},
|
||||
Storages: cloudprovider.Storage{
|
||||
DataDisk: []cloudprovider.StorageInfo{
|
||||
{StorageType: api.STORAGE_BAIDU_SSD, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_PREMIUM_SSD, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_HDD, MaxSizeGb: 32765, MinSizeGb: 5, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL1, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL2, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL3, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_SSD, MaxSizeGb: 65536, MinSizeGb: 5, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_PREMIUM_SSD, MaxSizeGb: 65536, MinSizeGb: 20, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_HDD, MaxSizeGb: 65536, MinSizeGb: 5, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL1, MaxSizeGb: 65536, MinSizeGb: 5, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL2, MaxSizeGb: 65536, MinSizeGb: 461, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL3, MaxSizeGb: 65536, MinSizeGb: 1261, StepSizeGb: 1, Resizable: true},
|
||||
},
|
||||
SysDisk: []cloudprovider.StorageInfo{
|
||||
{StorageType: api.STORAGE_BAIDU_SSD, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_PREMIUM_SSD, MaxSizeGb: 32765, MinSizeGb: 20, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_HDD, MaxSizeGb: 32765, MinSizeGb: 20, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL1, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL2, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL3, MaxSizeGb: 32765, MinSizeGb: 50, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_SSD, MaxSizeGb: 20480, MinSizeGb: 10, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_PREMIUM_SSD, MaxSizeGb: 20480, MinSizeGb: 10, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_HDD, MaxSizeGb: 20480, MinSizeGb: 10, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL1, MaxSizeGb: 20480, MinSizeGb: 20, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL2, MaxSizeGb: 20480, MinSizeGb: 461, StepSizeGb: 1, Resizable: true},
|
||||
{StorageType: api.STORAGE_BAIDU_ENHANCED_SSD_PL3, MaxSizeGb: 20480, MinSizeGb: 1261, StepSizeGb: 1, Resizable: true},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
2
vendor/modules.txt
vendored
2
vendor/modules.txt
vendored
@@ -2243,7 +2243,7 @@ sigs.k8s.io/structured-merge-diff/v4/value
|
||||
# sigs.k8s.io/yaml v1.2.0
|
||||
## explicit; go 1.12
|
||||
sigs.k8s.io/yaml
|
||||
# yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251202110347-66e60ae88e4f
|
||||
# yunion.io/x/cloudmux v0.3.10-0-alpha.1.0.20251205085757-3dc9b243b5c2
|
||||
## explicit; go 1.24
|
||||
yunion.io/x/cloudmux/pkg/apis
|
||||
yunion.io/x/cloudmux/pkg/apis/billing
|
||||
|
||||
38
vendor/yunion.io/x/cloudmux/pkg/multicloud/baidu/baidu.go
generated
vendored
38
vendor/yunion.io/x/cloudmux/pkg/multicloud/baidu/baidu.go
generated
vendored
@@ -178,7 +178,13 @@ func (cli *SBaiduClient) bosList(regionId, bucketName, resource string, params u
|
||||
return nil, err
|
||||
}
|
||||
_, ret, err := httputils.ParseJSONResponse("", resp, err, cli.debug)
|
||||
return ret, err
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "ParseJSONResponse")
|
||||
}
|
||||
if gotypes.IsNil(ret) {
|
||||
return jsonutils.NewDict(), nil
|
||||
}
|
||||
return ret, nil
|
||||
}
|
||||
|
||||
func (cli *SBaiduClient) bosDelete(regionId, bucketName, resource string, params url.Values) (jsonutils.JSONObject, error) {
|
||||
@@ -187,7 +193,13 @@ func (cli *SBaiduClient) bosDelete(regionId, bucketName, resource string, params
|
||||
return nil, err
|
||||
}
|
||||
_, ret, err := httputils.ParseJSONResponse("", resp, err, cli.debug)
|
||||
return ret, err
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "ParseJSONResponse")
|
||||
}
|
||||
if gotypes.IsNil(ret) {
|
||||
return jsonutils.NewDict(), nil
|
||||
}
|
||||
return ret, nil
|
||||
}
|
||||
|
||||
func (cli *SBaiduClient) bosUpdate(regionId, bucketName, resource string, params url.Values, body map[string]interface{}) (jsonutils.JSONObject, error) {
|
||||
@@ -200,7 +212,13 @@ func (cli *SBaiduClient) bosUpdate(regionId, bucketName, resource string, params
|
||||
return nil, err
|
||||
}
|
||||
_, ret, err := httputils.ParseJSONResponse("", resp, err, cli.debug)
|
||||
return ret, err
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "ParseJSONResponse")
|
||||
}
|
||||
if gotypes.IsNil(ret) {
|
||||
return jsonutils.NewDict(), nil
|
||||
}
|
||||
return ret, nil
|
||||
}
|
||||
|
||||
func (cli *SBaiduClient) bosRequest(method httputils.THttpMethod, regionId, bucketName, resource string, params url.Values, header http.Header, body io.Reader) (*http.Response, error) {
|
||||
@@ -271,7 +289,13 @@ func (cli *SBaiduClient) request(method httputils.THttpMethod, service, regionId
|
||||
return nil, err
|
||||
}
|
||||
_, ret, err := httputils.ParseJSONResponse("", resp, err, cli.debug)
|
||||
return ret, err
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "ParseJSONResponse")
|
||||
}
|
||||
if gotypes.IsNil(ret) {
|
||||
return jsonutils.NewDict(), nil
|
||||
}
|
||||
return ret, nil
|
||||
}
|
||||
|
||||
func (cli *SBaiduClient) raw_request(method httputils.THttpMethod, service, regionId, bucketName, resource string, params url.Values, header http.Header, body io.Reader) (*http.Response, error) {
|
||||
@@ -302,7 +326,11 @@ func (cli *SBaiduClient) raw_request(method httputils.THttpMethod, service, regi
|
||||
}
|
||||
header.Set("Authorization", signature)
|
||||
|
||||
return httputils.Request(cli.getDefaultClient(), cli.ctx, method, uri, header, body, cli.debug)
|
||||
resp, err := httputils.Request(cli.getDefaultClient(), cli.ctx, method, uri, header, body, cli.debug)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return resp, nil
|
||||
}
|
||||
|
||||
func (cli *SBaiduClient) GetSubAccounts() ([]cloudprovider.SSubAccount, error) {
|
||||
|
||||
12
vendor/yunion.io/x/cloudmux/pkg/multicloud/baidu/bucket.go
generated
vendored
12
vendor/yunion.io/x/cloudmux/pkg/multicloud/baidu/bucket.go
generated
vendored
@@ -28,6 +28,7 @@ import (
|
||||
"yunion.io/x/cloudmux/pkg/multicloud"
|
||||
"yunion.io/x/jsonutils"
|
||||
"yunion.io/x/pkg/errors"
|
||||
"yunion.io/x/pkg/gotypes"
|
||||
"yunion.io/x/pkg/util/httputils"
|
||||
)
|
||||
|
||||
@@ -103,6 +104,9 @@ func (b *SBucket) GetTags() (map[string]string, error) {
|
||||
if err != nil {
|
||||
return nil, errors.Wrap(err, "ParseJSONResponse")
|
||||
}
|
||||
if gotypes.IsNil(body) {
|
||||
return nil, nil
|
||||
}
|
||||
ret := struct {
|
||||
Tag []struct {
|
||||
TagKey string `json:"tagKey"`
|
||||
@@ -313,6 +317,9 @@ func (b *SBucket) NewMultipartUpload(ctx context.Context, key string, cannedAcl
|
||||
if err != nil {
|
||||
return "", errors.Wrapf(err, "ParseJSONResponse %s %s", b.Name, key)
|
||||
}
|
||||
if gotypes.IsNil(body) {
|
||||
return "", errors.Errorf("empty response for NewMultipartUpload %s %s", b.Name, key)
|
||||
}
|
||||
return body.GetString("uploadId")
|
||||
}
|
||||
|
||||
@@ -381,6 +388,11 @@ func (b *SBucket) CopyPart(ctx context.Context, key string, uploadId string, par
|
||||
if err != nil {
|
||||
return "", errors.Wrapf(err, "ParseJSONResponse %s %s %s", b.Name, key, uploadId)
|
||||
}
|
||||
|
||||
if gotypes.IsNil(body) {
|
||||
return "", errors.Errorf("empty response for CopyPart %s %s %s %s %d %d", b.Name, key, uploadId, srcBucket, srcOffset, srcLength)
|
||||
}
|
||||
|
||||
return body.GetString("eTag")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user