google-cloud-secret_manager 0.4.0 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dd997305e4ea4ac3bfb9840cdbb4e3e48c06fcdf81aeba1e8aa9fe8600fec3b6
4
- data.tar.gz: 943eb163b2e729de37bd1e8ee02426c7e154701144468713b72475b6cebc0ae0
3
+ metadata.gz: 80d5a53f757ac4eabc61326830ab6c0c17d71f8911f10f27a00f859d040af58a
4
+ data.tar.gz: 193f6708ebe96c09fc096be85d0c46d03f4a1f5729df6cb81c93ac7b9c205cd9
5
5
  SHA512:
6
- metadata.gz: 7bc3f8d42d90f81a8c81ce2f2780964b5f68ccd81035c31e7128c65bdd223d9ce9b7f6a556c0e01e72b5147617737a764cfa9a6dca2908e345421f3fda13b3a8
7
- data.tar.gz: 2e9bc323ec14069ab0b1edfd390ffb9015a6896880be2e38b3da4f02e408db73f63a63e28f15ea6e624abbfde83ed1d4a17342928472393554ef4dbe74350dd0
6
+ metadata.gz: a5015b1390f98dce84c2d2af31720d3e8e7a3d47ec88ee132714f5228b99d39906adaa3ba46ec3113e3064e6cc9daff9785b15a700371a81385b892092918b79
7
+ data.tar.gz: cb93b7f77dc666dcfcfa2b38f43f58558d8ede6413022c8fac85c7820d4ee4abef20a9c462d5323a7998b00a42d108ec366491a36afc0dcbd448b4afa7ef40b1
data/AUTHENTICATION.md CHANGED
@@ -64,7 +64,7 @@ containers where writing files is difficult or not encouraged.
64
64
 
65
65
  The environment variables that google-cloud-secret_manager
66
66
  checks for credentials are configured on the service Credentials class (such as
67
- `Google::Cloud::SecretManager::V1::SecretManagerService::Credentials`):
67
+ `::Google::Cloud::SecretManager::V1::SecretManagerService::Credentials`):
68
68
 
69
69
  1. `SECRET_MANAGER_CREDENTIALS` - Path to JSON file, or JSON contents
70
70
  2. `SECRET_MANAGER_KEYFILE` - Path to JSON file, or JSON contents
data/README.md CHANGED
@@ -6,9 +6,10 @@ Secret Manager is a secure and convenient storage system for API keys, passwords
6
6
 
7
7
  Actual client classes for the various versions of this API are defined in
8
8
  _versioned_ client gems, with names of the form `google-cloud-secret_manager-v*`.
9
- The gem `google-cloud-secret_manager` is a convenience wrapper library that brings the
9
+ The gem `google-cloud-secret_manager` is the main client library that brings the
10
10
  verisoned gems in as dependencies, and provides high-level methods for
11
- constructing clients.
11
+ constructing clients. More information on versioned clients can be found below
12
+ in the section titled *Which client should I use?*.
12
13
 
