Skip to content

Commit 6536c0f

Browse files
chore: generate libraries at Tue Jul 22 06:20:48 UTC 2025
1 parent 1c37cf4 commit 6536c0f

File tree

3 files changed

+11
-14
lines changed

3 files changed

+11
-14
lines changed

google-cloud-spanner/src/main/java/com/google/cloud/spanner/BuiltInMetricsConstant.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,10 +98,8 @@ public class BuiltInMetricsConstant {
9898
AttributeKey.stringKey("directpath_enabled");
9999
public static final AttributeKey<String> DIRECT_PATH_USED_KEY =
100100
AttributeKey.stringKey("directpath_used");
101-
public static final AttributeKey<String> REQUEST_ID_KEY =
102-
AttributeKey.stringKey(REQUEST_ID);
103-
public static Set<String> ALLOWED_EXEMPLARS_ATTRIBUTES = new HashSet<>(
104-
Arrays.asList(REQUEST_ID));
101+
public static final AttributeKey<String> REQUEST_ID_KEY = AttributeKey.stringKey(REQUEST_ID);
102+
public static Set<String> ALLOWED_EXEMPLARS_ATTRIBUTES = new HashSet<>(Arrays.asList(REQUEST_ID));
105103

106104
// IP address prefixes allocated for DirectPath backends.
107105
public static final String DP_IPV6_PREFIX = "2001:4860:8040";

google-cloud-spanner/src/main/java/com/google/cloud/spanner/SpannerCloudMonitoringExporterUtils.java

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -295,12 +295,13 @@ private static String makeSpanName(String projectId, String traceId, String span
295295
private static DroppedLabels mapFilteredAttributes(Attributes attributes) {
296296
DroppedLabels.Builder labels = DroppedLabels.newBuilder();
297297
attributes.forEach((k, v) -> labels.putLabel(cleanAttributeKey(k.getKey()), v.toString()));
298-
attributes.forEach((k, v) -> {
299-
String key = cleanAttributeKey(k.getKey());
300-
if (ALLOWED_EXEMPLARS_ATTRIBUTES.contains(key)) {
301-
labels.putLabel(key, v.toString());
302-
}
303-
});
298+
attributes.forEach(
299+
(k, v) -> {
300+
String key = cleanAttributeKey(k.getKey());
301+
if (ALLOWED_EXEMPLARS_ATTRIBUTES.contains(key)) {
302+
labels.putLabel(key, v.toString());
303+
}
304+
});
304305
return labels.build();
305306
}
306307

google-cloud-spanner/src/main/java/com/google/cloud/spanner/spi/v1/HeaderInterceptor.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -309,11 +309,9 @@ private void addDirectPathUsedAttribute(
309309
}
310310
}
311311

312-
private void addRequestIdAttribute(
313-
CompositeTracer compositeTracer, String requestId) {
312+
private void addRequestIdAttribute(CompositeTracer compositeTracer, String requestId) {
314313
if (compositeTracer != null) {
315-
compositeTracer.addAttributes(
316-
BuiltInMetricsConstant.REQUEST_ID_KEY.getKey(), requestId);
314+
compositeTracer.addAttributes(BuiltInMetricsConstant.REQUEST_ID_KEY.getKey(), requestId);
317315
}
318316
}
319317

0 commit comments

Comments
 (0)