google-cloud-talent-v4 0.2.0 → 0.4.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -60,7 +60,7 @@ module Google
60
60
  parent_config = while namespace.any?
61
61
  parent_name = namespace.join "::"
62
62
  parent_const = const_get parent_name
63
- break parent_const.configure if parent_const&.respond_to? :configure
63
+ break parent_const.configure if parent_const.respond_to? :configure
64
64
  namespace.pop
65
65
  end
66
66
  default_config = Client::Configuration.new parent_config
@@ -69,28 +69,19 @@ module Google
69
69
 
70
70
  default_config.rpcs.get_tenant.timeout = 30.0
71
71
  default_config.rpcs.get_tenant.retry_policy = {
72
- initial_delay: 0.1,
73
- max_delay: 60.0,
74
- multiplier: 1.3,
75
- retry_codes: [4, 14]
72
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
76
73
  }
77
74
 
78
75
  default_config.rpcs.update_tenant.timeout = 30.0
79
76
 
80
77
  default_config.rpcs.delete_tenant.timeout = 30.0
81
78
  default_config.rpcs.delete_tenant.retry_policy = {
82
- initial_delay: 0.1,
83
- max_delay: 60.0,
84
- multiplier: 1.3,
85
- retry_codes: [4, 14]
79
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
86
80
  }
87
81
 
88
82
  default_config.rpcs.list_tenants.timeout = 30.0
89
83
  default_config.rpcs.list_tenants.retry_policy = {
90
- initial_delay: 0.1,
91
- max_delay: 60.0,
92
- multiplier: 1.3,
93
- retry_codes: [4, 14]
84
+ initial_delay: 0.1, max_delay: 60.0, multiplier: 1.3, retry_codes: [4, 14]
94
85
  }
95
86
 
96
87
  default_config
@@ -154,8 +145,14 @@ module Google
154
145
 
155
146
  # Create credentials
156
147
  credentials = @config.credentials
157
- credentials ||= Credentials.default scope: @config.scope
158
- if credentials.is_a?(String) || credentials.is_a?(Hash)
148
+ # Use self-signed JWT if the scope and endpoint are unchanged from default,
149
+ # but only if the default endpoint does not have a region prefix.
150
+ enable_self_signed_jwt = @config.scope == Client.configure.scope &&
151
+ @config.endpoint == Client.configure.endpoint &&
152
+ !@config.endpoint.split(".").first.include?("-")
153
+ credentials ||= Credentials.default scope: @config.scope,
154
+ enable_self_signed_jwt: enable_self_signed_jwt
155
+ if credentials.is_a?(::String) || credentials.is_a?(::Hash)
159
156
  credentials = Credentials.new credentials, scope: @config.scope
160
157
  end
161
158
  @quota_project_id = @config.quota_project
@@ -622,7 +619,7 @@ module Google
622
619
  config_attr :scope, nil, ::String, ::Array, nil
623
620
  config_attr :lib_name, nil, ::String, nil
624
621
  config_attr :lib_version, nil, ::String, nil
625
- config_attr(:channel_args, { "grpc.service_config_disable_resolution"=>1 }, ::Hash, nil)
622
+ config_attr(:channel_args, { "grpc.service_config_disable_resolution" => 1 }, ::Hash, nil)
626
623
  config_attr :interceptors, nil, ::Array, nil
627
624
  config_attr :timeout, nil, ::Numeric, nil
628
625
  config_attr :metadata, nil, ::Hash, nil
@@ -643,7 +640,7 @@ module Google
643
640
  def rpcs
644
641
  @rpcs ||= begin
645
642
  parent_rpcs = nil
646
- parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config&.respond_to?(:rpcs)
643
+ parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs)
647
644
  Rpcs.new parent_rpcs
648
645
  end
649
646
  end
@@ -655,7 +652,7 @@ module Google
655
652
  # Each configuration object is of type `Gapic::Config::Method` and includes
656
653
  # the following configuration fields:
657
654
  #
658
- # * `timeout` (*type:* `Numeric`) - The call timeout in milliseconds
655
+ # * `timeout` (*type:* `Numeric`) - The call timeout in seconds
659
656
  # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional gRPC headers
660
657
  # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields
661
658
  # include the following keys:
@@ -694,15 +691,15 @@ module Google
694
691
 
695
692
  # @private
696
693
  def initialize parent_rpcs = nil
697
- create_tenant_config = parent_rpcs&.create_tenant if parent_rpcs&.respond_to? :create_tenant
694
+ create_tenant_config = parent_rpcs.create_tenant if parent_rpcs.respond_to? :create_tenant
698
695
  @create_tenant = ::Gapic::Config::Method.new create_tenant_config
699
- get_tenant_config = parent_rpcs&.get_tenant if parent_rpcs&.respond_to? :get_tenant
696
+ get_tenant_config = parent_rpcs.get_tenant if parent_rpcs.respond_to? :get_tenant
700
697
  @get_tenant = ::Gapic::Config::Method.new get_tenant_config