13
14
  View the [Client Library Documentation](https://googleapis.dev/ruby/google-cloud-secret_manager/latest)
14
15
  for this library, google-cloud-secret_manager, to see the convenience methods for
@@ -70,3 +71,61 @@ in security maintenance, and not end of life. Currently, this means Ruby 2.4
70
71
  and later. Older versions of Ruby _may_ still work, but are unsupported and not
71
72
  recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details
72
73
  about the Ruby support schedule.
74
+
75
+ ## Which client should I use?
76
+
77
+ Most modern Ruby client libraries for Google APIs come in two flavors: the main
78
+ client library with a name such as `google-cloud-secret_manager`,
79
+ and lower-level _versioned_ client libraries with names such as
80
+ `google-cloud-secret_manager-v1`.
81
+ _In most cases, you should install the main client._
82
+
83
+ ### What's the difference between the main client and a versioned client?
84
+
85
+ A _versioned client_ provides a basic set of data types and client classes for
86
+ a _single version_ of a specific service. (That is, for a service with multiple
87
+ versions, there might be a separate versioned client for each service version.)
88
+ Most versioned clients are written and maintained by a code generator.
89
+
90
+ The _main client_ is designed to provide you with the _recommended_ client
91
+ interfaces for the service. There will be only one main client for any given
92
+ service, even a service with multiple versions. The main client includes
93
+ factory methods for constructing the client objects we recommend for most
94
+ users. In some cases, those will be classes provided by an underlying versioned
95
+ client; in other cases, they will be handwritten higher-level client objects
96
+ with additional capabilities, convenience methods, or best practices built in.
97
+ Generally, the main client will default to a recommended service version,
98
+ although in some cases you can override this if you need to talk to a specific
99
+ service version.
100
+
101
+ ### Why would I want to use the main client?
102
+
103
+ We recommend that most users install the main client gem for a service. You can
104
+ identify this gem as the one _without_ a version in its name, e.g.
105
+ `google-cloud-secret_manager`.
106
+ The main client is recommended because it will embody the best practices for
107
+ accessing the service, and may also provide more convenient interfaces or
108
+ tighter integration into frameworks and third-party libraries. In addition, the
109
+ documentation and samples published by Google will generally demonstrate use of
110
+ the main client.
111
+
112
+ ### Why would I want to use a versioned client?
113
+
114
+ You can use a versioned client if you are content with a possibly lower-level
115
+ class interface, you explicitly want to avoid features provided by the main
116
+ client, or you want to access a specific service version not be covered by the
117
+ main client. You can identify versioned client gems because the service version
118
+ is part of the name, e.g. `google-cloud-secret_manager-v1`.
119
+
120
+ ### What about the google-apis-<name> clients?
121
+
122
+ Client library gems with names that begin with `google-apis-` are based on an
123
+ older code generation technology. They talk to a REST/JSON backend (whereas
124
+ most modern clients talk to a [gRPC](https://grpc.io/) backend) and they may
125
+ not offer the same performance, features, and ease of use provided by more
126
+ modern clients.
127
+
128
+ The `google-apis-` clients have wide coverage across Google services, so you
129
+ might need to use one if there is no modern client available for the service.
130
+ However, if a modern client is available, we generally recommend it over the
131
+ older `google-apis-` clients.
@@ -16,4 +16,4 @@
16
16
 
17
17
  # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
18
 
19
- require "google/cloud/secret_manager"
19
+ require "google/cloud/secret_manager" unless defined? Google::Cloud::SecretManager::VERSION
@@ -16,21 +16,29 @@
16
16
 
17
17
  # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
18
 
19
+ # Require this file early so that the version constant gets defined before
20
+ # requiring "google/cloud". This is because google-cloud-core will load the
21
+ # entrypoint (gem name) file, which in turn re-requires this file (hence
22
+ # causing a require cycle) unless the version constant is already defined.
19
23
  require "google/cloud/secret_manager/version"
24
+
20
25
  require "googleauth"
21
26
  gem "google-cloud-core"
22
- require "google/cloud" unless defined? Google::Cloud.new
27
+ require "google/cloud" unless defined? ::Google::Cloud.new
23
28
  require "google/cloud/config"
24
29
 
25
30
  # Set the default configuration
26
- Google::Cloud.configure.add_config! :secret_manager do |config|
27
- config.add_field! :credentials, nil, match: [String, Hash, Google::Auth::Credentials]
28
- config.add_field! :lib_name, nil, match: String
29
- config.add_field! :lib_version, nil, match: String
30
- config.add_field! :interceptors, nil, match: Array
31
- config.add_field! :timeout, nil, match: Numeric
32
- config.add_field! :metadata, nil, match: Hash
33
- config.add_field! :retry_policy, nil, match: [Hash, Proc]
31
+ ::Google::Cloud.configure.add_config! :secret_manager do |config|
32
+ config.add_field! :endpoint, "secretmanager.googleapis.com", match: ::String
33
+ config.add_field! :credentials, nil, match: [::String, ::Hash, ::Google::Auth::Credentials]
34
+ config.add_field! :scope, nil, match: [::Array, ::String]
35
+ config.add_field! :lib_name, nil, match: ::String
36
+ config.add_field! :lib_version, nil, match: ::String
37
+ config.add_field! :interceptors, nil, match: ::Array
38
+ config.add_field! :timeout, nil, match: ::Numeric
39
+ config.add_field! :metadata, nil, match: ::Hash
40
+ config.add_field! :retry_policy, nil, match: [::Hash, ::Proc]
41
+ config.add_field! :quota_project, nil, match: ::String
34
42
  end
35
43
 
36
44
  module Google
@@ -57,7 +65,7 @@ module Google
57
65
  # * Secret
58
66
  # * SecretVersion
59
67
  #
60
- # @param version [String, Symbol] The API version to connect to. Optional.
68
+ # @param version [::String, ::Symbol] The API version to connect to. Optional.
61
69
  # Defaults to `:v1`.
62
70
  # @return [SecretManagerService::Client] A client object for the specified version.
63
71
  #
@@ -86,8 +94,8 @@ module Google
86
94
  # The library version as recorded in instrumentation and logging.
87
95
  # * `interceptors` (*type:* `Array<GRPC::ClientInterceptor>`) -
88
96
  # An array of interceptors that are run before calls are executed.
89
- # * `timeout` (*type:* `Integer`) -
90
- # Default timeout in milliseconds.
97
+ # * `timeout` (*type:* `Numeric`) -
98
+ # Default timeout in seconds.
91
99
  # * `metadata` (*type:* `Hash{Symbol=>String}`) -
92
100
  # Additional gRPC headers to be sent with the call.
93
101
  # * `retry_policy` (*type:* `Hash`) -
@@ -98,13 +106,16 @@ module Google
98
106
  # * `:retry_codes` (*type:* `Array<String>`) -
99
107
  # The error codes that should trigger a retry.
100
108
  #
101
- # @return [Google::Cloud::Config] The default configuration used by this library
109
+ # @return [::Google::Cloud::Config] The default configuration used by this library
102
110
  #
103
111
  def self.configure
104
- yield Google::Cloud.configure.secret_manager if block_given?
112
+ yield ::Google::Cloud.configure.secret_manager if block_given?
105
113
 
106
- Google::Cloud.configure.secret_manager
114
+ ::Google::Cloud.configure.secret_manager
107
115
  end
108
116
  end
109
117
  end
110
118
  end
119
+
120
+ helper_path = ::File.join __dir__, "secret_manager", "helpers.rb"
121
+ require "google/cloud/secret_manager/helpers" if ::File.file? helper_path
@@ -16,7 +16,7 @@
16
16
  module Google
17
17
  module Cloud
18
18
  module SecretManager
19
- VERSION = "0.4.0".freeze
19
+ VERSION = "1.0.2".freeze
20
20
  end
21
21
  end
22
22
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-secret_manager
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Google LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-13 00:00:00.000000000 Z
11
+ date: 2021-02-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: google-cloud-core
@@ -52,20 +52,6 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0.3'
55
- - !ruby/object:Gem::Dependency
56
- name: autotest-suffix
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: '1.1'
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '1.1'
69
55
  - !ruby/object:Gem::Dependency
70
56
  name: google-style
71
57
  requirement: !ruby/object:Gem::Requirement
@@ -86,56 +72,56 @@ dependencies:
86
72
  requirements:
87
73
  - - "~>"
88
74
  - !ruby/object:Gem::Version
89
- version: '5.10'
75
+ version: '5.14'
90
76
  type: :development
91
77
  prerelease: false
92
78
  version_requirements: !ruby/object:Gem::Requirement
93
79
  requirements:
94
80
  - - "~>"
95
81
  - !ruby/object:Gem::Version
96
- version: '5.10'
82
+ version: '5.14'
97
83
  - !ruby/object:Gem::Dependency
98
- name: minitest-autotest
84
+ name: minitest-focus
99
85
  requirement: !ruby/object:Gem::Requirement
100
86
  requirements:
101
87
  - - "~>"
102
88
  - !ruby/object:Gem::Version
103
- version: '1.0'
89
+ version: '1.1'
104
90
  type: :development
105
91
  prerelease: false
106
92
  version_requirements: !ruby/object:Gem::Requirement
107
93
  requirements:
108
94
  - - "~>"
109
95
  - !ruby/object:Gem::Version
110
- version: '1.0'
96
+ version: '1.1'
111
97
  - !ruby/object:Gem::Dependency
112
- name: minitest-focus
98
+ name: minitest-rg
113
99
  requirement: !ruby/object:Gem::Requirement
114
100
  requirements:
115
101
  - - "~>"
116
102
  - !ruby/object:Gem::Version
117
- version: '1.1'
103
+ version: '5.2'
118
104
  type: :development
119
105
  prerelease: false
120
106
  version_requirements: !ruby/object:Gem::Requirement
121
107
  requirements:
122
108
  - - "~>"
123
109
  - !ruby/object:Gem::Version
124
- version: '1.1'
110
+ version: '5.2'
125
111
  - !ruby/object:Gem::Dependency
126
- name: minitest-rg
112
+ name: rake
127
113
  requirement: !ruby/object:Gem::Requirement
128
114
  requirements:
129
- - - "~>"
115
+ - - ">="
130
116
  - !ruby/object:Gem::Version
131
- version: '5.2'
117
+ version: '12.0'
132
118
  type: :development
133
119
  prerelease: false
134
120
  version_requirements: !ruby/object:Gem::Requirement
135
121
  requirements:
136
- - - "~>"
122
+ - - ">="
137
123
  - !ruby/object:Gem::Version
138
- version: '5.2'
124
+ version: '12.0'
139
125
  - !ruby/object:Gem::Dependency
140
126
  name: redcarpet
141
127
  requirement: !ruby/object:Gem::Requirement
@@ -213,7 +199,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
213
199
  - !ruby/object:Gem::Version
214
200
  version: '0'
215
201
  requirements: []
216
- rubygems_version: 3.0.6
202
+ rubygems_version: 3.2.6
217
203
  signing_key:
218
204
  specification_version: 4
219
205
  summary: API Client library for the Secret Manager API