When I created http_request task using GoogleCloudTasks Gem version 1.3.2, GaxError RPC failed, caused by 3 error occured.
I couldn't reproduced this error by version 1.3.1 and 1.3.0.
gem 'google-cloud-tasks', '= 1.3.2'require "google/cloud/tasks"
project_id = ARGV.shift
location_id = ARGV.shift
queue_id = ARGV.shift
client = Google::Cloud::Tasks.new
parent = client.queue_path project_id, location_id, queue_id
task = {
http_request: {
http_method: "POST",
url: "https://example.com/example/path/"
}
}
response = client.create_task parent, task
run $ bundle exec ruby create_task.rb "project-xxxxxxxx" "asia-northeast1" "queue-xxxxxxxx"
Traceback (most recent call last):
10: from create_task.rb:19:in `<main>'
9: from /usr/local/bundle/gems/google-cloud-tasks-1.3.2/lib/google/cloud/tasks/v2/cloud_tasks_client.rb:1120:in `create_task'
8: from /usr/local/bundle/gems/google-gax-1.8.1/lib/google/gax/api_callable.rb:260:in `block in create_api_call'
7: from /usr/local/bundle/gems/google-gax-1.8.1/lib/google/gax/api_callable.rb:230:in `block in create_api_call'
6: from /usr/local/bundle/gems/google-gax-1.8.1/lib/google/gax/api_callable.rb:401:in `block in add_timeout_arg'
5: from /usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/client_stub.rb:171:in `block in request_response'
4: from /usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/interceptors.rb:170:in `intercept!'
3: from /usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/client_stub.rb:172:in `block (2 levels) in request_response'
2: from /usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/active_call.rb:377:in `request_response'
1: from /usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/active_call.rb:181:in `attach_status_results_and_complete_call'
/usr/local/bundle/gems/grpc-1.26.0/src/ruby/lib/grpc/generic/active_call.rb:31:in `check_status': 3:The request deadline is 2019-12-24T19:04:04.062331705-08:00. The deadline cannot be more than 30s in the future. (GRPC::InvalidArgument)
3: from create_task.rb:19:in `<main>'
2: from /usr/local/bundle/gems/google-cloud-tasks-1.3.2/lib/google/cloud/tasks/v2/cloud_tasks_client.rb:1120:in `create_task'
1: from /usr/local/bundle/gems/google-gax-1.8.1/lib/google/gax/api_callable.rb:259:in `block in create_api_call'
/usr/local/bundle/gems/google-gax-1.8.1/lib/google/gax/api_callable.rb:264:in `rescue in block in create_api_call': GaxError RPC failed, caused by 3:The request deadline is 2019-12-24T19:04:04.062331705-08:00. The deadline cannot be more than 30s in the future. (Google::Gax::InvalidArgumentError)
Thank you for the issue. There was a change to the default network configuration in release 1.3.2 that is causing this. We are currently in a release freeze for the holidays, but we will get a new release as soon as the freeze is over. For now it is best to downgrade to release 1.3.1.
@dazuma Here is the commit that increased the timeouts to greater than 30 seconds.
The upstream configs have been fixed. Tonight's autosynth should pick up the changes. I'm going to yank 1.3.2 in the meantime, as it's just not going to work for people.
The original settings have been restored for the v2 client, and we are requesting the same for the v2beta2 and v2beta3 clients. We will release an update when all client settings are restored.
Sorry, we neglected to close this issue. The updated libraries were released quite some time ago.
Most helpful comment
The upstream configs have been fixed. Tonight's autosynth should pick up the changes. I'm going to yank 1.3.2 in the meantime, as it's just not going to work for people.