701
- update_tenant_config = parent_rpcs&.update_tenant if parent_rpcs&.respond_to? :update_tenant
698
+ update_tenant_config = parent_rpcs.update_tenant if parent_rpcs.respond_to? :update_tenant
702
699
  @update_tenant = ::Gapic::Config::Method.new update_tenant_config
703
- delete_tenant_config = parent_rpcs&.delete_tenant if parent_rpcs&.respond_to? :delete_tenant
700
+ delete_tenant_config = parent_rpcs.delete_tenant if parent_rpcs.respond_to? :delete_tenant
704
701
  @delete_tenant = ::Gapic::Config::Method.new delete_tenant_config
705
- list_tenants_config = parent_rpcs&.list_tenants if parent_rpcs&.respond_to? :list_tenants
702
+ list_tenants_config = parent_rpcs.list_tenants if parent_rpcs.respond_to? :list_tenants
706
703
  @list_tenants = ::Gapic::Config::Method.new list_tenants_config
707
704
 
708
705
  yield self if block_given?
@@ -21,7 +21,7 @@ module Google
21
21
  module Cloud
22
22
  module Talent
23
23
  module V4
24
- VERSION = "0.2.0"
24
+ VERSION = "0.4.2"
25
25
  end
26
26
  end
27
27
  end
@@ -54,6 +54,18 @@ module Google
54
54
  # This indicates that the field may be set once in a request to create a
55
55
  # resource, but may not be changed thereafter.
56
56
  IMMUTABLE = 5
57
+
58
+ # Denotes that a (repeated) field is an unordered list.
59
+ # This indicates that the service may provide the elements of the list
60
+ # in any arbitrary order, rather than the order the user originally
61
+ # provided. Additionally, the list's order may or may not be stable.
62
+ UNORDERED_LIST = 6
63
+
64
+ # Denotes that this field returns a non-empty default value if not set.
65
+ # This indicates that if the user provides the empty value in a request,
66
+ # a non-empty value will be returned. The user will not be aware of what
67
+ # non-empty value to expect.
68
+ NON_EMPTY_DEFAULT = 7
57
69
  end
58
70
  end
59
71
  end
@@ -25,7 +25,7 @@ module Google
25
25
  # @return [::String]
26
26
  # The server-assigned name, which is only unique within the same service that
27
27
  # originally returns it. If you use the default HTTP mapping, the
28
- # `name` should have the format of `operations/some/unique/name`.
28
+ # `name` should be a resource name ending with `operations/{unique_id}`.
29
29
  # @!attribute [rw] metadata
30
30
  # @return [::Google::Protobuf::Any]
31
31
  # Service-specific metadata associated with the operation. It typically
@@ -35,7 +35,7 @@ module Google
35
35
  # @!attribute [rw] done
36
36
  # @return [::Boolean]
37
37
  # If the value is `false`, it means the operation is still in progress.
38
- # If true, the operation is completed, and either `error` or `response` is
38
+ # If `true`, the operation is completed, and either `error` or `response` is
39
39
  # available.
40
40
  # @!attribute [rw] error
41
41
  # @return [::Google::Rpc::Status]
@@ -67,7 +67,7 @@ module Google
67
67
  # The request message for Operations.ListOperations.
68
68
  # @!attribute [rw] name
69
69
  # @return [::String]
70
- # The name of the operation collection.
70
+ # The name of the operation's parent resource.
71
71
  # @!attribute [rw] filter
72
72
  # @return [::String]
73
73
  # The standard list filter.
@@ -112,6 +112,20 @@ module Google
112
112
  extend ::Google::Protobuf::MessageExts::ClassMethods
113
113
  end
114
114
 
115
+ # The request message for Operations.WaitOperation.
116
+ # @!attribute [rw] name
117
+ # @return [::String]
118
+ # The name of the operation resource to wait on.
119
+ # @!attribute [rw] timeout
120
+ # @return [::Google::Protobuf::Duration]
121
+ # The maximum duration to wait before timing out. If left blank, the wait
122
+ # will be at most the time permitted by the underlying HTTP/RPC protocol.
123
+ # If RPC context deadline is also specified, the shorter one will be used.
124
+ class WaitOperationRequest
125
+ include ::Google::Protobuf::MessageExts
126
+ extend ::Google::Protobuf::MessageExts::ClassMethods
127
+ end
128
+
115
129
  # A message representing the message types used by a long-running operation.
116
130
  #
117
131
  # Example:
@@ -57,10 +57,13 @@ module Google
57
57
  # Example 4: Pack and unpack a message in Go
58
58
  #
59
59
  # foo := &pb.Foo{...}
60
- # any, err := ptypes.MarshalAny(foo)
60
+ # any, err := anypb.New(foo)
61
+ # if err != nil {
62
+ # ...
63
+ # }
61
64
  # ...
62
65
  # foo := &pb.Foo{}
63
- # if err := ptypes.UnmarshalAny(any, foo); err != nil {
66
+ # if err := any.UnmarshalTo(foo); err != nil {
64
67
  # ...
