Code review sweep (run 25135365127)#18421
Merged
Merged
Conversation
Automated code review of instrumentation/cassandra/cassandra-4.0/javaagent.
Automated code review of instrumentation/cassandra/cassandra-4.4/javaagent.
Automated code review of instrumentation/clickhouse/clickhouse-client-v1-0.5/javaagent.
Automated code review of instrumentation/clickhouse/clickhouse-client-v2-0.8/javaagent.
Automated code review of instrumentation/couchbase/couchbase-2.6/javaagent.
Automated code review of instrumentation/couchbase/couchbase-3.1.6/javaagent.
832de3b to
545c40b
Compare
trask
approved these changes
Apr 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automated code review sweep walked the following modules in order
and stopped after accumulating at least 10 modified files:
cassandra-4.0:javaagentcassandra-4.4:javaagentcassandra-4.4:librarycassandra-4.4:testingcassandra-common-4.0:testingclickhouse-client-common:javaagentclickhouse-client-v1-0.5:javaagentclickhouse-client-v2-0.8:javaagentcouchbase-2.0:javaagentcouchbase-2.6:javaagentcouchbase-3.1.6:javaagentcouchbase-3.1.6:tracing-opentelemetry-shadedcouchbase-3.1:javaagentModule:
cassandra-4.0:javaagentModule path:
instrumentation/cassandra/cassandra-4.0/javaagentSummary
Applied one safe repository-guideline fix in
cassandra-4.0javaagent and committed it asef6a940b.Applied Changes
Javaagent
File:
CassandraClientInstrumentationModule.java:31Change: Normalized chained `hasClassesNamed(...)` landmark checks in `classLoaderMatcher()` to keep single-class checks on one line with version comments immediately above each matcher call.
Reason: `javaagent-module-patterns.md` requires chained single-class `hasClassesNamed(...)` calls to keep the class string inline and place version-boundary comments directly above the relevant matcher.
Module:
cassandra-4.4:javaagentModule path:
instrumentation/cassandra/cassandra-4.4/javaagentSummary
Applied safe repository-guideline fixes for
instrumentation/cassandra/cassandra-4.4/javaagentand committed them in31b0c846.Applied Changes
Build
File:
build.gradle.kts:9Change: Changed the open-ended muzzle range from `versions.set("[4.4,]")` to `versions.set("[4.4,)")`.
Reason: `gradle-conventions.md` requires proper Maven version range syntax such as `"[1.0,)"` for javaagent muzzle `pass` blocks.
Javaagent
File:
CompletionStageFunction.java:8Change: Added a static import for `CassandraSingletons.telemetry` and changed the call site to `telemetry().wrap(...)`.
Reason: `javaagent-singletons-patterns.md` says callers should static import exported `*Singletons` accessors and use them unqualified.
Module:
cassandra-4.4:libraryModule path:
instrumentation/cassandra/cassandra-4.4/librarySummary
No safe deterministic fixes were applied under
instrumentation/cassandra/cassandra-4.4/library. The modulemetadata.yamlentry forotel.instrumentation.common.db.query-sanitization.enabledmatches the library builder default and declarative-name rules.Applied Changes
No safe automated changes were applied.
Unresolved Items
File:
CassandraTelemetry.javaReason: `CassandraTelemetry` is a public library API class that appears subclassable; making it `final` or narrowing its protected constructor would align with the style/library patterns, but it is source-incompatible for a published library artifact and should be handled as an explicit non-stable API breaking change with changelog/release intent.
File:
CassandraTelemetryBuilder.javaReason: `CassandraTelemetryBuilder` has protected construction/customization hooks while the library pattern prefers a `final` builder with a package-private constructor, but changing that public/protected API is source-incompatible and requires an explicit non-stable API breaking-change decision rather than an automatic review fix.
Module:
cassandra-4.4:testingModule path:
instrumentation/cassandra/cassandra-4.4/testingSummary
No safe repository-guideline fixes were applied. Reviewed scoped source under
instrumentation/cassandra/cassandra-4.4/testingand the modulemetadata.yaml; existinghasAttributesSatisfyingExactly(...),AutoCleanupExtension, semconv, dependency, and config metadata patterns match repository guidance.Applied Changes
No safe automated changes were applied.
Module:
cassandra-common-4.0:testingModule path:
instrumentation/cassandra/cassandra-common-4.0/testingSummary
No safe repository-guideline fixes were applied after reviewing
instrumentation/cassandra/cassandra-common-4.0/testing; the reviewablebuild.gradle.ktsandAbstractCassandraTest.javaalready align with the loaded style, testing, Gradle, and metadata guidance.Applied Changes
No safe automated changes were applied.
Module:
clickhouse-client-common:javaagentModule path:
instrumentation/clickhouse/clickhouse-client-common/javaagentSummary
No safe repository-guideline fixes were found in
instrumentation/clickhouse/clickhouse-client-common/javaagent; no files were changed.Applied Changes
No safe automated changes were applied.
Module:
clickhouse-client-v1-0.5:javaagentModule path:
instrumentation/clickhouse/clickhouse-client-v1-0.5/javaagentSummary
Applied and committed one safe review fix for
clickhouse-client-v1-0.5javaagent: nullable ByteBuddy advice values are now declared explicitly.Applied Changes
Nullability
File:
ClickHouseClientV1Instrumentation.java:51Change: Added `@Nullable` to the `onEnter()` return, nullable `@Advice.Argument`, nullable `@Advice.Thrown`, and nullable `@Advice.Enter` parameters.
Reason: Repository nullability guidance requires annotating values that can actually be `null`; this advice returns `null` to skip instrumentation, instrumented callers can pass a `null` `ClickHouseRequest`, `@Advice.Thrown` is `null` on successful execution, and `@Advice.Enter` is `null` when enter advice skips span creation.
Module:
clickhouse-client-v2-0.8:javaagentModule path:
instrumentation/clickhouse/clickhouse-client-v2-0.8/javaagentSummary
Applied and committed safe repository-guideline fixes for
clickhouse-client-v2-0.8javaagent.Applied Changes
Nullability
File:
ClickHouseClientV2Instrumentation.java:49Change: Added `@Nullable` to nullable advice return, `@Advice.Argument`, `@Advice.Thrown`, and `@Advice.Enter` values.
Reason: Repository nullability guidance requires annotating values that can be `null`; the advice returns `null`, accepts a nullable query argument, receives nullable thrown exceptions, and may receive a nullable `ClickHouseScope`.
File:
ClickHouseClientV2Singletons.java:41Change: Added `@Nullable` to `getAddressAndPort()` return value and the `setAddressAndPort()` `endpoint` parameter.
Reason: Repository nullability guidance requires annotating concrete nullable flows; `VirtualField.get()` can return `null`, and callers pass `null` when no ClickHouse endpoint is available.
Style
File:
ClickHouseClientV2Test.java:59Change: Renamed literal static final test fields to uppercase constant names: `DATABASE_NAME`, `TABLE_NAME`, `USERNAME`, and `PASSWORD`.
Reason: The style guide requires uppercase names for constant-like fields such as stable literal string constants.
Module:
couchbase-2.0:javaagentModule path:
instrumentation/couchbase/couchbase-2.0/javaagentSummary
No safe repository-guideline fixes were needed under
instrumentation/couchbase/couchbase-2.0/javaagent; reviewed source, tests,build.gradle.kts, siblingtestInstrumentationwiring, and mandatorymetadata.yamlconfig coverage.Applied Changes
No safe automated changes were applied.
Module:
couchbase-2.6:javaagentModule path:
instrumentation/couchbase/couchbase-2.6/javaagentSummary
Applied one safe repository-guideline fix under
instrumentation/couchbase/couchbase-2.6/javaagentand committed it as5127bde7.Applied Changes
Testing
File:
Couchbase26Util.java:27Change: Replaced repeated `Boolean.getBoolean(...)` checks with a module-level `EXPERIMENTAL_ATTRIBUTES` flag constant.
Reason: The testing guideline for flag-gated assertions says to read experimental flags through a shared/per-module constant instead of repeated inline `Boolean.getBoolean(...)` calls.
Module:
couchbase-3.1.6:javaagentModule path:
instrumentation/couchbase/couchbase-3.1.6/javaagentSummary
Applied and committed one safe repository-guideline fix for
couchbase-3.1.6javaagent tests.Applied Changes
Testing
File:
CouchbaseClient316Test.java:65Change: Registered the dedicated `ClusterEnvironment` with `cleanup.deferAfterAll(environment::shutdown)`.
Reason: Repository test resource cleanup guidance requires class-scoped resources created in `@BeforeAll` to be cleaned up with `AutoCleanupExtension.deferAfterAll(...)`; the sibling Couchbase 3.1 test already uses this pattern for the same resource.
Module:
couchbase-3.1.6:tracing-opentelemetry-shadedModule path:
instrumentation/couchbase/couchbase-3.1.6/tracing-opentelemetry-shadedSummary
No safe repository-guideline fixes were applied. The only tracked file under
instrumentation/couchbase/couchbase-3.1.6/tracing-opentelemetry-shadedisbuild.gradle.kts, and it already matches the established Couchbase shaded-module Gradle pattern; generatedbuild/artifacts were skipped as non-reviewable outputs. The modulemetadata.yamlhas no config entries and no Couchbase instrumentation config usage was found requiring metadata changes.Applied Changes
No safe automated changes were applied.
Module:
couchbase-3.1:javaagentModule path:
instrumentation/couchbase/couchbase-3.1/javaagentSummary
Applied and committed one safe repository-guideline fix for
couchbase-3.1javaagent.Applied Changes
Javaagent
File:
CouchbaseEnvironmentInstrumentation.java:39Change: Changed the `GlobalOpenTelemetry.getTracer(...)` instrumentation scope from `io.opentelemetry.javaagent.couchbase-3.1` to `io.opentelemetry.couchbase-3.1`.
Reason: Repository javaagent naming guidance expects instrumentation names to match `io.opentelemetry.<module-name>`; this also aligns the older `Tracer`-based Couchbase shim with sibling Couchbase modules.
Download code review diagnostics