Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Outdated usage of entries.list API request #971

Closed
frankyn opened this issue Oct 14, 2016 · 10 comments · Fixed by #1069
Closed

Outdated usage of entries.list API request #971

frankyn opened this issue Oct 14, 2016 · 10 comments · Fixed by #1069
Assignees
Labels
api: logging Issues related to the Cloud Logging API. release blocking Required feature/issue must be fixed prior to next release.
Milestone

Comments

@frankyn
Copy link
Member

frankyn commented Oct 14, 2016

Issue: In the logging/service.rb file, an deprecated fieldName (projectIds) of entries.list API is being used.

https://github.com/GoogleCloudPlatform/google-cloud-ruby/blob/2d6c92137152d5297e91e1b5c336ed94b5ac96e7/google-cloud-logging/lib/google/cloud/logging/service.rb#L95-L109

@blowmage blowmage added the api: logging Issues related to the Cloud Logging API. label Oct 14, 2016
@blowmage blowmage self-assigned this Oct 14, 2016
@blowmage
Copy link
Contributor

Ugh. When was this field deprecated?

It looks like resource_names was added to the protobuf fields a couple weeks ago. I take it we should resource_names instead of project_ids?

@blowmage
Copy link
Contributor

@dazuma's Any input on this? Should we add a resources argument to the project#entities method?

@frankyn
Copy link
Member Author

frankyn commented Oct 14, 2016

While working with Remi, we came across it trying to figure out a different issue. Yes, that's what we understood as of now.

@blowmage
Copy link
Contributor

@hxiong388 Thoughts?

@hxiong388
Copy link
Contributor

According to the doc, resourceNames field includes the deprecated projectIds value. But since the GAPIC API currently requires project_ids parameter, maybe we can achieve backward compatibility by adding a new resource_names parameter to Service#list_entries, and consolidate project_ids and resource_names into one parameter:

def list_entries projects: nil, resource_names: [], ...
  resource_names = Array(projects || @project) + resource_names
  ...
  paged_enum = logging.list_log_entries nil, resource_names: resource_names , ...

Propagate the same resource_names parameter to Google::Cloud::Logging::Project#entries as well.

Later whoever removes the deprecated project_ids field from GAPIC API can clean up these two Veneer APIs.

@blowmage
Copy link
Contributor

When will project_ids be removed from the API? Also, the documentation site that shows the field as deprecated is showing the version as v2beta1, but Google Cloud Stackdriver Logging is using v2. Are the GAPIC/GRPC endpoints stable? Or will there be additional changes to the released API?

@frankyn
Copy link
Member Author

frankyn commented Oct 14, 2016

I don't want to leave you hanging Mike, I have forwarded your questions and waiting on a response!

@filipjs
Copy link

filipjs commented Oct 14, 2016

Hi. We do not have a timeline yet for the field removal, but most likely that will happen in a couple of months. If you have an option to change your code to use resource_names, please do so.
Yes, we are in the process of renaming our docs from v2beta1 to v2, and there are no other changes planned. The endpoints also do not change.

@blowmage
Copy link
Contributor

@filipjs If a user is using the current release of the google-cloud-logging library, and does not upgrade to a new version that uses the new field, will their client stop working? Are you removing the field from the published protobufs? Or are you removing the field from the server API?

@filipjs
Copy link

filipjs commented Oct 14, 2016

It will continue to work until it's removed from the protobuf, which means the service will stop accepting it.

@blowmage blowmage added this to the v0.21 milestone Oct 14, 2016
@blowmage blowmage modified the milestones: v0.21, v1 Beta Oct 20, 2016
@quartzmo quartzmo added the release blocking Required feature/issue must be fixed prior to next release. label Nov 21, 2016
blowmage added a commit to blowmage/google-cloud-ruby that referenced this issue Nov 21, 2016
Effectively replaces the projects argument, which is deprecated and will eventually be removed.

[closes googleapis#971]
gcf-owl-bot bot added a commit that referenced this issue Dec 12, 2024
Source-Link: googleapis/googleapis@7d0c6be

Source-Link: googleapis/googleapis-gen@2ddc476
Copy-Tag: eyJwIjoiZ29vZ2xlLWNsb3VkLWNvbXB1dGUtdjEvLk93bEJvdC55YW1sIiwiaCI6IjJkZGM0NzZkNGNjZTZmMDdiNTFjYzY5NmZmYzNlMGM0Yzc2MWJiMTgifQ==
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: logging Issues related to the Cloud Logging API. release blocking Required feature/issue must be fixed prior to next release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants