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

Resource Detector for Cloud Run/Cloud Functions #194

Merged
merged 7 commits into from
Sep 28, 2022
Merged

Resource Detector for Cloud Run/Cloud Functions #194

merged 7 commits into from
Sep 28, 2022

Conversation

RangelReale
Copy link
Contributor

Based on the Go code.

Fixes #193

Copy link
Collaborator

@aabmass aabmass left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, @dashpole can you approve if the resource detection logic looks good?

@aabmass
Copy link
Collaborator

aabmass commented Sep 21, 2022

/gcbrun

"cloud.platform": "gcp_cloud_run",
"cloud.region": all_metadata["instance"]["region"].split("/")[-1],
"faas.id": all_metadata["instance"]["id"],
"gcp.resource_type": "cloud_run",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not familiar with gcp.resource_type. It seems like duplicate information with cloud.platform. Why is it included?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It predates cloud.platform so it was our hack to make things work. We should get rid of it, see #85

"cloud.platform": "gcp_cloud_functions",
"cloud.region": all_metadata["instance"]["region"].split("/")[-1],
"faas.id": all_metadata["instance"]["id"],
"gcp.resource_type": "cloud_functions",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as above.

@dashpole
Copy link
Contributor

Going to merge this, and then track removal of the extra attribute with #85

@dashpole dashpole merged commit 8ce5ecf into GoogleCloudPlatform:main Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Resource detector should detect more services
3 participants