Bump errorProneVersion from 2.18.0 to 2.19.0 (#5435)
Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jack Berg <jberg@newrelic.com>
This commit is contained in:
parent
d67faf2aef
commit
d45dce3b2a
|
@ -29,7 +29,7 @@ val DEPENDENCY_BOMS = listOf(
|
||||||
)
|
)
|
||||||
|
|
||||||
val autoValueVersion = "1.10.1"
|
val autoValueVersion = "1.10.1"
|
||||||
val errorProneVersion = "2.18.0"
|
val errorProneVersion = "2.19.0"
|
||||||
val jmhVersion = "1.36"
|
val jmhVersion = "1.36"
|
||||||
// Mockito 5.x.x requires Java 11 https://github.com/mockito/mockito/releases/tag/v5.0.0
|
// Mockito 5.x.x requires Java 11 https://github.com/mockito/mockito/releases/tag/v5.0.0
|
||||||
val mockitoVersion = "4.11.0"
|
val mockitoVersion = "4.11.0"
|
||||||
|
|
|
@ -7,6 +7,7 @@ package io.opentelemetry.exporter.internal.retry;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.SocketTimeoutException;
|
import java.net.SocketTimeoutException;
|
||||||
|
import java.util.Locale;
|
||||||
import java.util.concurrent.ThreadLocalRandom;
|
import java.util.concurrent.ThreadLocalRandom;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
import java.util.function.Function;
|
import java.util.function.Function;
|
||||||
|
@ -104,7 +105,7 @@ public final class RetryInterceptor implements Interceptor {
|
||||||
String message = e.getMessage();
|
String message = e.getMessage();
|
||||||
// Connect timeouts can produce SocketTimeoutExceptions with no message, or with "connect timed
|
// Connect timeouts can produce SocketTimeoutExceptions with no message, or with "connect timed
|
||||||
// out"
|
// out"
|
||||||
return message == null || message.toLowerCase().contains("connect timed out");
|
return message == null || message.toLowerCase(Locale.ROOT).contains("connect timed out");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Visible for testing
|
// Visible for testing
|
||||||
|
|
|
@ -22,6 +22,7 @@ import java.io.RandomAccessFile;
|
||||||
import java.net.MalformedURLException;
|
import java.net.MalformedURLException;
|
||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
import java.time.Duration;
|
import java.time.Duration;
|
||||||
|
import java.util.Locale;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.function.BiConsumer;
|
import java.util.function.BiConsumer;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.Consumer;
|
||||||
|
@ -154,7 +155,7 @@ public final class OtlpConfigUtil {
|
||||||
}
|
}
|
||||||
AggregationTemporality temporality;
|
AggregationTemporality temporality;
|
||||||
try {
|
try {
|
||||||
temporality = AggregationTemporality.valueOf(temporalityStr.toUpperCase());
|
temporality = AggregationTemporality.valueOf(temporalityStr.toUpperCase(Locale.ROOT));
|
||||||
} catch (IllegalArgumentException e) {
|
} catch (IllegalArgumentException e) {
|
||||||
throw new ConfigurationException(
|
throw new ConfigurationException(
|
||||||
"Unrecognized aggregation temporality: " + temporalityStr, e);
|
"Unrecognized aggregation temporality: " + temporalityStr, e);
|
||||||
|
|
|
@ -11,6 +11,7 @@ import io.opentracing.Tracer;
|
||||||
import io.opentracing.propagation.Format.Builtin;
|
import io.opentracing.propagation.Format.Builtin;
|
||||||
import io.opentracing.propagation.TextMapInjectAdapter;
|
import io.opentracing.propagation.TextMapInjectAdapter;
|
||||||
import io.opentracing.tag.Tags;
|
import io.opentracing.tag.Tags;
|
||||||
|
import java.util.Locale;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.concurrent.ArrayBlockingQueue;
|
import java.util.concurrent.ArrayBlockingQueue;
|
||||||
|
|
||||||
|
@ -38,7 +39,7 @@ final class Client {
|
||||||
if (convertKeysToUpperCase) {
|
if (convertKeysToUpperCase) {
|
||||||
Message newMessage = new Message();
|
Message newMessage = new Message();
|
||||||
for (Map.Entry<String, String> entry : message.entrySet()) {
|
for (Map.Entry<String, String> entry : message.entrySet()) {
|
||||||
newMessage.put(entry.getKey().toUpperCase(), entry.getValue());
|
newMessage.put(entry.getKey().toUpperCase(Locale.getDefault()), entry.getValue());
|
||||||
}
|
}
|
||||||
message = newMessage;
|
message = newMessage;
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@ package io.opentelemetry.sdk.metrics.internal.aggregator;
|
||||||
|
|
||||||
import io.opentelemetry.sdk.metrics.Aggregation;
|
import io.opentelemetry.sdk.metrics.Aggregation;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
|
import java.util.Locale;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -59,7 +60,7 @@ public class AggregationUtil {
|
||||||
* @throws IllegalArgumentException if the name is not recognized
|
* @throws IllegalArgumentException if the name is not recognized
|
||||||
*/
|
*/
|
||||||
public static Aggregation forName(String name) {
|
public static Aggregation forName(String name) {
|
||||||
Aggregation aggregation = aggregationByName.get(name.toLowerCase());
|
Aggregation aggregation = aggregationByName.get(name.toLowerCase(Locale.ROOT));
|
||||||
if (aggregation == null) {
|
if (aggregation == null) {
|
||||||
throw new IllegalArgumentException("Unrecognized aggregation name " + name);
|
throw new IllegalArgumentException("Unrecognized aggregation name " + name);
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,6 +20,7 @@ import io.opentelemetry.api.metrics.MeterProvider;
|
||||||
import io.opentelemetry.internal.testing.slf4j.SuppressLogger;
|
import io.opentelemetry.internal.testing.slf4j.SuppressLogger;
|
||||||
import io.opentelemetry.sdk.metrics.internal.state.MetricStorageRegistry;
|
import io.opentelemetry.sdk.metrics.internal.state.MetricStorageRegistry;
|
||||||
import io.opentelemetry.sdk.testing.exporter.InMemoryMetricReader;
|
import io.opentelemetry.sdk.testing.exporter.InMemoryMetricReader;
|
||||||
|
import java.util.Locale;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.jupiter.api.extension.RegisterExtension;
|
import org.junit.jupiter.api.extension.RegisterExtension;
|
||||||
|
|
||||||
|
@ -175,7 +176,7 @@ class SdkMeterTest {
|
||||||
.setUnit("metric tonnes")
|
.setUnit("metric tonnes")
|
||||||
.build();
|
.build();
|
||||||
assertThat(longCounter).isNotNull();
|
assertThat(longCounter).isNotNull();
|
||||||
sdkMeter.counterBuilder("testLongCounter".toUpperCase()).build();
|
sdkMeter.counterBuilder("testLongCounter".toUpperCase(Locale.getDefault())).build();
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -213,7 +214,7 @@ class SdkMeterTest {
|
||||||
.build();
|
.build();
|
||||||
assertThat(longUpDownCounter).isNotNull();
|
assertThat(longUpDownCounter).isNotNull();
|
||||||
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
||||||
sdkMeter.upDownCounterBuilder("testLongUpDownCounter".toUpperCase()).build();
|
sdkMeter.upDownCounterBuilder("testLongUpDownCounter".toUpperCase(Locale.getDefault())).build();
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -255,7 +256,10 @@ class SdkMeterTest {
|
||||||
assertThat(longHistogram).isNotNull();
|
assertThat(longHistogram).isNotNull();
|
||||||
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
||||||
|
|
||||||
sdkMeter.histogramBuilder("testLongValueRecorder".toUpperCase()).ofLongs().build();
|
sdkMeter
|
||||||
|
.histogramBuilder("testLongValueRecorder".toUpperCase(Locale.getDefault()))
|
||||||
|
.ofLongs()
|
||||||
|
.build();
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -283,7 +287,10 @@ class SdkMeterTest {
|
||||||
.buildWithCallback(obs -> {});
|
.buildWithCallback(obs -> {});
|
||||||
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
||||||
|
|
||||||
sdkMeter.gaugeBuilder("longValueObserver".toUpperCase()).ofLongs().buildWithCallback(x -> {});
|
sdkMeter
|
||||||
|
.gaugeBuilder("longValueObserver".toUpperCase(Locale.getDefault()))
|
||||||
|
.ofLongs()
|
||||||
|
.buildWithCallback(x -> {});
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -309,7 +316,9 @@ class SdkMeterTest {
|
||||||
.buildWithCallback(x -> {});
|
.buildWithCallback(x -> {});
|
||||||
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
||||||
|
|
||||||
sdkMeter.counterBuilder("testLongSumObserver".toUpperCase()).buildWithCallback(x -> {});
|
sdkMeter
|
||||||
|
.counterBuilder("testLongSumObserver".toUpperCase(Locale.getDefault()))
|
||||||
|
.buildWithCallback(x -> {});
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -336,7 +345,7 @@ class SdkMeterTest {
|
||||||
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
assertThat(metricStorageLogs.getEvents()).isEmpty();
|
||||||
|
|
||||||
sdkMeter
|
sdkMeter
|
||||||
.upDownCounterBuilder("testLongUpDownSumObserver".toUpperCase())
|
.upDownCounterBuilder("testLongUpDownSumObserver".toUpperCase(Locale.getDefault()))
|
||||||
.buildWithCallback(x -> {});
|
.buildWithCallback(x -> {});
|
||||||
metricStorageLogs.assertContains("Found duplicate metric definition");
|
metricStorageLogs.assertContains("Found duplicate metric definition");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue