Skip to content

Commit a306a43

Browse files
committed
fix(storage): simplify Cloud Monitoring endpoint filter
[Generated-by: AI]
1 parent 82a8c8e commit a306a43

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎java-storage/google-cloud-storage/src/main/java/com/google/cloud/storage/OpenTelemetryBootstrappingUtils.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ static String getCloudMonitoringEndpoint(
233233
final String resolvedHost = host;
234234
String match =
235235
ImmutableList.of(canonicalEndpoint, privateEndpoint, restrictedEndpoint).stream()
236-
.filter(s -> resolvedHost.contains(s) || endpoint.contains(C2P_PREFIX + s))
236+
.filter(resolvedHost::contains)
237237
.collect(Collectors.joining());
238238
if (!StringUtils.isNullOrEmpty(match)) {
239239
metricServiceEndpoint = match;

0 commit comments

Comments
 (0)