Skip to content

fix(gax): reduce visibility of ApiTracerContext methods#12738

Open
blakeli0 wants to merge 6 commits intomainfrom
reduce-api-tracer-context-scope
Open

fix(gax): reduce visibility of ApiTracerContext methods#12738
blakeli0 wants to merge 6 commits intomainfrom
reduce-api-tracer-context-scope

Conversation

@blakeli0
Copy link
Copy Markdown
Contributor

@blakeli0 blakeli0 commented Apr 10, 2026

This PR

  • Reduced visibility of several methods in ApiTracerContext to package-private to limit API surface area.
  • Returns a new instance of OpenTelemetryMetricsFactory in withContext method to maintain immutability.

@blakeli0 blakeli0 requested a review from a team as a code owner April 10, 2026 03:17
@blakeli0 blakeli0 changed the title feat(o11y): reduce visibility of ApiTracerContext methods fix(gax): reduce visibility of ApiTracerContext methods Apr 10, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request modifies ApiTracerContext.java by reducing the visibility of several methods from public to package-private. The review feedback correctly identifies these changes as breaking for the public API and recommends restoring the public access modifier for methods including serverPort(), operationType(), serviceName(), urlDomain(), destinationResourceId(), getAttemptAttributes(), empty(), and toBuilder().

@blakeli0 blakeli0 requested a review from diegomarquezp April 10, 2026 03:58
@blakeli0 blakeli0 requested a review from diegomarquezp April 10, 2026 15:55
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.

2 participants