google-cloud-storage 1.35.0 → 1.36.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -0
- data/lib/google/cloud/storage/bucket.rb +57 -1
- data/lib/google/cloud/storage/project.rb +17 -11
- data/lib/google/cloud/storage/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4c20986682a3f95c8fbea7f0132f5196d35f7978ba2b873530332a9709d3316c
|
4
|
+
data.tar.gz: 14de14960774f46eeaf07bbf9d8188228441dfdd8cb7b2c9a3649869f0909258
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 95d9b766685011b4421ff24fb2ceaa8aa42a8c89e9ad12aab6ca3e496bf01788ef9bd191554acefa9e9d2be0154292fd56d78953bf731446b65a20c97cc3ee51
|
7
|
+
data.tar.gz: b8748e786883a80b98fa77c927342656bb54ba69d8e309b2a11076bde8667671b2f0398abf694b49538761aa4bad08f5b59c4d39a38923f3afd1695f385a8e1c
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,23 @@
|
|
1
1
|
# Release History
|
2
2
|
|
3
|
+
### 1.36.2 (2022-04-20)
|
4
|
+
|
5
|
+
#### Documentation
|
6
|
+
|
7
|
+
* Document support for dual region buckets
|
8
|
+
|
9
|
+
### 1.36.1 / 2022-02-08
|
10
|
+
|
11
|
+
#### Documentation
|
12
|
+
|
13
|
+
* Update the RPO sample output. ([#17277](https://www.github.com/googleapis/google-cloud-ruby/issues/17277))
|
14
|
+
|
15
|
+
### 1.36.0 / 2022-01-12
|
16
|
+
|
17
|
+
#### Features
|
18
|
+
|
19
|
+
* add support for RPO (turbo replication). ([#14407](https://www.github.com/googleapis/google-cloud-ruby/issues/14407))
|
20
|
+
|
3
21
|
### 1.35.0 / 2021-12-08
|
4
22
|
|
5
23
|
#### Features
|
@@ -279,7 +279,7 @@ module Google
|
|
279
279
|
#
|
280
280
|
# @return [String]
|
281
281
|
#
|
282
|
-
# @see https://cloud.google.com/storage/docs/
|
282
|
+
# @see https://cloud.google.com/storage/docs/locations
|
283
283
|
#
|
284
284
|
def location
|
285
285
|
@gapi.location
|
@@ -1035,6 +1035,62 @@ module Google
|
|
1035
1035
|
|
1036
1036
|
alias public_access_prevention_unspecified? public_access_prevention_inherited?
|
1037
1037
|
|
1038
|
+
##
|
1039
|
+
# Recovery Point Objective (RPO) is another attribute of a bucket, it measures how long it takes for a set of
|
1040
|
+
# updates to be asynchronously copied to the other region.
|
1041
|
+
# Currently, `DEFAULT` and `ASYNC_TURBO` are supported. When set to `ASYNC_TURBO`, Turbo Replication is enabled
|
1042
|
+
# for a bucket. `DEFAULT` is used to reset rpo on an existing bucket with rpo set to `ASYNC_TURBO`.
|
1043
|
+
# This value can be modified by calling {#rpo=}.
|
1044
|
+
#
|
1045
|
+
# @return [String, nil] Currently, `DEFAULT` and `ASYNC_TURBO` are supported. Returns `nil` if the bucket has
|
1046
|
+
# no RPO.
|
1047
|
+
#
|
1048
|
+
# @example
|
1049
|
+
# require "google/cloud/storage"
|
1050
|
+
#
|
1051
|
+
# storage = Google::Cloud::Storage.new
|
1052
|
+
#
|
1053
|
+
# bucket = storage.bucket "my-bucket"
|
1054
|
+
#
|
1055
|
+
# bucket.rpo = :DEFAULT
|
1056
|
+
# bucket.rpo #=> "DEFAULT"
|
1057
|
+
#
|
1058
|
+
def rpo
|
1059
|
+
@gapi.rpo
|
1060
|
+
end
|
1061
|
+
|
1062
|
+
##
|
1063
|
+
# Sets the value for Recovery Point Objective (RPO) in the bucket. This value can be queried by calling {#rpo}.
|
1064
|
+
#
|
1065
|
+
# @param [Symbol, String] new_rpo The bucket's new Recovery Point Objective metadata.
|
1066
|
+
# Currently, `DEFAULT` and `ASYNC_TURBO` are supported. When set to `ASYNC_TURBO`, Turbo Replication
|
1067
|
+
# is enabled for a bucket.
|
1068
|
+
#
|
1069
|
+
# @example Set RPO to DEFAULT:
|
1070
|
+
# require "google/cloud/storage"
|
1071
|
+
#
|
1072
|
+
# storage = Google::Cloud::Storage.new
|
1073
|
+
#
|
1074
|
+
# bucket = storage.bucket "my-bucket"
|
1075
|
+
#
|
1076
|
+
# bucket.rpo = :DEFAULT
|
1077
|
+
# bucket.rpo #=> "DEFAULT"
|
1078
|
+
#
|
1079
|
+
# @example Set RPO to ASYNC_TURBO:
|
1080
|
+
# require "google/cloud/storage"
|
1081
|
+
#
|
1082
|
+
# storage = Google::Cloud::Storage.new
|
1083
|
+
#
|
1084
|
+
# bucket = storage.bucket "my-bucket"
|
1085
|
+
#
|
1086
|
+
# bucket.rpo = :ASYNC_TURBO
|
1087
|
+
# bucket.rpo #=> "ASYNC_TURBO"
|
1088
|
+
#
|
1089
|
+
def rpo= new_rpo
|
1090
|
+
@gapi.rpo = new_rpo&.to_s
|
1091
|
+
patch_gapi! :rpo
|
1092
|
+
end
|
1093
|
+
|
1038
1094
|
##
|
1039
1095
|
# Updates the bucket with changes made in the given block in a single
|
1040
1096
|
# PATCH request. The following attributes may be set: {#cors},
|
@@ -288,12 +288,11 @@ module Google
|
|
288
288
|
# roles.
|
289
289
|
# * `public`, `public_read`, `publicRead` - File owner gets OWNER
|
290
290
|
# access, and allUsers get READER access.
|
291
|
-
# @param [String] location The location of the bucket.
|
292
|
-
#
|
293
|
-
#
|
294
|
-
#
|
295
|
-
#
|
296
|
-
# the authoritative list. The default value is `US`.
|
291
|
+
# @param [String] location The location of the bucket. Optional.
|
292
|
+
# If not passed, the default location, 'US', will be used.
|
293
|
+
# If specifying a dual-region location, the regions can be specified
|
294
|
+
# by joining them with a plus sign, for example 'US-CENTRAL1+US-WEST1'. See:
|
295
|
+
# [Storage Locaitons](https://cloud.google.com/storage/docs/locations).
|
297
296
|
# @param [String] logging_bucket The destination bucket for the bucket's
|
298
297
|
# logs. For more information, see [Access
|
299
298
|
# Logs](https://cloud.google.com/storage/docs/access-logs).
|
@@ -364,11 +363,18 @@ module Google
|
|
364
363
|
# b.lifecycle.add_set_storage_class_rule "COLDLINE", age: 10
|
365
364
|
# end
|
366
365
|
#
|
367
|
-
def create_bucket bucket_name,
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
366
|
+
def create_bucket bucket_name,
|
367
|
+
acl: nil,
|
368
|
+
default_acl: nil,
|
369
|
+
location: nil,
|
370
|
+
storage_class: nil,
|
371
|
+
logging_bucket: nil,
|
372
|
+
logging_prefix: nil,
|
373
|
+
website_main: nil,
|
374
|
+
website_404: nil,
|
375
|
+
versioning: nil,
|
376
|
+
requester_pays: nil,
|
377
|
+
user_project: nil
|
372
378
|
params = {
|
373
379
|
name: bucket_name,
|
374
380
|
location: location
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-storage
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.36.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Moore
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2022-04-20 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: google-cloud-core
|
@@ -318,7 +318,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
318
318
|
- !ruby/object:Gem::Version
|
319
319
|
version: '0'
|
320
320
|
requirements: []
|
321
|
-
rubygems_version: 3.
|
321
|
+
rubygems_version: 3.3.5
|
322
322
|
signing_key:
|
323
323
|
specification_version: 4
|
324
324
|
summary: API Client library for Google Cloud Storage
|