Bump armeria-bom from 1.20.3 to 1.21.0 (#5065)
* Bump armeria-bom from 1.20.3 to 1.21.0 Bumps [armeria-bom](https://github.com/line/armeria) from 1.20.3 to 1.21.0. - [Release notes](https://github.com/line/armeria/releases) - [Changelog](https://github.com/line/armeria/blob/master/.post-release-msg) - [Commits](https://github.com/line/armeria/compare/armeria-1.20.3...armeria-1.21.0) --- updated-dependencies: - dependency-name: com.linecorp.armeria:armeria-bom dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * Fix PrometheusHttpServerTest 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
ad2013ffbd
commit
7b92428281
|
@ -15,7 +15,7 @@ val DEPENDENCY_BOMS = listOf(
|
|||
"com.fasterxml.jackson:jackson-bom:2.14.1",
|
||||
"com.google.guava:guava-bom:31.1-jre",
|
||||
"com.google.protobuf:protobuf-bom:3.21.12",
|
||||
"com.linecorp.armeria:armeria-bom:1.20.3",
|
||||
"com.linecorp.armeria:armeria-bom:1.21.0",
|
||||
"com.squareup.okhttp3:okhttp-bom:4.10.0",
|
||||
"io.grpc:grpc-bom:1.51.1",
|
||||
"io.zipkin.brave:brave-bom:5.14.1",
|
||||
|
|
|
@ -10,8 +10,8 @@ import static org.assertj.core.api.Assertions.assertThat;
|
|||
import static org.assertj.core.api.Assertions.assertThatThrownBy;
|
||||
|
||||
import com.google.common.collect.ImmutableList;
|
||||
import com.google.common.io.ByteStreams;
|
||||
import com.linecorp.armeria.client.WebClient;
|
||||
import com.linecorp.armeria.client.encoding.DecodingClient;
|
||||
import com.linecorp.armeria.common.AggregatedHttpResponse;
|
||||
import com.linecorp.armeria.common.HttpHeaderNames;
|
||||
import com.linecorp.armeria.common.HttpMethod;
|
||||
|
@ -27,7 +27,11 @@ import io.opentelemetry.sdk.metrics.internal.data.ImmutableMetricData;
|
|||
import io.opentelemetry.sdk.metrics.internal.data.ImmutableSumData;
|
||||
import io.opentelemetry.sdk.metrics.internal.export.MetricProducer;
|
||||
import io.opentelemetry.sdk.resources.Resource;
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.IOException;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.util.Collections;
|
||||
import java.util.zip.GZIPInputStream;
|
||||
import org.junit.jupiter.api.AfterAll;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
@ -150,17 +154,19 @@ class PrometheusHttpServerTest {
|
|||
}
|
||||
|
||||
@Test
|
||||
void fetchPrometheusCompressed() {
|
||||
void fetchPrometheusCompressed() throws IOException {
|
||||
WebClient client =
|
||||
WebClient.builder("http://localhost:" + prometheusServer.getAddress().getPort())
|
||||
.decorator(DecodingClient.newDecorator())
|
||||
.addHeader(HttpHeaderNames.ACCEPT_ENCODING, "gzip")
|
||||
.build();
|
||||
AggregatedHttpResponse response = client.get("/").aggregate().join();
|
||||
assertThat(response.status()).isEqualTo(HttpStatus.OK);
|
||||
assertThat(response.headers().get(HttpHeaderNames.CONTENT_TYPE))
|
||||
.isEqualTo("text/plain; version=0.0.4; charset=utf-8");
|
||||
assertThat(response.headers().get(HttpHeaderNames.CONTENT_ENCODING)).isEqualTo("gzip");
|
||||
assertThat(response.contentUtf8())
|
||||
GZIPInputStream gis = new GZIPInputStream(new ByteArrayInputStream(response.content().array()));
|
||||
String content = new String(ByteStreams.toByteArray(gis), StandardCharsets.UTF_8);
|
||||
assertThat(content)
|
||||
.isEqualTo(
|
||||
"# TYPE target info\n"
|
||||
+ "# HELP target Target metadata\n"
|
||||
|
|
Loading…
Reference in New Issue