Update dependencies
Among others, this updates minio-go, so that the new "eu-west-3" zone for AWS is supported.
This commit is contained in:
parent
b63de7c798
commit
2b39f9f4b2
3435 changed files with 1318042 additions and 315692 deletions
99
vendor/google.golang.org/api/storage/v1/storage-api.json
generated
vendored
99
vendor/google.golang.org/api/storage/v1/storage-api.json
generated
vendored
|
@ -1,11 +1,11 @@
|
|||
{
|
||||
"kind": "discovery#restDescription",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/INmkTh2mO0thq3Agrhx1mHd0DoE\"",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/aE5XnXblJMQy68d2aZIGrlTQ05U\"",
|
||||
"discoveryVersion": "v1",
|
||||
"id": "storage:v1",
|
||||
"name": "storage",
|
||||
"version": "v1",
|
||||
"revision": "20171018",
|
||||
"revision": "20171212",
|
||||
"title": "Cloud Storage JSON API",
|
||||
"description": "Stores and retrieves potentially large, immutable data objects.",
|
||||
"ownerDomain": "google.com",
|
||||
|
@ -23,7 +23,7 @@
|
|||
"basePath": "/storage/v1/",
|
||||
"rootUrl": "https://www.googleapis.com/",
|
||||
"servicePath": "storage/v1/",
|
||||
"batchPath": "batch",
|
||||
"batchPath": "batch/storage/v1",
|
||||
"parameters": {
|
||||
"alt": {
|
||||
"type": "string",
|
||||
|
@ -114,7 +114,7 @@
|
|||
"properties": {
|
||||
"requesterPays": {
|
||||
"type": "boolean",
|
||||
"description": "When set to true, bucket is requester pays."
|
||||
"description": "When set to true, Requester Pays is enabled for this bucket."
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -153,6 +153,10 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"defaultEventBasedHold": {
|
||||
"type": "boolean",
|
||||
"description": "Defines the default value for Event-Based hold on newly created objects in this bucket. Event-Based hold is a way to retain objects indefinitely until an event occurs, signified by the hold's release. After being released, such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here bucket-level retention is 3 years and the event is loan being paid in full. In this example these objects will be held intact for any number of years until the event has occurred (hold is released) and then 3 more years after that. Objects under Event-Based hold cannot be deleted, overwritten or archived until the hold is removed."
|
||||
},
|
||||
"defaultObjectAcl": {
|
||||
"type": "array",
|
||||
"description": "Default access controls to apply to new objects when no ACL is provided.",
|
||||
|
@ -165,7 +169,8 @@
|
|||
"description": "Encryption configuration used by default for newly inserted objects, when no encryption config is specified.",
|
||||
"properties": {
|
||||
"defaultKmsKeyName": {
|
||||
"type": "string"
|
||||
"type": "string",
|
||||
"description": "A Cloud KMS key that will be used to encrypt objects inserted into this bucket, if no encryption method is specified. Limited availability; usable only by enabled projects."
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -175,7 +180,7 @@
|
|||
},
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "The ID of the bucket. For buckets, the id and name properities are the same."
|
||||
"description": "The ID of the bucket. For buckets, the id and name properties are the same."
|
||||
},
|
||||
"kind": {
|
||||
"type": "string",
|
||||
|
@ -302,6 +307,26 @@
|
|||
"description": "The project number of the project the bucket belongs to.",
|
||||
"format": "uint64"
|
||||
},
|
||||
"retentionPolicy": {
|
||||
"type": "object",
|
||||
"description": "Defines the retention policy for a bucket. The Retention policy enforces a minimum retention time for all objects contained in the bucket, based on their creation time. Any attempt to overwrite or delete objects younger than the retention period will result in a PERMISSION_DENIED error. An unlocked retention policy can be modified or removed from the bucket via the UpdateBucketMetadata RPC. A locked retention policy cannot be removed or shortened in duration for the lifetime of the bucket. Attempting to remove or decrease period of a locked retention policy will result in a PERMISSION_DENIED error.",
|
||||
"properties": {
|
||||
"effectiveTime": {
|
||||
"type": "string",
|
||||
"description": "The time from which policy was enforced and effective. RFC 3339 format.",
|
||||
"format": "date-time"
|
||||
},
|
||||
"isLocked": {
|
||||
"type": "boolean",
|
||||
"description": "Once locked, an object retention policy cannot be modified."
|
||||
},
|
||||
"retentionPeriod": {
|
||||
"type": "string",
|
||||
"description": "Specifies the duration that objects need to be retained. Retention duration must be greater than zero and less than 100 years. Note that enforcement of retention periods less than a day is not guaranteed. Such periods should only be used for testing purposes.",
|
||||
"format": "int64"
|
||||
}
|
||||
}
|
||||
},
|
||||
"selfLink": {
|
||||
"type": "string",
|
||||
"description": "The URI of this bucket."
|
||||
|
@ -607,7 +632,12 @@
|
|||
"payload_format": {
|
||||
"type": "string",
|
||||
"description": "The desired content of the Payload.",
|
||||
"default": "JSON_API_V1"
|
||||
"default": "JSON_API_V1",
|
||||
"annotations": {
|
||||
"required": [
|
||||
"storage.notifications.insert"
|
||||
]
|
||||
}
|
||||
},
|
||||
"selfLink": {
|
||||
"type": "string",
|
||||
|
@ -711,6 +741,10 @@
|
|||
"type": "string",
|
||||
"description": "HTTP 1.1 Entity tag for the object."
|
||||
},
|
||||
"eventBasedHold": {
|
||||
"type": "boolean",
|
||||
"description": "Defines the Event-Based hold for an object. Event-Based hold is a way to retain objects indefinitely until an event occurs, signified by the hold's release. After being released, such objects will be subject to bucket-level retention (if any). One sample use case of this flag is for banks to hold loan documents for at least 3 years after loan is paid in full. Here bucket-level retention is 3 years and the event is loan being paid in full. In this example these objects will be held intact for any number of years until the event has occurred (hold is released) and then 3 more years after that."
|
||||
},
|
||||
"generation": {
|
||||
"type": "string",
|
||||
"description": "The content generation of this object. Used for object versioning.",
|
||||
|
@ -727,7 +761,7 @@
|
|||
},
|
||||
"kmsKeyName": {
|
||||
"type": "string",
|
||||
"description": "Cloud KMS Key used to encrypt this object, if the object is encrypted by such a key."
|
||||
"description": "Cloud KMS Key used to encrypt this object, if the object is encrypted by such a key. Limited availability; usable only by enabled projects."
|
||||
},
|
||||
"md5Hash": {
|
||||
"type": "string",
|
||||
|
@ -768,6 +802,11 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"retentionExpirationTime": {
|
||||
"type": "string",
|
||||
"description": "Specifies the earliest time that the object's retention period expires. This value is server-determined and is in RFC 3339 format. Note 1: This field is not provided for objects with an active Event-Based hold, since retention expiration is unknown until the hold is removed. Note 2: This value can be provided even when TemporaryHold is set (so that the user can reason about policy without having to first unset the TemporaryHold).",
|
||||
"format": "date-time"
|
||||
},
|
||||
"selfLink": {
|
||||
"type": "string",
|
||||
"description": "The link to this object."
|
||||
|
@ -781,6 +820,10 @@
|
|||
"type": "string",
|
||||
"description": "Storage class of the object."
|
||||
},
|
||||
"temporaryHold": {
|
||||
"type": "boolean",
|
||||
"description": "Defines the temporary hold for an object. This flag is used to enforce a temporary hold on an object. While it is set to true, the object is protected against deletion and overwrites. A common use case of this flag is regulatory investigations where objects need to be retained while the investigation is ongoing."
|
||||
},
|
||||
"timeCreated": {
|
||||
"type": "string",
|
||||
"description": "The creation time of the object in RFC 3339 format.",
|
||||
|
@ -1559,6 +1602,44 @@
|
|||
"https://www.googleapis.com/auth/devstorage.read_write"
|
||||
]
|
||||
},
|
||||
"lockRetentionPolicy": {
|
||||
"id": "storage.buckets.lockRetentionPolicy",
|
||||
"path": "b/{bucket}/lockRetentionPolicy",
|
||||
"httpMethod": "POST",
|
||||
"description": "Locks retention policy on a bucket.",
|
||||
"parameters": {
|
||||
"bucket": {
|
||||
"type": "string",
|
||||
"description": "Name of a bucket.",
|
||||
"required": true,
|
||||
"location": "path"
|
||||
},
|
||||
"ifMetagenerationMatch": {
|
||||
"type": "string",
|
||||
"description": "Makes the operation conditional on whether bucket's current metageneration matches the given value.",
|
||||
"required": true,
|
||||
"format": "int64",
|
||||
"location": "query"
|
||||
},
|
||||
"userProject": {
|
||||
"type": "string",
|
||||
"description": "The project to be billed for this request. Required for Requester Pays buckets.",
|
||||
"location": "query"
|
||||
}
|
||||
},
|
||||
"parameterOrder": [
|
||||
"bucket",
|
||||
"ifMetagenerationMatch"
|
||||
],
|
||||
"response": {
|
||||
"$ref": "Bucket"
|
||||
},
|
||||
"scopes": [
|
||||
"https://www.googleapis.com/auth/cloud-platform",
|
||||
"https://www.googleapis.com/auth/devstorage.full_control",
|
||||
"https://www.googleapis.com/auth/devstorage.read_write"
|
||||
]
|
||||
},
|
||||
"patch": {
|
||||
"id": "storage.buckets.patch",
|
||||
"path": "b/{bucket}",
|
||||
|
@ -2963,7 +3044,7 @@
|
|||
},
|
||||
"kmsKeyName": {
|
||||
"type": "string",
|
||||
"description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.",
|
||||
"description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any. Limited availability; usable only by enabled projects.",
|
||||
"location": "query"
|
||||
},
|
||||
"name": {
|
||||
|
|
266
vendor/google.golang.org/api/storage/v1/storage-gen.go
generated
vendored
266
vendor/google.golang.org/api/storage/v1/storage-gen.go
generated
vendored
|
@ -204,6 +204,20 @@ type Bucket struct {
|
|||
// configuration.
|
||||
Cors []*BucketCors `json:"cors,omitempty"`
|
||||
|
||||
// DefaultEventBasedHold: Defines the default value for Event-Based hold
|
||||
// on newly created objects in this bucket. Event-Based hold is a way to
|
||||
// retain objects indefinitely until an event occurs, signified by the
|
||||
// hold's release. After being released, such objects will be subject to
|
||||
// bucket-level retention (if any). One sample use case of this flag is
|
||||
// for banks to hold loan documents for at least 3 years after loan is
|
||||
// paid in full. Here bucket-level retention is 3 years and the event is
|
||||
// loan being paid in full. In this example these objects will be held
|
||||
// intact for any number of years until the event has occurred (hold is
|
||||
// released) and then 3 more years after that. Objects under Event-Based
|
||||
// hold cannot be deleted, overwritten or archived until the hold is
|
||||
// removed.
|
||||
DefaultEventBasedHold bool `json:"defaultEventBasedHold,omitempty"`
|
||||
|
||||
// DefaultObjectAcl: Default access controls to apply to new objects
|
||||
// when no ACL is provided.
|
||||
DefaultObjectAcl []*ObjectAccessControl `json:"defaultObjectAcl,omitempty"`
|
||||
|
@ -215,8 +229,8 @@ type Bucket struct {
|
|||
// Etag: HTTP 1.1 Entity tag for the bucket.
|
||||
Etag string `json:"etag,omitempty"`
|
||||
|
||||
// Id: The ID of the bucket. For buckets, the id and name properities
|
||||
// are the same.
|
||||
// Id: The ID of the bucket. For buckets, the id and name properties are
|
||||
// the same.
|
||||
Id string `json:"id,omitempty"`
|
||||
|
||||
// Kind: The kind of item this is. For buckets, this is always
|
||||
|
@ -254,6 +268,18 @@ type Bucket struct {
|
|||
// to.
|
||||
ProjectNumber uint64 `json:"projectNumber,omitempty,string"`
|
||||
|
||||
// RetentionPolicy: Defines the retention policy for a bucket. The
|
||||
// Retention policy enforces a minimum retention time for all objects
|
||||
// contained in the bucket, based on their creation time. Any attempt to
|
||||
// overwrite or delete objects younger than the retention period will
|
||||
// result in a PERMISSION_DENIED error. An unlocked retention policy can
|
||||
// be modified or removed from the bucket via the UpdateBucketMetadata
|
||||
// RPC. A locked retention policy cannot be removed or shortened in
|
||||
// duration for the lifetime of the bucket. Attempting to remove or
|
||||
// decrease period of a locked retention policy will result in a
|
||||
// PERMISSION_DENIED error.
|
||||
RetentionPolicy *BucketRetentionPolicy `json:"retentionPolicy,omitempty"`
|
||||
|
||||
// SelfLink: The URI of this bucket.
|
||||
SelfLink string `json:"selfLink,omitempty"`
|
||||
|
||||
|
@ -309,7 +335,8 @@ func (s *Bucket) MarshalJSON() ([]byte, error) {
|
|||
|
||||
// BucketBilling: The bucket's billing configuration.
|
||||
type BucketBilling struct {
|
||||
// RequesterPays: When set to true, bucket is requester pays.
|
||||
// RequesterPays: When set to true, Requester Pays is enabled for this
|
||||
// bucket.
|
||||
RequesterPays bool `json:"requesterPays,omitempty"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "RequesterPays") to
|
||||
|
@ -381,6 +408,9 @@ func (s *BucketCors) MarshalJSON() ([]byte, error) {
|
|||
// BucketEncryption: Encryption configuration used by default for newly
|
||||
// inserted objects, when no encryption config is specified.
|
||||
type BucketEncryption struct {
|
||||
// DefaultKmsKeyName: A Cloud KMS key that will be used to encrypt
|
||||
// objects inserted into this bucket, if no encryption method is
|
||||
// specified. Limited availability; usable only by enabled projects.
|
||||
DefaultKmsKeyName string `json:"defaultKmsKeyName,omitempty"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "DefaultKmsKeyName")
|
||||
|
@ -617,6 +647,54 @@ func (s *BucketOwner) MarshalJSON() ([]byte, error) {
|
|||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// BucketRetentionPolicy: Defines the retention policy for a bucket. The
|
||||
// Retention policy enforces a minimum retention time for all objects
|
||||
// contained in the bucket, based on their creation time. Any attempt to
|
||||
// overwrite or delete objects younger than the retention period will
|
||||
// result in a PERMISSION_DENIED error. An unlocked retention policy can
|
||||
// be modified or removed from the bucket via the UpdateBucketMetadata
|
||||
// RPC. A locked retention policy cannot be removed or shortened in
|
||||
// duration for the lifetime of the bucket. Attempting to remove or
|
||||
// decrease period of a locked retention policy will result in a
|
||||
// PERMISSION_DENIED error.
|
||||
type BucketRetentionPolicy struct {
|
||||
// EffectiveTime: The time from which policy was enforced and effective.
|
||||
// RFC 3339 format.
|
||||
EffectiveTime string `json:"effectiveTime,omitempty"`
|
||||
|
||||
// IsLocked: Once locked, an object retention policy cannot be modified.
|
||||
IsLocked bool `json:"isLocked,omitempty"`
|
||||
|
||||
// RetentionPeriod: Specifies the duration that objects need to be
|
||||
// retained. Retention duration must be greater than zero and less than
|
||||
// 100 years. Note that enforcement of retention periods less than a day
|
||||
// is not guaranteed. Such periods should only be used for testing
|
||||
// purposes.
|
||||
RetentionPeriod int64 `json:"retentionPeriod,omitempty,string"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "EffectiveTime") to
|
||||
// unconditionally include in API requests. By default, fields with
|
||||
// empty values are omitted from API requests. However, any non-pointer,
|
||||
// non-interface field appearing in ForceSendFields will be sent to the
|
||||
// server regardless of whether the field is empty or not. This may be
|
||||
// used to include empty fields in Patch requests.
|
||||
ForceSendFields []string `json:"-"`
|
||||
|
||||
// NullFields is a list of field names (e.g. "EffectiveTime") to include
|
||||
// in API requests with the JSON null value. By default, fields with
|
||||
// empty values are omitted from API requests. However, any field with
|
||||
// an empty value appearing in NullFields will be sent to the server as
|
||||
// null. It is an error if a field in this list has a non-empty value.
|
||||
// This may be used to include null fields in Patch requests.
|
||||
NullFields []string `json:"-"`
|
||||
}
|
||||
|
||||
func (s *BucketRetentionPolicy) MarshalJSON() ([]byte, error) {
|
||||
type NoMethod BucketRetentionPolicy
|
||||
raw := NoMethod(*s)
|
||||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// BucketVersioning: The bucket's versioning configuration.
|
||||
type BucketVersioning struct {
|
||||
// Enabled: While set to true, versioning is fully enabled for this
|
||||
|
@ -1185,6 +1263,18 @@ type Object struct {
|
|||
// Etag: HTTP 1.1 Entity tag for the object.
|
||||
Etag string `json:"etag,omitempty"`
|
||||
|
||||
// EventBasedHold: Defines the Event-Based hold for an object.
|
||||
// Event-Based hold is a way to retain objects indefinitely until an
|
||||
// event occurs, signified by the hold's release. After being released,
|
||||
// such objects will be subject to bucket-level retention (if any). One
|
||||
// sample use case of this flag is for banks to hold loan documents for
|
||||
// at least 3 years after loan is paid in full. Here bucket-level
|
||||
// retention is 3 years and the event is loan being paid in full. In
|
||||
// this example these objects will be held intact for any number of
|
||||
// years until the event has occurred (hold is released) and then 3 more
|
||||
// years after that.
|
||||
EventBasedHold bool `json:"eventBasedHold,omitempty"`
|
||||
|
||||
// Generation: The content generation of this object. Used for object
|
||||
// versioning.
|
||||
Generation int64 `json:"generation,omitempty,string"`
|
||||
|
@ -1198,7 +1288,8 @@ type Object struct {
|
|||
Kind string `json:"kind,omitempty"`
|
||||
|
||||
// KmsKeyName: Cloud KMS Key used to encrypt this object, if the object
|
||||
// is encrypted by such a key.
|
||||
// is encrypted by such a key. Limited availability; usable only by
|
||||
// enabled projects.
|
||||
KmsKeyName string `json:"kmsKeyName,omitempty"`
|
||||
|
||||
// Md5Hash: MD5 hash of the data; encoded using base64. For more
|
||||
|
@ -1226,6 +1317,15 @@ type Object struct {
|
|||
// the object.
|
||||
Owner *ObjectOwner `json:"owner,omitempty"`
|
||||
|
||||
// RetentionExpirationTime: Specifies the earliest time that the
|
||||
// object's retention period expires. This value is server-determined
|
||||
// and is in RFC 3339 format. Note 1: This field is not provided for
|
||||
// objects with an active Event-Based hold, since retention expiration
|
||||
// is unknown until the hold is removed. Note 2: This value can be
|
||||
// provided even when TemporaryHold is set (so that the user can reason
|
||||
// about policy without having to first unset the TemporaryHold).
|
||||
RetentionExpirationTime string `json:"retentionExpirationTime,omitempty"`
|
||||
|
||||
// SelfLink: The link to this object.
|
||||
SelfLink string `json:"selfLink,omitempty"`
|
||||
|
||||
|
@ -1235,6 +1335,13 @@ type Object struct {
|
|||
// StorageClass: Storage class of the object.
|
||||
StorageClass string `json:"storageClass,omitempty"`
|
||||
|
||||
// TemporaryHold: Defines the temporary hold for an object. This flag is
|
||||
// used to enforce a temporary hold on an object. While it is set to
|
||||
// true, the object is protected against deletion and overwrites. A
|
||||
// common use case of this flag is regulatory investigations where
|
||||
// objects need to be retained while the investigation is ongoing.
|
||||
TemporaryHold bool `json:"temporaryHold,omitempty"`
|
||||
|
||||
// TimeCreated: The creation time of the object in RFC 3339 format.
|
||||
TimeCreated string `json:"timeCreated,omitempty"`
|
||||
|
||||
|
@ -3687,6 +3794,152 @@ func (c *BucketsListCall) Pages(ctx context.Context, f func(*Buckets) error) err
|
|||
}
|
||||
}
|
||||
|
||||
// method id "storage.buckets.lockRetentionPolicy":
|
||||
|
||||
type BucketsLockRetentionPolicyCall struct {
|
||||
s *Service
|
||||
bucket string
|
||||
urlParams_ gensupport.URLParams
|
||||
ctx_ context.Context
|
||||
header_ http.Header
|
||||
}
|
||||
|
||||
// LockRetentionPolicy: Locks retention policy on a bucket.
|
||||
func (r *BucketsService) LockRetentionPolicy(bucket string, ifMetagenerationMatch int64) *BucketsLockRetentionPolicyCall {
|
||||
c := &BucketsLockRetentionPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
|
||||
c.bucket = bucket
|
||||
c.urlParams_.Set("ifMetagenerationMatch", fmt.Sprint(ifMetagenerationMatch))
|
||||
return c
|
||||
}
|
||||
|
||||
// UserProject sets the optional parameter "userProject": The project to
|
||||
// be billed for this request. Required for Requester Pays buckets.
|
||||
func (c *BucketsLockRetentionPolicyCall) UserProject(userProject string) *BucketsLockRetentionPolicyCall {
|
||||
c.urlParams_.Set("userProject", userProject)
|
||||
return c
|
||||
}
|
||||
|
||||
// Fields allows partial responses to be retrieved. See
|
||||
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
|
||||
// for more information.
|
||||
func (c *BucketsLockRetentionPolicyCall) Fields(s ...googleapi.Field) *BucketsLockRetentionPolicyCall {
|
||||
c.urlParams_.Set("fields", googleapi.CombineFields(s))
|
||||
return c
|
||||
}
|
||||
|
||||
// Context sets the context to be used in this call's Do method. Any
|
||||
// pending HTTP request will be aborted if the provided context is
|
||||
// canceled.
|
||||
func (c *BucketsLockRetentionPolicyCall) Context(ctx context.Context) *BucketsLockRetentionPolicyCall {
|
||||
c.ctx_ = ctx
|
||||
return c
|
||||
}
|
||||
|
||||
// Header returns an http.Header that can be modified by the caller to
|
||||
// add HTTP headers to the request.
|
||||
func (c *BucketsLockRetentionPolicyCall) Header() http.Header {
|
||||
if c.header_ == nil {
|
||||
c.header_ = make(http.Header)
|
||||
}
|
||||
return c.header_
|
||||
}
|
||||
|
||||
func (c *BucketsLockRetentionPolicyCall) doRequest(alt string) (*http.Response, error) {
|
||||
reqHeaders := make(http.Header)
|
||||
for k, v := range c.header_ {
|
||||
reqHeaders[k] = v
|
||||
}
|
||||
reqHeaders.Set("User-Agent", c.s.userAgent())
|
||||
var body io.Reader = nil
|
||||
c.urlParams_.Set("alt", alt)
|
||||
urls := googleapi.ResolveRelative(c.s.BasePath, "b/{bucket}/lockRetentionPolicy")
|
||||
urls += "?" + c.urlParams_.Encode()
|
||||
req, _ := http.NewRequest("POST", urls, body)
|
||||
req.Header = reqHeaders
|
||||
googleapi.Expand(req.URL, map[string]string{
|
||||
"bucket": c.bucket,
|
||||
})
|
||||
return gensupport.SendRequest(c.ctx_, c.s.client, req)
|
||||
}
|
||||
|
||||
// Do executes the "storage.buckets.lockRetentionPolicy" call.
|
||||
// Exactly one of *Bucket or error will be non-nil. Any non-2xx status
|
||||
// code is an error. Response headers are in either
|
||||
// *Bucket.ServerResponse.Header or (if a response was returned at all)
|
||||
// in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
|
||||
// check whether the returned error was because http.StatusNotModified
|
||||
// was returned.
|
||||
func (c *BucketsLockRetentionPolicyCall) Do(opts ...googleapi.CallOption) (*Bucket, error) {
|
||||
gensupport.SetOptions(c.urlParams_, opts...)
|
||||
res, err := c.doRequest("json")
|
||||
if res != nil && res.StatusCode == http.StatusNotModified {
|
||||
if res.Body != nil {
|
||||
res.Body.Close()
|
||||
}
|
||||
return nil, &googleapi.Error{
|
||||
Code: res.StatusCode,
|
||||
Header: res.Header,
|
||||
}
|
||||
}
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
defer googleapi.CloseBody(res)
|
||||
if err := googleapi.CheckResponse(res); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
ret := &Bucket{
|
||||
ServerResponse: googleapi.ServerResponse{
|
||||
Header: res.Header,
|
||||
HTTPStatusCode: res.StatusCode,
|
||||
},
|
||||
}
|
||||
target := &ret
|
||||
if err := gensupport.DecodeResponse(target, res); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return ret, nil
|
||||
// {
|
||||
// "description": "Locks retention policy on a bucket.",
|
||||
// "httpMethod": "POST",
|
||||
// "id": "storage.buckets.lockRetentionPolicy",
|
||||
// "parameterOrder": [
|
||||
// "bucket",
|
||||
// "ifMetagenerationMatch"
|
||||
// ],
|
||||
// "parameters": {
|
||||
// "bucket": {
|
||||
// "description": "Name of a bucket.",
|
||||
// "location": "path",
|
||||
// "required": true,
|
||||
// "type": "string"
|
||||
// },
|
||||
// "ifMetagenerationMatch": {
|
||||
// "description": "Makes the operation conditional on whether bucket's current metageneration matches the given value.",
|
||||
// "format": "int64",
|
||||
// "location": "query",
|
||||
// "required": true,
|
||||
// "type": "string"
|
||||
// },
|
||||
// "userProject": {
|
||||
// "description": "The project to be billed for this request. Required for Requester Pays buckets.",
|
||||
// "location": "query",
|
||||
// "type": "string"
|
||||
// }
|
||||
// },
|
||||
// "path": "b/{bucket}/lockRetentionPolicy",
|
||||
// "response": {
|
||||
// "$ref": "Bucket"
|
||||
// },
|
||||
// "scopes": [
|
||||
// "https://www.googleapis.com/auth/cloud-platform",
|
||||
// "https://www.googleapis.com/auth/devstorage.full_control",
|
||||
// "https://www.googleapis.com/auth/devstorage.read_write"
|
||||
// ]
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
// method id "storage.buckets.patch":
|
||||
|
||||
type BucketsPatchCall struct {
|
||||
|
@ -8534,7 +8787,8 @@ func (c *ObjectsInsertCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in
|
|||
// the Cloud KMS key, of the form
|
||||
// projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key,
|
||||
// that will be used to encrypt the object. Overrides the object
|
||||
// metadata's kms_key_name value, if any.
|
||||
// metadata's kms_key_name value, if any. Limited availability; usable
|
||||
// only by enabled projects.
|
||||
func (c *ObjectsInsertCall) KmsKeyName(kmsKeyName string) *ObjectsInsertCall {
|
||||
c.urlParams_.Set("kmsKeyName", kmsKeyName)
|
||||
return c
|
||||
|
@ -8801,7 +9055,7 @@ func (c *ObjectsInsertCall) Do(opts ...googleapi.CallOption) (*Object, error) {
|
|||
// "type": "string"
|
||||
// },
|
||||
// "kmsKeyName": {
|
||||
// "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any.",
|
||||
// "description": "Resource name of the Cloud KMS key, of the form projects/my-project/locations/global/keyRings/my-kr/cryptoKeys/my-key, that will be used to encrypt the object. Overrides the object metadata's kms_key_name value, if any. Limited availability; usable only by enabled projects.",
|
||||
// "location": "query",
|
||||
// "type": "string"
|
||||
// },
|
||||
|
|
6
vendor/google.golang.org/api/storage/v1beta1/storage-api.json
generated
vendored
6
vendor/google.golang.org/api/storage/v1beta1/storage-api.json
generated
vendored
|
@ -1,11 +1,11 @@
|
|||
{
|
||||
"kind": "discovery#restDescription",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/bcRJYHI3-5nsBo04628_tSK-f84\"",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/MFBsd0cpXUnMtbb1xXb83mhHiCc\"",
|
||||
"discoveryVersion": "v1",
|
||||
"id": "storage:v1beta1",
|
||||
"name": "storage",
|
||||
"version": "v1beta1",
|
||||
"revision": "20170830",
|
||||
"revision": "20171212",
|
||||
"title": "Cloud Storage JSON API",
|
||||
"description": "Lets you store and retrieve potentially-large, immutable data objects.",
|
||||
"ownerDomain": "google.com",
|
||||
|
@ -23,7 +23,7 @@
|
|||
"basePath": "/storage/v1beta1/",
|
||||
"rootUrl": "https://www.googleapis.com/",
|
||||
"servicePath": "storage/v1beta1/",
|
||||
"batchPath": "batch",
|
||||
"batchPath": "batch/storage/v1beta1",
|
||||
"parameters": {
|
||||
"alt": {
|
||||
"type": "string",
|
||||
|
|
6
vendor/google.golang.org/api/storage/v1beta2/storage-api.json
generated
vendored
6
vendor/google.golang.org/api/storage/v1beta2/storage-api.json
generated
vendored
|
@ -1,11 +1,11 @@
|
|||
{
|
||||
"kind": "discovery#restDescription",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/-kx4VTo0WtGqkEZqxSfkCE_3vyg\"",
|
||||
"etag": "\"YWOzh2SDasdU84ArJnpYek-OMdg/jNAmDp5ax698Gc_lJBs4IFA1034\"",
|
||||
"discoveryVersion": "v1",
|
||||
"id": "storage:v1beta2",
|
||||
"name": "storage",
|
||||
"version": "v1beta2",
|
||||
"revision": "20170830",
|
||||
"revision": "20171212",
|
||||
"title": "Cloud Storage JSON API",
|
||||
"description": "Lets you store and retrieve potentially-large, immutable data objects.",
|
||||
"ownerDomain": "google.com",
|
||||
|
@ -23,7 +23,7 @@
|
|||
"basePath": "/storage/v1beta2/",
|
||||
"rootUrl": "https://www.googleapis.com/",
|
||||
"servicePath": "storage/v1beta2/",
|
||||
"batchPath": "batch",
|
||||
"batchPath": "batch/storage/v1beta2",
|
||||
"parameters": {
|
||||
"alt": {
|
||||
"type": "string",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue