chore(deps): bump google.golang.org/api from 0.141.0 to 0.142.0 (#2756)
Bumps [google.golang.org/api](https://github.com/googleapis/google-api-go-client) from 0.141.0 to 0.142.0. - [Release notes](https://github.com/googleapis/google-api-go-client/releases) - [Changelog](https://github.com/googleapis/google-api-go-client/blob/main/CHANGES.md) - [Commits](https://github.com/googleapis/google-api-go-client/compare/v0.141.0...v0.142.0) --- updated-dependencies: - dependency-name: google.golang.org/api dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
parent
a144a7872a
commit
75719b1d61
4
go.mod
4
go.mod
|
|
@ -149,7 +149,7 @@ require (
|
|||
golang.org/x/text v0.13.0 // indirect
|
||||
golang.org/x/time v0.1.0 // indirect
|
||||
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
|
||||
google.golang.org/api v0.141.0
|
||||
google.golang.org/api v0.142.0
|
||||
google.golang.org/appengine v1.6.7 // indirect
|
||||
google.golang.org/genproto v0.0.0-20230803162519-f966b187b2e5 // indirect
|
||||
google.golang.org/grpc v1.57.0 // indirect
|
||||
|
|
@ -182,7 +182,7 @@ require (
|
|||
github.com/subosito/gotenv v1.2.0 // indirect
|
||||
github.com/toqueteos/webbrowser v1.2.0 // indirect
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20230803162519-f966b187b2e5 // indirect
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230911183012-2d3300fd4832 // indirect
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230913181813-007df8e322eb // indirect
|
||||
gopkg.in/ini.v1 v1.62.0 // indirect
|
||||
gopkg.in/yaml.v2 v2.4.0 // indirect
|
||||
)
|
||||
|
|
|
|||
8
go.sum
8
go.sum
|
|
@ -1005,8 +1005,8 @@ google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjR
|
|||
google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU=
|
||||
google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94=
|
||||
google.golang.org/api v0.44.0/go.mod h1:EBOGZqzyhtvMDoxwS97ctnh0zUmYY6CxqXsc1AvkYD8=
|
||||
google.golang.org/api v0.141.0 h1:Df6vfMgDoIM6ss0m7H4MPwFwY87WNXHfBIda/Bmfl4E=
|
||||
google.golang.org/api v0.141.0/go.mod h1:iZqLkdPlXKyG0b90eu6KxVSE4D/ccRF2e/doKD2CnQQ=
|
||||
google.golang.org/api v0.142.0 h1:mf+7EJ94fi5ZcnpPy+m0Yv2dkz8bKm+UL0snTCuwXlY=
|
||||
google.golang.org/api v0.142.0/go.mod h1:zJAN5o6HRqR7O+9qJUFOWrZkYE66RH+efPBdTLA4xBA=
|
||||
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
|
||||
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
|
|
@ -1062,8 +1062,8 @@ google.golang.org/genproto v0.0.0-20230803162519-f966b187b2e5 h1:L6iMMGrtzgHsWof
|
|||
google.golang.org/genproto v0.0.0-20230803162519-f966b187b2e5/go.mod h1:oH/ZOT02u4kWEp7oYBGYFFkCdKS/uYR9Z7+0/xuuFp8=
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20230803162519-f966b187b2e5 h1:nIgk/EEq3/YlnmVVXVnm14rC2oxgs1o0ong4sD/rd44=
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20230803162519-f966b187b2e5/go.mod h1:5DZzOUPCLYL3mNkQ0ms0F3EuUNZ7py1Bqeq6sxzI7/Q=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230911183012-2d3300fd4832 h1:o4LtQxebKIJ4vkzyhtD2rfUNZ20Zf0ik5YVP5E7G7VE=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230911183012-2d3300fd4832/go.mod h1:+Bk1OCOj40wS2hwAMA+aCW9ypzm63QTBBHp6lQ3p+9M=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230913181813-007df8e322eb h1:Isk1sSH7bovx8Rti2wZK0UZF6oraBDK74uoyLEEVFN0=
|
||||
google.golang.org/genproto/googleapis/rpc v0.0.0-20230913181813-007df8e322eb/go.mod h1:+Bk1OCOj40wS2hwAMA+aCW9ypzm63QTBBHp6lQ3p+9M=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
|
||||
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ import (
|
|||
"cloud.google.com/go/compute/metadata"
|
||||
)
|
||||
|
||||
const configEndpointSuffix = "googleAutoMtlsConfiguration"
|
||||
const configEndpointSuffix = "instance/platform-security/auto-mtls-configuration"
|
||||
|
||||
// The period an MTLS config can be reused before needing refresh.
|
||||
var configExpiry = time.Hour
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ import (
|
|||
"crypto/tls"
|
||||
"errors"
|
||||
"net/http"
|
||||
"os"
|
||||
"strconv"
|
||||
|
||||
"golang.org/x/oauth2"
|
||||
"golang.org/x/oauth2/google"
|
||||
|
|
@ -16,6 +18,10 @@ import (
|
|||
"google.golang.org/grpc"
|
||||
)
|
||||
|
||||
const (
|
||||
newAuthLibEnVar = "GOOGLE_API_GO_EXPERIMENTAL_USE_NEW_AUTH_LIB"
|
||||
)
|
||||
|
||||
// DialSettings holds information needed to establish a connection with a
|
||||
// Google API service.
|
||||
type DialSettings struct {
|
||||
|
|
@ -47,6 +53,7 @@ type DialSettings struct {
|
|||
ImpersonationConfig *impersonate.Config
|
||||
EnableDirectPath bool
|
||||
EnableDirectPathXds bool
|
||||
EnableNewAuthLibrary bool
|
||||
AllowNonDefaultServiceAccount bool
|
||||
|
||||
// Google API system parameters. For more information please read:
|
||||
|
|
@ -77,6 +84,16 @@ func (ds *DialSettings) HasCustomAudience() bool {
|
|||
return len(ds.Audiences) > 0
|
||||
}
|
||||
|
||||
func (ds *DialSettings) IsNewAuthLibraryEnabled() bool {
|
||||
if ds.EnableNewAuthLibrary {
|
||||
return true
|
||||
}
|
||||
if b, err := strconv.ParseBool(os.Getenv(newAuthLibEnVar)); err == nil {
|
||||
return b
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// Validate reports an error if ds is invalid.
|
||||
func (ds *DialSettings) Validate() error {
|
||||
if ds.SkipValidation {
|
||||
|
|
|
|||
|
|
@ -5,4 +5,4 @@
|
|||
package internal
|
||||
|
||||
// Version is the current tagged release of the library.
|
||||
const Version = "0.141.0"
|
||||
const Version = "0.142.0"
|
||||
|
|
|
|||
|
|
@ -150,6 +150,19 @@ func (w *withCreds) Apply(o *internal.DialSettings) {
|
|||
o.InternalCredentials = (*google.Credentials)(w)
|
||||
}
|
||||
|
||||
// EnableNewAuthLibrary returns a ClientOption that specifies if libraries in this
|
||||
// module to delegate auth to our new library. This option will be removed in
|
||||
// the future once all clients have been moved to the new auth layer.
|
||||
func EnableNewAuthLibrary() option.ClientOption {
|
||||
return enableNewAuthLibrary(true)
|
||||
}
|
||||
|
||||
type enableNewAuthLibrary bool
|
||||
|
||||
func (w enableNewAuthLibrary) Apply(o *internal.DialSettings) {
|
||||
o.EnableNewAuthLibrary = bool(w)
|
||||
}
|
||||
|
||||
// EmbeddableAdapter is a no-op option.ClientOption that allow libraries to
|
||||
// create their own client options by embedding this type into their own
|
||||
// client-specific option wrapper. See example for usage.
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@
|
|||
"description": "Stores and retrieves potentially large, immutable data objects.",
|
||||
"discoveryVersion": "v1",
|
||||
"documentationLink": "https://developers.google.com/storage/docs/json_api/",
|
||||
"etag": "\"3137393534363837313035303430333138303233\"",
|
||||
"etag": "\"3132363038323634353839373135393539313634\"",
|
||||
"icons": {
|
||||
"x16": "https://www.google.com/images/icons/product/cloud_storage-16.png",
|
||||
"x32": "https://www.google.com/images/icons/product/cloud_storage-32.png"
|
||||
|
|
@ -446,6 +446,12 @@
|
|||
"project"
|
||||
],
|
||||
"parameters": {
|
||||
"enableObjectRetention": {
|
||||
"default": "false",
|
||||
"description": "When set to true, object retention is enabled for this bucket.",
|
||||
"location": "query",
|
||||
"type": "boolean"
|
||||
},
|
||||
"predefinedAcl": {
|
||||
"description": "Apply a predefined set of access controls to this bucket.",
|
||||
"enum": [
|
||||
|
|
@ -2295,6 +2301,11 @@
|
|||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
"overrideUnlockedRetention": {
|
||||
"description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.",
|
||||
"location": "query",
|
||||
"type": "boolean"
|
||||
},
|
||||
"predefinedAcl": {
|
||||
"description": "Apply a predefined set of access controls to this object.",
|
||||
"enum": [
|
||||
|
|
@ -2738,6 +2749,11 @@
|
|||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
"overrideUnlockedRetention": {
|
||||
"description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.",
|
||||
"location": "query",
|
||||
"type": "boolean"
|
||||
},
|
||||
"predefinedAcl": {
|
||||
"description": "Apply a predefined set of access controls to this object.",
|
||||
"enum": [
|
||||
|
|
@ -3242,7 +3258,7 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"revision": "20230907",
|
||||
"revision": "20230914",
|
||||
"rootUrl": "https://storage.googleapis.com/",
|
||||
"schemas": {
|
||||
"Bucket": {
|
||||
|
|
@ -3268,6 +3284,15 @@
|
|||
"description": "Whether or not Autoclass is enabled on this bucket",
|
||||
"type": "boolean"
|
||||
},
|
||||
"terminalStorageClass": {
|
||||
"description": "The storage class that objects in the bucket eventually transition to if they are not read for a certain length of time. Valid values are NEARLINE and ARCHIVE.",
|
||||
"type": "string"
|
||||
},
|
||||
"terminalStorageClassUpdateTime": {
|
||||
"description": "A date and time in RFC 3339 format representing the time of the most recent update to \"terminalStorageClass\".",
|
||||
"format": "date-time",
|
||||
"type": "string"
|
||||
},
|
||||
"toggleTime": {
|
||||
"description": "A date and time in RFC 3339 format representing the instant at which \"enabled\" was last toggled.",
|
||||
"format": "date-time",
|
||||
|
|
@ -3551,6 +3576,16 @@
|
|||
"description": "The name of the bucket.",
|
||||
"type": "string"
|
||||
},
|
||||
"objectRetention": {
|
||||
"description": "The bucket's object retention config.",
|
||||
"properties": {
|
||||
"mode": {
|
||||
"description": "The bucket's object retention mode. Can be Enabled.",
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
},
|
||||
"owner": {
|
||||
"description": "The owner of the bucket. This is always the project team's owner group.",
|
||||
"properties": {
|
||||
|
|
@ -3602,6 +3637,22 @@
|
|||
"description": "The URI of this bucket.",
|
||||
"type": "string"
|
||||
},
|
||||
"softDeletePolicy": {
|
||||
"description": "The bucket's soft delete policy, which defines the period of time that soft-deleted objects will be retained, and cannot be permanently deleted.",
|
||||
"properties": {
|
||||
"effectiveTime": {
|
||||
"description": "Server-determined value that indicates the time from which the policy, or one with a greater retention, was effective. This value is in RFC 3339 format.",
|
||||
"format": "date-time",
|
||||
"type": "string"
|
||||
},
|
||||
"retentionDurationSeconds": {
|
||||
"description": "The period of time in seconds, that soft-deleted objects in the bucket will be retained and cannot be permanently deleted.",
|
||||
"format": "int64",
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
},
|
||||
"storageClass": {
|
||||
"description": "The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, ARCHIVE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes.",
|
||||
"type": "string"
|
||||
|
|
@ -4306,6 +4357,21 @@
|
|||
},
|
||||
"type": "object"
|
||||
},
|
||||
"retention": {
|
||||
"description": "A collection of object level retention parameters.",
|
||||
"properties": {
|
||||
"mode": {
|
||||
"description": "The bucket's object retention mode, can only be Unlocked or Locked.",
|
||||
"type": "string"
|
||||
},
|
||||
"retainUntilTime": {
|
||||
"description": "A time in RFC 3339 format until which object retention protects this object.",
|
||||
"format": "date-time",
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"type": "object"
|
||||
},
|
||||
"retentionExpirationTime": {
|
||||
"description": "A server-determined value that specifies the earliest time that the object's retention period expires. This value 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 temporary hold is set (so that the user can reason about policy without having to first unset the temporary hold).",
|
||||
"format": "date-time",
|
||||
|
|
|
|||
|
|
@ -385,6 +385,9 @@ type Bucket struct {
|
|||
// Name: The name of the bucket.
|
||||
Name string `json:"name,omitempty"`
|
||||
|
||||
// ObjectRetention: The bucket's object retention config.
|
||||
ObjectRetention *BucketObjectRetention `json:"objectRetention,omitempty"`
|
||||
|
||||
// Owner: The owner of the bucket. This is always the project team's
|
||||
// owner group.
|
||||
Owner *BucketOwner `json:"owner,omitempty"`
|
||||
|
|
@ -415,6 +418,11 @@ type Bucket struct {
|
|||
// SelfLink: The URI of this bucket.
|
||||
SelfLink string `json:"selfLink,omitempty"`
|
||||
|
||||
// SoftDeletePolicy: The bucket's soft delete policy, which defines the
|
||||
// period of time that soft-deleted objects will be retained, and cannot
|
||||
// be permanently deleted.
|
||||
SoftDeletePolicy *BucketSoftDeletePolicy `json:"softDeletePolicy,omitempty"`
|
||||
|
||||
// StorageClass: The bucket's default storage class, used whenever no
|
||||
// storageClass is specified for a newly-created object. This defines
|
||||
// how objects in the bucket are stored and determines the SLA and the
|
||||
|
|
@ -470,6 +478,16 @@ type BucketAutoclass struct {
|
|||
// Enabled: Whether or not Autoclass is enabled on this bucket
|
||||
Enabled bool `json:"enabled,omitempty"`
|
||||
|
||||
// TerminalStorageClass: The storage class that objects in the bucket
|
||||
// eventually transition to if they are not read for a certain length of
|
||||
// time. Valid values are NEARLINE and ARCHIVE.
|
||||
TerminalStorageClass string `json:"terminalStorageClass,omitempty"`
|
||||
|
||||
// TerminalStorageClassUpdateTime: A date and time in RFC 3339 format
|
||||
// representing the time of the most recent update to
|
||||
// "terminalStorageClass".
|
||||
TerminalStorageClassUpdateTime string `json:"terminalStorageClassUpdateTime,omitempty"`
|
||||
|
||||
// ToggleTime: A date and time in RFC 3339 format representing the
|
||||
// instant at which "enabled" was last toggled.
|
||||
ToggleTime string `json:"toggleTime,omitempty"`
|
||||
|
|
@ -972,6 +990,34 @@ func (s *BucketLogging) MarshalJSON() ([]byte, error) {
|
|||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// BucketObjectRetention: The bucket's object retention config.
|
||||
type BucketObjectRetention struct {
|
||||
// Mode: The bucket's object retention mode. Can be Enabled.
|
||||
Mode string `json:"mode,omitempty"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "Mode") to
|
||||
// unconditionally include in API requests. By default, fields with
|
||||
// empty or default 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. "Mode") 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 *BucketObjectRetention) MarshalJSON() ([]byte, error) {
|
||||
type NoMethod BucketObjectRetention
|
||||
raw := NoMethod(*s)
|
||||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// BucketOwner: The owner of the bucket. This is always the project
|
||||
// team's owner group.
|
||||
type BucketOwner struct {
|
||||
|
|
@ -1053,6 +1099,43 @@ func (s *BucketRetentionPolicy) MarshalJSON() ([]byte, error) {
|
|||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// BucketSoftDeletePolicy: The bucket's soft delete policy, which
|
||||
// defines the period of time that soft-deleted objects will be
|
||||
// retained, and cannot be permanently deleted.
|
||||
type BucketSoftDeletePolicy struct {
|
||||
// EffectiveTime: Server-determined value that indicates the time from
|
||||
// which the policy, or one with a greater retention, was effective.
|
||||
// This value is in RFC 3339 format.
|
||||
EffectiveTime string `json:"effectiveTime,omitempty"`
|
||||
|
||||
// RetentionDurationSeconds: The period of time in seconds, that
|
||||
// soft-deleted objects in the bucket will be retained and cannot be
|
||||
// permanently deleted.
|
||||
RetentionDurationSeconds int64 `json:"retentionDurationSeconds,omitempty,string"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "EffectiveTime") to
|
||||
// unconditionally include in API requests. By default, fields with
|
||||
// empty or default 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 *BucketSoftDeletePolicy) MarshalJSON() ([]byte, error) {
|
||||
type NoMethod BucketSoftDeletePolicy
|
||||
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
|
||||
|
|
@ -2072,6 +2155,9 @@ type Object struct {
|
|||
// the object.
|
||||
Owner *ObjectOwner `json:"owner,omitempty"`
|
||||
|
||||
// Retention: A collection of object level retention parameters.
|
||||
Retention *ObjectRetention `json:"retention,omitempty"`
|
||||
|
||||
// RetentionExpirationTime: A server-determined value that specifies the
|
||||
// earliest time that the object's retention period expires. This value
|
||||
// is in RFC 3339 format. Note 1: This field is not provided for objects
|
||||
|
|
@ -2213,6 +2299,39 @@ func (s *ObjectOwner) MarshalJSON() ([]byte, error) {
|
|||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// ObjectRetention: A collection of object level retention parameters.
|
||||
type ObjectRetention struct {
|
||||
// Mode: The bucket's object retention mode, can only be Unlocked or
|
||||
// Locked.
|
||||
Mode string `json:"mode,omitempty"`
|
||||
|
||||
// RetainUntilTime: A time in RFC 3339 format until which object
|
||||
// retention protects this object.
|
||||
RetainUntilTime string `json:"retainUntilTime,omitempty"`
|
||||
|
||||
// ForceSendFields is a list of field names (e.g. "Mode") to
|
||||
// unconditionally include in API requests. By default, fields with
|
||||
// empty or default 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. "Mode") 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 *ObjectRetention) MarshalJSON() ([]byte, error) {
|
||||
type NoMethod ObjectRetention
|
||||
raw := NoMethod(*s)
|
||||
return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
|
||||
}
|
||||
|
||||
// ObjectAccessControl: An access-control entry.
|
||||
type ObjectAccessControl struct {
|
||||
// Bucket: The name of the bucket.
|
||||
|
|
@ -4189,6 +4308,14 @@ func (r *BucketsService) Insert(projectid string, bucket *Bucket) *BucketsInsert
|
|||
return c
|
||||
}
|
||||
|
||||
// EnableObjectRetention sets the optional parameter
|
||||
// "enableObjectRetention": When set to true, object retention is
|
||||
// enabled for this bucket.
|
||||
func (c *BucketsInsertCall) EnableObjectRetention(enableObjectRetention bool) *BucketsInsertCall {
|
||||
c.urlParams_.Set("enableObjectRetention", fmt.Sprint(enableObjectRetention))
|
||||
return c
|
||||
}
|
||||
|
||||
// PredefinedAcl sets the optional parameter "predefinedAcl": Apply a
|
||||
// predefined set of access controls to this bucket.
|
||||
//
|
||||
|
|
@ -4362,6 +4489,12 @@ func (c *BucketsInsertCall) Do(opts ...googleapi.CallOption) (*Bucket, error) {
|
|||
// "project"
|
||||
// ],
|
||||
// "parameters": {
|
||||
// "enableObjectRetention": {
|
||||
// "default": "false",
|
||||
// "description": "When set to true, object retention is enabled for this bucket.",
|
||||
// "location": "query",
|
||||
// "type": "boolean"
|
||||
// },
|
||||
// "predefinedAcl": {
|
||||
// "description": "Apply a predefined set of access controls to this bucket.",
|
||||
// "enum": [
|
||||
|
|
@ -10976,6 +11109,15 @@ func (c *ObjectsPatchCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch int
|
|||
return c
|
||||
}
|
||||
|
||||
// OverrideUnlockedRetention sets the optional parameter
|
||||
// "overrideUnlockedRetention": Must be true to remove the retention
|
||||
// configuration, reduce its unlocked retention period, or change its
|
||||
// mode from unlocked to locked.
|
||||
func (c *ObjectsPatchCall) OverrideUnlockedRetention(overrideUnlockedRetention bool) *ObjectsPatchCall {
|
||||
c.urlParams_.Set("overrideUnlockedRetention", fmt.Sprint(overrideUnlockedRetention))
|
||||
return c
|
||||
}
|
||||
|
||||
// PredefinedAcl sets the optional parameter "predefinedAcl": Apply a
|
||||
// predefined set of access controls to this object.
|
||||
//
|
||||
|
|
@ -11167,6 +11309,11 @@ func (c *ObjectsPatchCall) Do(opts ...googleapi.CallOption) (*Object, error) {
|
|||
// "required": true,
|
||||
// "type": "string"
|
||||
// },
|
||||
// "overrideUnlockedRetention": {
|
||||
// "description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.",
|
||||
// "location": "query",
|
||||
// "type": "boolean"
|
||||
// },
|
||||
// "predefinedAcl": {
|
||||
// "description": "Apply a predefined set of access controls to this object.",
|
||||
// "enum": [
|
||||
|
|
@ -12393,6 +12540,15 @@ func (c *ObjectsUpdateCall) IfMetagenerationNotMatch(ifMetagenerationNotMatch in
|
|||
return c
|
||||
}
|
||||
|
||||
// OverrideUnlockedRetention sets the optional parameter
|
||||
// "overrideUnlockedRetention": Must be true to remove the retention
|
||||
// configuration, reduce its unlocked retention period, or change its
|
||||
// mode from unlocked to locked.
|
||||
func (c *ObjectsUpdateCall) OverrideUnlockedRetention(overrideUnlockedRetention bool) *ObjectsUpdateCall {
|
||||
c.urlParams_.Set("overrideUnlockedRetention", fmt.Sprint(overrideUnlockedRetention))
|
||||
return c
|
||||
}
|
||||
|
||||
// PredefinedAcl sets the optional parameter "predefinedAcl": Apply a
|
||||
// predefined set of access controls to this object.
|
||||
//
|
||||
|
|
@ -12584,6 +12740,11 @@ func (c *ObjectsUpdateCall) Do(opts ...googleapi.CallOption) (*Object, error) {
|
|||
// "required": true,
|
||||
// "type": "string"
|
||||
// },
|
||||
// "overrideUnlockedRetention": {
|
||||
// "description": "Must be true to remove the retention configuration, reduce its unlocked retention period, or change its mode from unlocked to locked.",
|
||||
// "location": "query",
|
||||
// "type": "boolean"
|
||||
// },
|
||||
// "predefinedAcl": {
|
||||
// "description": "Apply a predefined set of access controls to this object.",
|
||||
// "enum": [
|
||||
|
|
|
|||
|
|
@ -953,7 +953,7 @@ golang.org/x/tools/internal/typesinternal
|
|||
## explicit; go 1.17
|
||||
golang.org/x/xerrors
|
||||
golang.org/x/xerrors/internal
|
||||
# google.golang.org/api v0.141.0
|
||||
# google.golang.org/api v0.142.0
|
||||
## explicit; go 1.19
|
||||
google.golang.org/api/googleapi
|
||||
google.golang.org/api/googleapi/transport
|
||||
|
|
@ -992,7 +992,7 @@ google.golang.org/genproto/internal
|
|||
## explicit; go 1.19
|
||||
google.golang.org/genproto/googleapis/api
|
||||
google.golang.org/genproto/googleapis/api/annotations
|
||||
# google.golang.org/genproto/googleapis/rpc v0.0.0-20230911183012-2d3300fd4832
|
||||
# google.golang.org/genproto/googleapis/rpc v0.0.0-20230913181813-007df8e322eb
|
||||
## explicit; go 1.19
|
||||
google.golang.org/genproto/googleapis/rpc/code
|
||||
google.golang.org/genproto/googleapis/rpc/errdetails
|
||||
|
|
|
|||
Loading…
Reference in New Issue