65
68
  # }
66
69
  #
@@ -70,7 +70,16 @@ module Google
70
70
  # .setNanos((int) ((millis % 1000) * 1000000)).build();
71
71
  #
72
72
  #
73
- # Example 5: Compute Timestamp from current time in Python.
73
+ # Example 5: Compute Timestamp from Java `Instant.now()`.
74
+ #
75
+ # Instant now = Instant.now();
76
+ #
77
+ # Timestamp timestamp =
78
+ # Timestamp.newBuilder().setSeconds(now.getEpochSecond())
79
+ # .setNanos(now.getNano()).build();
80
+ #
81
+ #
82
+ # Example 6: Compute Timestamp from current time in Python.
74
83
  #
75
84
  # timestamp = Timestamp()
76
85
  # timestamp.GetCurrentTime()
@@ -19,8 +19,8 @@
19
19
 
20
20
  module Google
21
21
  module Type
22
- # An object representing a latitude/longitude pair. This is expressed as a pair
23
- # of doubles representing degrees latitude and degrees longitude. Unless
22
+ # An object that represents a latitude/longitude pair. This is expressed as a
23
+ # pair of doubles to represent degrees latitude and degrees longitude. Unless
24
24
  # specified otherwise, this must conform to the
25
25
  # <a href="http://www.unoosa.org/pdf/icg/2012/template/WGS_84.pdf">WGS84
26
26
  # standard</a>. Values must be within normalized ranges.
@@ -22,7 +22,7 @@ module Google
22
22
  # Represents an amount of money with its currency type.
23
23
  # @!attribute [rw] currency_code
24
24
  # @return [::String]
25
- # The 3-letter currency code defined in ISO 4217.
25
+ # The three-letter currency code defined in ISO 4217.
26
26
  # @!attribute [rw] units
27
27
  # @return [::Integer]
28
28
  # The whole units of the amount.
@@ -21,7 +21,8 @@ module Google
21
21
  module Type
22
22
  # Represents a time of day. The date and time zone are either not significant
23
23
  # or are specified elsewhere. An API may choose to allow leap seconds. Related
24
- # types are [google.type.Date][google.type.Date] and `google.protobuf.Timestamp`.
24
+ # types are [google.type.Date][google.type.Date] and
25
+ # `google.protobuf.Timestamp`.
25
26
  # @!attribute [rw] hours
26
27
  # @return [::Integer]
27
28
  # Hours of day in 24 hour format. Should be from 0 to 23. An API may choose
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-talent-v4
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.4.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-10-05 00:00:00.000000000 Z
11
+ date: 2021-07-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gapic-common
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0.5'
20
+ - - "<"
18
21
  - !ruby/object:Gem::Version
19
- version: '0.3'
22
+ version: 2.a
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: '0.5'
30
+ - - "<"
25
31
  - !ruby/object:Gem::Version
26
- version: '0.3'
32
+ version: 2.a
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: google-cloud-errors
29
35
  requirement: !ruby/object:Gem::Requirement
@@ -44,14 +50,14 @@ dependencies:
44
50
  requirements:
45
51
  - - "~>"
46
52
  - !ruby/object:Gem::Version
47
- version: 1.24.0
53
+ version: 1.25.1
48
54
  type: :development
49
55
  prerelease: false
50
56
  version_requirements: !ruby/object:Gem::Requirement
51
57
  requirements:
52
58
  - - "~>"
53
59
  - !ruby/object:Gem::Version
54
- version: 1.24.0
60
+ version: 1.25.1
55
61
  - !ruby/object:Gem::Dependency
56
62
  name: minitest
57
63
  requirement: !ruby/object:Gem::Requirement
@@ -154,7 +160,9 @@ description: Transform your job search and candidate matching capabilities with
154
160
  Talent Solution, designed to support enterprise talent acquisition technology and
155
161
  evolve with your growing needs. This AI solution includes features such as Job Search
156
162
  and Profile Search to provide candidates and employers with an enhanced talent acquisition
157
- experience.
163
+ experience. Note that google-cloud-talent-v4 is a version-specific client library.
164
+ For most uses, we recommend installing the main client library google-cloud-talent
165
+ instead. See the readme for more details.
158
166
  email: googleapis-packages@google.com
159
167
  executables: []
160
168
  extensions: []
@@ -244,14 +252,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
244
252
  requirements:
245
253
  - - ">="
246
254
  - !ruby/object:Gem::Version
247
- version: '2.4'
255
+ version: '2.5'
248
256
  required_rubygems_version: !ruby/object:Gem::Requirement
249
257
  requirements:
250
258
  - - ">="
251
259
  - !ruby/object:Gem::Version
252
260
  version: '0'
253
261
  requirements: []
254
- rubygems_version: 3.1.4
262
+ rubygems_version: 3.2.17
255
263
  signing_key:
256
264
  specification_version: 4
257
265
  summary: API Client library for the Cloud Talent Solution V4 API