Skip to content

Fix #258 enable mapping when not gcp kubernetes#340

Merged
psx95 merged 9 commits intoGoogleCloudPlatform:mainfrom
tkmsaaaam:fix-issue-258
May 10, 2024
Merged

Fix #258 enable mapping when not gcp kubernetes#340
psx95 merged 9 commits intoGoogleCloudPlatform:mainfrom
tkmsaaaam:fix-issue-258

Conversation

@tkmsaaaam
Copy link
Copy Markdown
Contributor

Resolves #258

@tkmsaaaam tkmsaaaam requested a review from a team as a code owner May 6, 2024 11:33
@google-cla
Copy link
Copy Markdown

google-cla bot commented May 6, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@dashpole
Copy link
Copy Markdown
Contributor

dashpole commented May 6, 2024

/gcbrun

Copy link
Copy Markdown
Contributor

@psx95 psx95 left a comment

Choose a reason for hiding this comment

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

Thank you for the PR!

Overall looks good, I added some comments for improving code readability.

P.S: For fixing code style, you can run ./gradlew spotlessApply from the root of the repository.

@tkmsaaaam tkmsaaaam requested a review from psx95 May 9, 2024 14:18
@psx95 psx95 self-assigned this May 9, 2024
Copy link
Copy Markdown
Contributor

@psx95 psx95 left a comment

Choose a reason for hiding this comment

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

Thanks for making the changes!

I opened a PR against your repository, with some code refactors in the test file to make it more consistent with our repository. PTAL and merge the changes from that PR in your branch.

PR: tkmsaaaam#1

@tkmsaaaam tkmsaaaam requested a review from psx95 May 10, 2024 13:33
Copy link
Copy Markdown
Contributor

@psx95 psx95 left a comment

Choose a reason for hiding this comment

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

LGTM

@psx95
Copy link
Copy Markdown
Contributor

psx95 commented May 10, 2024

/gcbrun

@psx95
Copy link
Copy Markdown
Contributor

psx95 commented May 10, 2024

@tkmsaaaam it looks like one of the file has some formatting issues, can you run ./gradlew spotlessApply to confirm and commit any suggested changes ?

@tkmsaaaam
Copy link
Copy Markdown
Contributor Author

@psx95 Thank you for reviewing many times. I fixed it.

@psx95
Copy link
Copy Markdown
Contributor

psx95 commented May 10, 2024

/gcbrun

@psx95 psx95 merged commit 77ac82a into GoogleCloudPlatform:main May 10, 2024
@tkmsaaaam tkmsaaaam deleted the fix-issue-258 branch May 11, 2024 00:21
tkmsaaaam added a commit to tkmsaaaam/opentelemetry-operations-java that referenced this pull request May 11, 2024
@tkmsaaaam tkmsaaaam mentioned this pull request May 11, 2024
@tkmsaaaam
Copy link
Copy Markdown
Contributor Author

@psx95 My apologize. I fixed this issue. But I noticed it contained bug. So I fixed it. Please review it.
#342

diegomarquezp referenced this pull request in googleapis/sdk-platform-java May 31, 2024
…rces-support to v0.29.0 (#2831)

[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
|
[com.google.cloud.opentelemetry:detector-resources-support](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java)
| `0.28.0` -> `0.29.0` |
[![age](https://developer.mend.io/api/mc/badges/age/maven/com.google.cloud.opentelemetry:detector-resources-support/0.29.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/com.google.cloud.opentelemetry:detector-resources-support/0.29.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/com.google.cloud.opentelemetry:detector-resources-support/0.28.0/0.29.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/com.google.cloud.opentelemetry:detector-resources-support/0.28.0/0.29.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Release Notes

<details>
<summary>GoogleCloudPlatform/opentelemetry-operations-java
(com.google.cloud.opentelemetry:detector-resources-support)</summary>

###
[`v0.29.0`](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/releases/tag/v0.29.0)

[Compare
Source](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/compare/v0.28.0...v0.29.0)

#### Release Highlights

- Non-GKE resource now map to `k8s_*` monitored resource
([#&#8203;340](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/issues/340)
,
[#&#8203;342](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/issues/342))
- Support for mapping to custom Monitored Resources
([#&#8203;346](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/issues/346))
- Newly deprecated APIs:
[mapResource](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/blob/b0caafdaceb2b7418d256cecc05fa8fce9bafecc/exporters/metrics/src/main/java/com/google/cloud/opentelemetry/metric/ResourceTranslator.java#L36)

#### What's Changed

- Update maven-badges to link to sonatype central by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/322](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/322)
- Add auth support for gRPC by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/323](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/323)
- Switch to ConcurrentMap for thread-safety by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/328](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/328)
- Add otlp with spring boot sample by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/327](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/327)
- Change OTel quickstart to use log4j2 instead of logback by
[@&#8203;aabmass](https://togithub.com/aabmass) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/330](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/330)
- Always output logging.googleapis.com/trace_sampled as true by
[@&#8203;aabmass](https://togithub.com/aabmass) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/332](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/332)
- Update JVM flag otel.java.experimental.extension by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/338](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/338)
- Add test case for zone resource detection on GAE standard by
[@&#8203;aabmass](https://togithub.com/aabmass) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/341](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/341)
- Fix
[#&#8203;258](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/issues/258)
enable mapping when not gcp kubernetes by
[@&#8203;tkmsaaaam](https://togithub.com/tkmsaaaam) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/340](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/340)
- Fix
[#&#8203;340](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/issues/340)
bug by [@&#8203;tkmsaaaam](https://togithub.com/tkmsaaaam) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/342](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/342)
- Make all AttributeMappings final by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/347](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/347)
- Add support for custom MR mappings by
[@&#8203;psx95](https://togithub.com/psx95) in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/346](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/346)

#### New Contributors

- [@&#8203;tkmsaaaam](https://togithub.com/tkmsaaaam) made their first
contribution in
[https://github.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/340](https://togithub.com/GoogleCloudPlatform/opentelemetry-operations-java/pull/340)

**Full Changelog**:
GoogleCloudPlatform/opentelemetry-operations-java@v0.28.0...v0.29.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/googleapis/sdk-platform-java).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zNzcuOCIsInVwZGF0ZWRJblZlciI6IjM3LjM3Ny44IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
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.

Verify non-GKE resources map to k8s_* monitored resources

3 participants