Upgrade to Spring Framework 6 and Jakarta EE 9
Closes gh-28619 Closes gh-28620 Closes gh-28621 Closes gh-28622 Closes gh-28623 Closes gh-28624 Closes gh-28625 Closes gh-28626 Closes gh-28627 Closes gh-28628 Closes gh-28629 Closes gh-28630 Closes gh-28631 Closes gh-28632 Closes gh-28633 Closes gh-28634 Closes gh-28635 Closes gh-28636 Closes gh-28638 Closes gh-28639 Closes gh-28640 Closes gh-28644 Closes gh-28645 Closes gh-28650 Closes gh-28711 Closes gh-28866 Closes gh-28867 Closes gh-28868 Closes gh-28872 See gh-28641 See gh-28642 See gh-28643 See gh-28646 See gh-28647 See gh-28648 See gh-28649 See gh-28721 See gh-28869 See gh-28871
This commit is contained in:
parent
91b2eb1a6f
commit
fe7b13ec46
|
@ -5,6 +5,6 @@ org.gradle.parallel=true
|
||||||
org.gradle.jvmargs=-Xmx2g -Dfile.encoding=UTF-8
|
org.gradle.jvmargs=-Xmx2g -Dfile.encoding=UTF-8
|
||||||
|
|
||||||
kotlinVersion=1.6.0
|
kotlinVersion=1.6.0
|
||||||
tomcatVersion=9.0.55
|
tomcatVersion=10.0.12
|
||||||
|
|
||||||
kotlin.stdlib.default.dependency=false
|
kotlin.stdlib.default.dependency=false
|
||||||
|
|
|
@ -101,12 +101,7 @@ dependencies {
|
||||||
exclude group: "commons-logging", module: "commons-logging"
|
exclude group: "commons-logging", module: "commons-logging"
|
||||||
}
|
}
|
||||||
optional("org.flywaydb:flyway-core")
|
optional("org.flywaydb:flyway-core")
|
||||||
optional("org.hibernate:hibernate-core") {
|
optional("org.hibernate:hibernate-core-jakarta")
|
||||||
exclude group: "javax.activation", module: "javax.activation-api"
|
|
||||||
exclude group: "javax.persistence", module: "javax.persistence-api"
|
|
||||||
exclude group: "javax.xml.bind", module: "jaxb-api"
|
|
||||||
exclude group: "org.jboss.spec.javax.transaction", module: "jboss-transaction-api_1.2_spec"
|
|
||||||
}
|
|
||||||
optional("org.hibernate.validator:hibernate-validator")
|
optional("org.hibernate.validator:hibernate-validator")
|
||||||
optional("org.influxdb:influxdb-java")
|
optional("org.influxdb:influxdb-java")
|
||||||
optional("org.liquibase:liquibase-core") {
|
optional("org.liquibase:liquibase-core") {
|
||||||
|
@ -146,9 +141,8 @@ dependencies {
|
||||||
testImplementation("com.squareup.okhttp3:mockwebserver")
|
testImplementation("com.squareup.okhttp3:mockwebserver")
|
||||||
testImplementation("com.jayway.jsonpath:json-path")
|
testImplementation("com.jayway.jsonpath:json-path")
|
||||||
testImplementation("io.undertow:undertow-core")
|
testImplementation("io.undertow:undertow-core")
|
||||||
testImplementation("io.undertow:undertow-servlet") {
|
testImplementation("io.undertow:undertow-servlet-jakartaee9") {
|
||||||
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
||||||
exclude group: "org.jboss.spec.javax.servlet", module: "jboss-servlet-api_4.0_spec"
|
|
||||||
}
|
}
|
||||||
testImplementation("jakarta.xml.bind:jakarta.xml.bind-api")
|
testImplementation("jakarta.xml.bind:jakarta.xml.bind-api")
|
||||||
testImplementation("org.apache.logging.log4j:log4j-to-slf4j")
|
testImplementation("org.apache.logging.log4j:log4j-to-slf4j")
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.cloudfoundry.servlet;
|
||||||
|
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
|
@ -22,8 +22,8 @@ import java.util.LinkedHashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -32,7 +32,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean
|
||||||
import org.springframework.boot.autoconfigure.data.elasticsearch.ReactiveElasticsearchRestClientAutoConfiguration;
|
import org.springframework.boot.autoconfigure.data.elasticsearch.ReactiveElasticsearchRestClientAutoConfiguration;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* {@link EnableAutoConfiguration Auto-configuration} for
|
* {@link EnableAutoConfiguration Auto-configuration} for
|
||||||
|
|
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.jms;
|
||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.autoconfigure.health.CompositeHealthContributorConfiguration;
|
import org.springframework.boot.actuate.autoconfigure.health.CompositeHealthContributorConfiguration;
|
||||||
import org.springframework.boot.actuate.autoconfigure.health.ConditionalOnEnabledHealthIndicator;
|
import org.springframework.boot.actuate.autoconfigure.health.ConditionalOnEnabledHealthIndicator;
|
||||||
|
|
|
@ -16,16 +16,21 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.autoconfigure.metrics.export.prometheus;
|
package org.springframework.boot.actuate.autoconfigure.metrics.export.prometheus;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.net.HttpURLConnection;
|
||||||
import java.net.MalformedURLException;
|
import java.net.MalformedURLException;
|
||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
|
import java.nio.charset.StandardCharsets;
|
||||||
import java.time.Duration;
|
import java.time.Duration;
|
||||||
|
import java.util.Base64;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Clock;
|
import io.micrometer.core.instrument.Clock;
|
||||||
import io.micrometer.prometheus.PrometheusConfig;
|
import io.micrometer.prometheus.PrometheusConfig;
|
||||||
import io.micrometer.prometheus.PrometheusMeterRegistry;
|
import io.micrometer.prometheus.PrometheusMeterRegistry;
|
||||||
import io.prometheus.client.CollectorRegistry;
|
import io.prometheus.client.CollectorRegistry;
|
||||||
import io.prometheus.client.exporter.BasicAuthHttpConnectionFactory;
|
import io.prometheus.client.exporter.DefaultHttpConnectionFactory;
|
||||||
|
import io.prometheus.client.exporter.HttpConnectionFactory;
|
||||||
import io.prometheus.client.exporter.PushGateway;
|
import io.prometheus.client.exporter.PushGateway;
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
@ -154,4 +159,29 @@ public class PrometheusMetricsExportAutoConfiguration {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static class BasicAuthHttpConnectionFactory implements HttpConnectionFactory {
|
||||||
|
|
||||||
|
private final HttpConnectionFactory delegate = new DefaultHttpConnectionFactory();
|
||||||
|
|
||||||
|
private final String authorizationHeader;
|
||||||
|
|
||||||
|
BasicAuthHttpConnectionFactory(String username, String password) {
|
||||||
|
this.authorizationHeader = "Basic " + new String(
|
||||||
|
Base64.getEncoder().encode(new String(username + ":" + password).getBytes(StandardCharsets.UTF_8)),
|
||||||
|
StandardCharsets.UTF_8);
|
||||||
|
}
|
||||||
|
|
||||||
|
String getAuthorizationHeader() {
|
||||||
|
return this.authorizationHeader;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HttpURLConnection create(String url) throws IOException {
|
||||||
|
HttpURLConnection connection = this.delegate.create(url);
|
||||||
|
connection.setRequestProperty("Authorization", this.authorizationHeader);
|
||||||
|
return connection;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.metrics.web.servlet;
|
||||||
|
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import javax.servlet.DispatcherType;
|
import jakarta.servlet.DispatcherType;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.MeterRegistry;
|
import io.micrometer.core.instrument.MeterRegistry;
|
||||||
import io.micrometer.core.instrument.config.MeterFilter;
|
import io.micrometer.core.instrument.config.MeterFilter;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -27,7 +27,7 @@ import java.util.function.Supplier;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
import java.util.stream.Stream;
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.springframework.beans.factory.NoSuchBeanDefinitionException;
|
import org.springframework.beans.factory.NoSuchBeanDefinitionException;
|
||||||
import org.springframework.boot.actuate.autoconfigure.endpoint.web.WebEndpointProperties;
|
import org.springframework.boot.actuate.autoconfigure.endpoint.web.WebEndpointProperties;
|
||||||
|
|
|
@ -20,8 +20,8 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.beans.factory.ListableBeanFactory;
|
import org.springframework.beans.factory.ListableBeanFactory;
|
||||||
import org.springframework.core.annotation.AnnotationAwareOrderComparator;
|
import org.springframework.core.annotation.AnnotationAwareOrderComparator;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,8 +20,8 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.beans.factory.ListableBeanFactory;
|
import org.springframework.beans.factory.ListableBeanFactory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
|
|
@ -19,7 +19,7 @@ package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.springframework.beans.factory.ListableBeanFactory;
|
import org.springframework.beans.factory.ListableBeanFactory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
|
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
||||||
import javax.servlet.Filter;
|
import jakarta.servlet.Filter;
|
||||||
|
|
||||||
import org.apache.catalina.Valve;
|
import org.apache.catalina.Valve;
|
||||||
import org.apache.catalina.valves.AccessLogValve;
|
import org.apache.catalina.valves.AccessLogValve;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
||||||
|
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.autoconfigure.endpoint.web.WebEndpointProperties;
|
import org.springframework.boot.actuate.autoconfigure.endpoint.web.WebEndpointProperties;
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -19,7 +19,7 @@ package org.springframework.boot.actuate.autoconfigure.condition;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
|
||||||
import javax.annotation.PostConstruct;
|
import jakarta.annotation.PostConstruct;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -20,10 +20,10 @@ import java.io.IOException;
|
||||||
import java.time.Duration;
|
import java.time.Duration;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServlet;
|
import jakarta.servlet.http.HttpServlet;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.integrationtest;
|
||||||
|
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServlet;
|
import jakarta.servlet.http.HttpServlet;
|
||||||
|
|
||||||
import org.junit.jupiter.api.AfterEach;
|
import org.junit.jupiter.api.AfterEach;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.autoconfigure.jms;
|
package org.springframework.boot.actuate.autoconfigure.jms;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -18,10 +18,10 @@ package org.springframework.boot.actuate.autoconfigure.metrics.data.city;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
|
||||||
import javax.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import javax.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import javax.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import javax.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
public class City implements Serializable {
|
public class City implements Serializable {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,19 +16,18 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.autoconfigure.metrics.export.prometheus;
|
package org.springframework.boot.actuate.autoconfigure.metrics.export.prometheus;
|
||||||
|
|
||||||
import java.util.function.Consumer;
|
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Clock;
|
import io.micrometer.core.instrument.Clock;
|
||||||
import io.micrometer.prometheus.PrometheusConfig;
|
import io.micrometer.prometheus.PrometheusConfig;
|
||||||
import io.micrometer.prometheus.PrometheusMeterRegistry;
|
import io.micrometer.prometheus.PrometheusMeterRegistry;
|
||||||
import io.prometheus.client.CollectorRegistry;
|
import io.prometheus.client.CollectorRegistry;
|
||||||
import io.prometheus.client.exporter.BasicAuthHttpConnectionFactory;
|
|
||||||
import io.prometheus.client.exporter.DefaultHttpConnectionFactory;
|
import io.prometheus.client.exporter.DefaultHttpConnectionFactory;
|
||||||
import io.prometheus.client.exporter.HttpConnectionFactory;
|
import io.prometheus.client.exporter.HttpConnectionFactory;
|
||||||
import io.prometheus.client.exporter.PushGateway;
|
import io.prometheus.client.exporter.PushGateway;
|
||||||
|
import org.assertj.core.api.ThrowingConsumer;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.jupiter.api.extension.ExtendWith;
|
import org.junit.jupiter.api.extension.ExtendWith;
|
||||||
|
|
||||||
|
import org.springframework.boot.actuate.autoconfigure.metrics.export.prometheus.PrometheusMetricsExportAutoConfiguration.BasicAuthHttpConnectionFactory;
|
||||||
import org.springframework.boot.actuate.autoconfigure.web.server.ManagementContextAutoConfiguration;
|
import org.springframework.boot.actuate.autoconfigure.web.server.ManagementContextAutoConfiguration;
|
||||||
import org.springframework.boot.actuate.metrics.export.prometheus.PrometheusPushGatewayManager;
|
import org.springframework.boot.actuate.metrics.export.prometheus.PrometheusPushGatewayManager;
|
||||||
import org.springframework.boot.actuate.metrics.export.prometheus.PrometheusScrapeEndpoint;
|
import org.springframework.boot.actuate.metrics.export.prometheus.PrometheusScrapeEndpoint;
|
||||||
|
@ -193,8 +192,11 @@ class PrometheusMetricsExportAutoConfigurationTests {
|
||||||
"management.metrics.export.prometheus.pushgateway.username=admin",
|
"management.metrics.export.prometheus.pushgateway.username=admin",
|
||||||
"management.metrics.export.prometheus.pushgateway.password=secret")
|
"management.metrics.export.prometheus.pushgateway.password=secret")
|
||||||
.withUserConfiguration(BaseConfiguration.class)
|
.withUserConfiguration(BaseConfiguration.class)
|
||||||
.run(hasHttpConnectionFactory((httpConnectionFactory) -> assertThat(httpConnectionFactory)
|
.run(hasHttpConnectionFactory((httpConnectionFactory) -> {
|
||||||
.isInstanceOf(BasicAuthHttpConnectionFactory.class)));
|
assertThat(httpConnectionFactory).isInstanceOf(BasicAuthHttpConnectionFactory.class);
|
||||||
|
assertThat(((BasicAuthHttpConnectionFactory) httpConnectionFactory).getAuthorizationHeader())
|
||||||
|
.isEqualTo("Basic YWRtaW46c2VjcmV0");
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
private void hasGatewayURL(AssertableApplicationContext context, String url) {
|
private void hasGatewayURL(AssertableApplicationContext context, String url) {
|
||||||
|
@ -202,7 +204,7 @@ class PrometheusMetricsExportAutoConfigurationTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
private ContextConsumer<AssertableApplicationContext> hasHttpConnectionFactory(
|
private ContextConsumer<AssertableApplicationContext> hasHttpConnectionFactory(
|
||||||
Consumer<HttpConnectionFactory> httpConnectionFactory) {
|
ThrowingConsumer<HttpConnectionFactory> httpConnectionFactory) {
|
||||||
return (context) -> {
|
return (context) -> {
|
||||||
PushGateway pushGateway = getPushGateway(context);
|
PushGateway pushGateway = getPushGateway(context);
|
||||||
httpConnectionFactory
|
httpConnectionFactory
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -22,7 +22,7 @@ import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.concurrent.CyclicBarrier;
|
import java.util.concurrent.CyclicBarrier;
|
||||||
|
|
||||||
import javax.servlet.DispatcherType;
|
import jakarta.servlet.DispatcherType;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.MeterRegistry;
|
import io.micrometer.core.instrument.MeterRegistry;
|
||||||
import io.micrometer.core.instrument.MockClock;
|
import io.micrometer.core.instrument.MockClock;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,10 +20,10 @@ import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.EnumSet;
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import javax.servlet.DispatcherType;
|
import jakarta.servlet.DispatcherType;
|
||||||
import javax.servlet.Filter;
|
import jakarta.servlet.Filter;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Meter;
|
import io.micrometer.core.instrument.Meter;
|
||||||
import io.micrometer.core.instrument.MeterRegistry;
|
import io.micrometer.core.instrument.MeterRegistry;
|
||||||
|
|
|
@ -21,10 +21,10 @@ import java.time.Duration;
|
||||||
import java.util.Base64;
|
import java.util.Base64;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServlet;
|
import jakarta.servlet.http.HttpServlet;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -19,7 +19,7 @@ package org.springframework.boot.actuate.autoconfigure.security.servlet;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.assertj.core.api.AssertDelegateTarget;
|
import org.assertj.core.api.AssertDelegateTarget;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
|
@ -161,7 +161,7 @@ class ManagementWebSecurityAutoConfigurationTests {
|
||||||
}
|
}
|
||||||
|
|
||||||
private HttpStatus getResponseStatus(AssertableWebApplicationContext context, String path)
|
private HttpStatus getResponseStatus(AssertableWebApplicationContext context, String path)
|
||||||
throws IOException, javax.servlet.ServletException {
|
throws IOException, jakarta.servlet.ServletException {
|
||||||
FilterChainProxy filterChainProxy = context.getBean(FilterChainProxy.class);
|
FilterChainProxy filterChainProxy = context.getBean(FilterChainProxy.class);
|
||||||
MockServletContext servletContext = new MockServletContext();
|
MockServletContext servletContext = new MockServletContext();
|
||||||
MockHttpServletResponse response = new MockHttpServletResponse();
|
MockHttpServletResponse response = new MockHttpServletResponse();
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,7 @@ class ManagementErrorEndpointTests {
|
||||||
|
|
||||||
@BeforeEach
|
@BeforeEach
|
||||||
void setUp() {
|
void setUp() {
|
||||||
this.request.setAttribute("javax.servlet.error.exception", new RuntimeException("test exception"));
|
this.request.setAttribute("jakarta.servlet.error.exception", new RuntimeException("test exception"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.autoconfigure.web.servlet;
|
||||||
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
|
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
|
|
||||||
import org.springframework.boot.testsupport.web.servlet.MockServletWebServer.RegisteredFilter;
|
import org.springframework.boot.testsupport.web.servlet.MockServletWebServer.RegisteredFilter;
|
||||||
import org.springframework.boot.testsupport.web.servlet.MockServletWebServer.RegisteredServlet;
|
import org.springframework.boot.testsupport.web.servlet.MockServletWebServer.RegisteredServlet;
|
||||||
|
|
|
@ -21,8 +21,8 @@ import java.util.Map;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.Consumer;
|
||||||
import java.util.function.Function;
|
import java.util.function.Function;
|
||||||
|
|
||||||
import javax.validation.Valid;
|
import jakarta.validation.Valid;
|
||||||
import javax.validation.constraints.NotEmpty;
|
import jakarta.validation.constraints.NotEmpty;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import reactor.core.publisher.Mono;
|
import reactor.core.publisher.Mono;
|
||||||
|
|
|
@ -20,8 +20,8 @@
|
||||||
2017-08-08 17:12:32.084 INFO 19866 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
|
2017-08-08 17:12:32.084 INFO 19866 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'httpPutFormContentFilter' to: [/*]
|
||||||
2017-08-08 17:12:32.084 INFO 19866 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
|
2017-08-08 17:12:32.084 INFO 19866 --- [ost-startStop-1] o.s.b.w.servlet.FilterRegistrationBean : Mapping filter: 'requestContextFilter' to: [/*]
|
||||||
2017-08-08 17:12:32.349 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@76b10754: startup date [Tue Aug 08 17:12:30 BST 2017]; root of context hierarchy
|
2017-08-08 17:12:32.349 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerAdapter : Looking for @ControllerAdvice: org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext@76b10754: startup date [Tue Aug 08 17:12:30 BST 2017]; root of context hierarchy
|
||||||
2017-08-08 17:12:32.420 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.error(javax.servlet.http.HttpServletRequest)
|
2017-08-08 17:12:32.420 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error]}" onto public org.springframework.http.ResponseEntity<java.util.Map<java.lang.String, java.lang.Object>> org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.error(jakarta.servlet.http.HttpServletRequest)
|
||||||
2017-08-08 17:12:32.421 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.errorHtml(javax.servlet.http.HttpServletRequest,javax.servlet.http.HttpServletResponse)
|
2017-08-08 17:12:32.421 INFO 19866 --- [ main] s.w.s.m.m.a.RequestMappingHandlerMapping : Mapped "{[/error],produces=[text/html]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.boot.autoconfigure.web.servlet.error.BasicErrorController.errorHtml(jakarta.servlet.http.HttpServletRequest,jakarta.servlet.http.HttpServletResponse)
|
||||||
2017-08-08 17:12:32.444 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
2017-08-08 17:12:32.444 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/webjars/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
||||||
2017-08-08 17:12:32.444 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
2017-08-08 17:12:32.444 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
||||||
2017-08-08 17:12:32.471 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
2017-08-08 17:12:32.471 INFO 19866 --- [ main] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapped URL path [/**/favicon.ico] onto handler of type [class org.springframework.web.servlet.resource.ResourceHttpRequestHandler]
|
||||||
|
|
|
@ -31,12 +31,8 @@ dependencies {
|
||||||
optional("io.r2dbc:r2dbc-pool")
|
optional("io.r2dbc:r2dbc-pool")
|
||||||
optional("io.r2dbc:r2dbc-spi")
|
optional("io.r2dbc:r2dbc-spi")
|
||||||
optional("io.reactivex:rxjava-reactive-streams")
|
optional("io.reactivex:rxjava-reactive-streams")
|
||||||
optional("org.elasticsearch.client:elasticsearch-rest-client") {
|
optional("io.undertow:undertow-servlet-jakartaee9") {
|
||||||
exclude(group: "commons-logging", module: "commons-logging")
|
|
||||||
}
|
|
||||||
optional("io.undertow:undertow-servlet") {
|
|
||||||
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
||||||
exclude group: "org.jboss.spec.javax.servlet", module: "jboss-servlet-api_4.0_spec"
|
|
||||||
}
|
}
|
||||||
optional("javax.cache:cache-api")
|
optional("javax.cache:cache-api")
|
||||||
optional("jakarta.jms:jakarta.jms-api")
|
optional("jakarta.jms:jakarta.jms-api")
|
||||||
|
@ -49,6 +45,12 @@ dependencies {
|
||||||
exclude(group: "javax.servlet", module: "javax.servlet-api")
|
exclude(group: "javax.servlet", module: "javax.servlet-api")
|
||||||
}
|
}
|
||||||
optional("org.elasticsearch:elasticsearch")
|
optional("org.elasticsearch:elasticsearch")
|
||||||
|
optional("org.elasticsearch.client:elasticsearch-rest-client") {
|
||||||
|
exclude(group: "commons-logging", module: "commons-logging")
|
||||||
|
}
|
||||||
|
optional("org.elasticsearch.client:elasticsearch-rest-high-level-client") {
|
||||||
|
exclude(group: "commons-logging", module: "commons-logging")
|
||||||
|
}
|
||||||
optional("org.flywaydb:flyway-core")
|
optional("org.flywaydb:flyway-core")
|
||||||
optional("org.hibernate.validator:hibernate-validator")
|
optional("org.hibernate.validator:hibernate-validator")
|
||||||
optional("org.influxdb:influxdb-java")
|
optional("org.influxdb:influxdb-java")
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -25,7 +25,7 @@ import org.springframework.boot.actuate.health.Health;
|
||||||
import org.springframework.boot.actuate.health.HealthIndicator;
|
import org.springframework.boot.actuate.health.HealthIndicator;
|
||||||
import org.springframework.boot.actuate.health.Status;
|
import org.springframework.boot.actuate.health.Status;
|
||||||
import org.springframework.core.ParameterizedTypeReference;
|
import org.springframework.core.ParameterizedTypeReference;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
import org.springframework.web.reactive.function.client.ClientResponse;
|
import org.springframework.web.reactive.function.client.ClientResponse;
|
||||||
import org.springframework.web.reactive.function.client.WebClient;
|
import org.springframework.web.reactive.function.client.WebClient;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,8 +20,8 @@ import java.util.Collections;
|
||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
import javax.servlet.ServletRegistration.Dynamic;
|
import jakarta.servlet.ServletRegistration.Dynamic;
|
||||||
|
|
||||||
import org.springframework.beans.BeanUtils;
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.util.Assert;
|
import org.springframework.util.Assert;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,9 +18,9 @@ package org.springframework.boot.actuate.endpoint.web;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.ServletRegistration.Dynamic;
|
import jakarta.servlet.ServletRegistration.Dynamic;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
|
@ -26,8 +26,8 @@ import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.beans.factory.InitializingBean;
|
import org.springframework.beans.factory.InitializingBean;
|
||||||
import org.springframework.boot.actuate.endpoint.InvalidEndpointRequestException;
|
import org.springframework.boot.actuate.endpoint.InvalidEndpointRequestException;
|
||||||
|
@ -333,7 +333,7 @@ public abstract class AbstractWebMvcEndpointHandlerMapping extends RequestMappin
|
||||||
});
|
});
|
||||||
InvocationContext invocationContext = new InvocationContext(securityContext, arguments,
|
InvocationContext invocationContext = new InvocationContext(securityContext, arguments,
|
||||||
serverNamespaceArgumentResolver, producibleOperationArgumentResolver);
|
serverNamespaceArgumentResolver, producibleOperationArgumentResolver);
|
||||||
return handleResult(this.operation.invoke(invocationContext), HttpMethod.resolve(request.getMethod()));
|
return handleResult(this.operation.invoke(invocationContext), HttpMethod.valueOf(request.getMethod()));
|
||||||
}
|
}
|
||||||
catch (InvalidEndpointRequestException ex) {
|
catch (InvalidEndpointRequestException ex) {
|
||||||
throw new InvalidEndpointBadRequestException(ex);
|
throw new InvalidEndpointBadRequestException(ex);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.endpoint.web.servlet;
|
package org.springframework.boot.actuate.endpoint.web.servlet;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.web.servlet.HandlerInterceptor;
|
import org.springframework.web.servlet.HandlerInterceptor;
|
||||||
|
|
||||||
|
|
|
@ -20,8 +20,8 @@ import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.endpoint.web.EndpointLinksResolver;
|
import org.springframework.boot.actuate.endpoint.web.EndpointLinksResolver;
|
||||||
import org.springframework.boot.actuate.endpoint.web.EndpointMapping;
|
import org.springframework.boot.actuate.endpoint.web.EndpointMapping;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -19,9 +19,9 @@ package org.springframework.boot.actuate.jms;
|
||||||
import java.util.concurrent.CountDownLatch;
|
import java.util.concurrent.CountDownLatch;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
import javax.jms.Connection;
|
import jakarta.jms.Connection;
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
import javax.jms.JMSException;
|
import jakarta.jms.JMSException;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
|
@ -70,7 +70,7 @@ public final class WebFluxTags {
|
||||||
* @return the method tag whose value is a capitalized method (e.g. GET).
|
* @return the method tag whose value is a capitalized method (e.g. GET).
|
||||||
*/
|
*/
|
||||||
public static Tag method(ServerWebExchange exchange) {
|
public static Tag method(ServerWebExchange exchange) {
|
||||||
return Tag.of("method", exchange.getRequest().getMethodValue());
|
return Tag.of("method", exchange.getRequest().getMethod().name());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -19,8 +19,8 @@ package org.springframework.boot.actuate.metrics.web.servlet;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
import io.micrometer.core.instrument.Tags;
|
import io.micrometer.core.instrument.Tags;
|
||||||
|
|
|
@ -23,8 +23,8 @@ import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.annotation.Timed;
|
import io.micrometer.core.annotation.Timed;
|
||||||
import io.micrometer.core.instrument.LongTaskTimer;
|
import io.micrometer.core.instrument.LongTaskTimer;
|
||||||
|
|
|
@ -20,10 +20,10 @@ import java.io.IOException;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import javax.servlet.FilterChain;
|
import jakarta.servlet.FilterChain;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.annotation.Timed;
|
import io.micrometer.core.annotation.Timed;
|
||||||
import io.micrometer.core.instrument.MeterRegistry;
|
import io.micrometer.core.instrument.MeterRegistry;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,8 +18,8 @@ package org.springframework.boot.actuate.metrics.web.servlet;
|
||||||
|
|
||||||
import java.util.regex.Pattern;
|
import java.util.regex.Pattern;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.metrics.web.servlet;
|
package org.springframework.boot.actuate.metrics.web.servlet;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.LongTaskTimer;
|
import io.micrometer.core.instrument.LongTaskTimer;
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.metrics.web.servlet;
|
package org.springframework.boot.actuate.metrics.web.servlet;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.LongTaskTimer;
|
import io.micrometer.core.instrument.LongTaskTimer;
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -21,7 +21,7 @@ import java.util.List;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
import java.util.stream.Stream;
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
|
|
||||||
import org.apache.catalina.Container;
|
import org.apache.catalina.Container;
|
||||||
import org.apache.catalina.Context;
|
import org.apache.catalina.Context;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -26,7 +26,7 @@ import java.util.Map.Entry;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
import java.util.stream.Stream;
|
import java.util.stream.Stream;
|
||||||
|
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.web.mappings.HandlerMethodDescription;
|
import org.springframework.boot.actuate.web.mappings.HandlerMethodDescription;
|
||||||
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.web.mappings.servlet;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
|
||||||
import javax.servlet.FilterRegistration;
|
import jakarta.servlet.FilterRegistration;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A {@link RegistrationMappingDescription} derived from a {@link FilterRegistration}.
|
* A {@link RegistrationMappingDescription} derived from a {@link FilterRegistration}.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,8 +20,8 @@ import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import javax.servlet.Filter;
|
import jakarta.servlet.Filter;
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
||||||
import org.springframework.context.ApplicationContext;
|
import org.springframework.context.ApplicationContext;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.web.mappings.servlet;
|
package org.springframework.boot.actuate.web.mappings.servlet;
|
||||||
|
|
||||||
import javax.servlet.Registration;
|
import jakarta.servlet.Registration;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A mapping description derived from a {@link Registration}.
|
* A mapping description derived from a {@link Registration}.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,7 +18,7 @@ package org.springframework.boot.actuate.web.mappings.servlet;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
|
||||||
import javax.servlet.ServletRegistration;
|
import jakarta.servlet.ServletRegistration;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A mapping description derived from a {@link ServletRegistration}.
|
* A mapping description derived from a {@link ServletRegistration}.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,8 +20,8 @@ import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
import org.springframework.boot.actuate.web.mappings.MappingDescriptionProvider;
|
||||||
import org.springframework.context.ApplicationContext;
|
import org.springframework.context.ApplicationContext;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -44,7 +44,7 @@ class ServerWebExchangeTraceableRequest implements TraceableRequest {
|
||||||
|
|
||||||
ServerWebExchangeTraceableRequest(ServerWebExchange exchange) {
|
ServerWebExchangeTraceableRequest(ServerWebExchange exchange) {
|
||||||
ServerHttpRequest request = exchange.getRequest();
|
ServerHttpRequest request = exchange.getRequest();
|
||||||
this.method = request.getMethodValue();
|
this.method = request.getMethod().name();
|
||||||
this.headers = request.getHeaders();
|
this.headers = request.getHeaders();
|
||||||
this.uri = request.getURI();
|
this.uri = request.getURI();
|
||||||
this.remoteAddress = getRemoteAddress(request);
|
this.remoteAddress = getRemoteAddress(request);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,13 +20,13 @@ import java.io.IOException;
|
||||||
import java.net.URI;
|
import java.net.URI;
|
||||||
import java.net.URISyntaxException;
|
import java.net.URISyntaxException;
|
||||||
|
|
||||||
import javax.servlet.Filter;
|
import jakarta.servlet.Filter;
|
||||||
import javax.servlet.FilterChain;
|
import jakarta.servlet.FilterChain;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
import javax.servlet.http.HttpServletResponseWrapper;
|
import jakarta.servlet.http.HttpServletResponseWrapper;
|
||||||
import javax.servlet.http.HttpSession;
|
import jakarta.servlet.http.HttpSession;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.trace.http.HttpExchangeTracer;
|
import org.springframework.boot.actuate.trace.http.HttpExchangeTracer;
|
||||||
import org.springframework.boot.actuate.trace.http.HttpTrace;
|
import org.springframework.boot.actuate.trace.http.HttpTrace;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -25,7 +25,7 @@ import java.util.LinkedHashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.trace.http.TraceableRequest;
|
import org.springframework.boot.actuate.trace.http.TraceableRequest;
|
||||||
import org.springframework.util.StringUtils;
|
import org.springframework.util.StringUtils;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -21,7 +21,7 @@ import java.util.LinkedHashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.trace.http.TraceableResponse;
|
import org.springframework.boot.actuate.trace.http.TraceableResponse;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -26,9 +26,9 @@ import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
import org.springframework.boot.actuate.health.Health;
|
import org.springframework.boot.actuate.health.Health;
|
||||||
import org.springframework.boot.actuate.health.Status;
|
import org.springframework.boot.actuate.health.Status;
|
||||||
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.DefaultReactiveElasticsearchClient;
|
||||||
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
import org.springframework.data.elasticsearch.client.ClientConfiguration;
|
import org.springframework.data.elasticsearch.client.ClientConfiguration;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.DefaultReactiveElasticsearchClient;
|
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
|
||||||
import org.springframework.http.HttpHeaders;
|
import org.springframework.http.HttpHeaders;
|
||||||
import org.springframework.http.HttpStatus;
|
import org.springframework.http.HttpStatus;
|
||||||
import org.springframework.http.MediaType;
|
import org.springframework.http.MediaType;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -20,10 +20,10 @@ import java.util.Collections;
|
||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.servlet.GenericServlet;
|
import jakarta.servlet.GenericServlet;
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
import javax.servlet.ServletRequest;
|
import jakarta.servlet.ServletRequest;
|
||||||
import javax.servlet.ServletResponse;
|
import jakarta.servlet.ServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,13 +18,13 @@ package org.springframework.boot.actuate.endpoint.web;
|
||||||
|
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
|
||||||
import javax.servlet.GenericServlet;
|
import jakarta.servlet.GenericServlet;
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.ServletRegistration.Dynamic;
|
import jakarta.servlet.ServletRegistration.Dynamic;
|
||||||
import javax.servlet.ServletRequest;
|
import jakarta.servlet.ServletRequest;
|
||||||
import javax.servlet.ServletResponse;
|
import jakarta.servlet.ServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.jupiter.api.extension.ExtendWith;
|
import org.junit.jupiter.api.extension.ExtendWith;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -24,10 +24,10 @@ import java.util.function.Consumer;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
import javax.servlet.GenericServlet;
|
import jakarta.servlet.GenericServlet;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.ServletRequest;
|
import jakarta.servlet.ServletRequest;
|
||||||
import javax.servlet.ServletResponse;
|
import jakarta.servlet.ServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -23,8 +23,8 @@ import java.util.function.Function;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
import java.util.stream.StreamSupport;
|
import java.util.stream.StreamSupport;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
|
@ -19,11 +19,11 @@ package org.springframework.boot.actuate.endpoint.web.servlet;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
|
|
||||||
import javax.servlet.Filter;
|
import jakarta.servlet.Filter;
|
||||||
import javax.servlet.FilterChain;
|
import jakarta.servlet.FilterChain;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,10 +16,10 @@
|
||||||
|
|
||||||
package org.springframework.boot.actuate.jms;
|
package org.springframework.boot.actuate.jms;
|
||||||
|
|
||||||
import javax.jms.Connection;
|
import jakarta.jms.Connection;
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
import javax.jms.ConnectionMetaData;
|
import jakarta.jms.ConnectionMetaData;
|
||||||
import javax.jms.JMSException;
|
import jakarta.jms.JMSException;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.mockito.invocation.InvocationOnMock;
|
import org.mockito.invocation.InvocationOnMock;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,14 +18,14 @@ package org.springframework.boot.actuate.mail;
|
||||||
|
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
|
||||||
import javax.mail.Address;
|
import jakarta.mail.Address;
|
||||||
import javax.mail.Message;
|
import jakarta.mail.Message;
|
||||||
import javax.mail.MessagingException;
|
import jakarta.mail.MessagingException;
|
||||||
import javax.mail.Provider;
|
import jakarta.mail.Provider;
|
||||||
import javax.mail.Provider.Type;
|
import jakarta.mail.Provider.Type;
|
||||||
import javax.mail.Session;
|
import jakarta.mail.Session;
|
||||||
import javax.mail.Transport;
|
import jakarta.mail.Transport;
|
||||||
import javax.mail.URLName;
|
import jakarta.mail.URLName;
|
||||||
|
|
||||||
import org.junit.jupiter.api.BeforeEach;
|
import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
|
@ -22,6 +22,7 @@ import io.micrometer.core.instrument.Tag;
|
||||||
import org.junit.jupiter.api.BeforeEach;
|
import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
import org.springframework.http.HttpMethod;
|
||||||
import org.springframework.http.HttpStatus;
|
import org.springframework.http.HttpStatus;
|
||||||
import org.springframework.http.server.reactive.ServerHttpRequest;
|
import org.springframework.http.server.reactive.ServerHttpRequest;
|
||||||
import org.springframework.http.server.reactive.ServerHttpResponse;
|
import org.springframework.http.server.reactive.ServerHttpResponse;
|
||||||
|
@ -134,7 +135,7 @@ class WebFluxTagsTests {
|
||||||
ServerWebExchange exchange = mock(ServerWebExchange.class);
|
ServerWebExchange exchange = mock(ServerWebExchange.class);
|
||||||
ServerHttpRequest request = mock(ServerHttpRequest.class);
|
ServerHttpRequest request = mock(ServerHttpRequest.class);
|
||||||
given(exchange.getRequest()).willReturn(request);
|
given(exchange.getRequest()).willReturn(request);
|
||||||
given(request.getMethodValue()).willReturn("CUSTOM");
|
given(request.getMethod()).willReturn(HttpMethod.valueOf("CUSTOM"));
|
||||||
Tag tag = WebFluxTags.method(exchange);
|
Tag tag = WebFluxTags.method(exchange);
|
||||||
assertThat(tag.getValue()).isEqualTo("CUSTOM");
|
assertThat(tag.getValue()).isEqualTo("CUSTOM");
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,8 +18,8 @@ package org.springframework.boot.actuate.metrics.web.servlet;
|
||||||
|
|
||||||
import java.util.concurrent.atomic.AtomicBoolean;
|
import java.util.concurrent.atomic.AtomicBoolean;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.instrument.Tag;
|
import io.micrometer.core.instrument.Tag;
|
||||||
|
|
||||||
|
|
|
@ -30,10 +30,10 @@ import java.util.concurrent.CyclicBarrier;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
import java.util.concurrent.atomic.AtomicReference;
|
import java.util.concurrent.atomic.AtomicReference;
|
||||||
|
|
||||||
import javax.servlet.FilterChain;
|
import jakarta.servlet.FilterChain;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import io.micrometer.core.annotation.Timed;
|
import io.micrometer.core.annotation.Timed;
|
||||||
import io.micrometer.core.instrument.Clock;
|
import io.micrometer.core.instrument.Clock;
|
||||||
|
|
|
@ -20,10 +20,10 @@ import java.io.IOException;
|
||||||
import java.security.Principal;
|
import java.security.Principal;
|
||||||
import java.util.EnumSet;
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.http.HttpServlet;
|
import jakarta.servlet.http.HttpServlet;
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import jakarta.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -22,10 +22,10 @@ import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.function.Supplier;
|
import java.util.function.Supplier;
|
||||||
|
|
||||||
import javax.servlet.FilterRegistration;
|
import jakarta.servlet.FilterRegistration;
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
import javax.servlet.ServletException;
|
import jakarta.servlet.ServletException;
|
||||||
import javax.servlet.ServletRegistration;
|
import jakarta.servlet.ServletRegistration;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -24,6 +24,7 @@ import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
|
|
||||||
import org.springframework.http.HttpHeaders;
|
import org.springframework.http.HttpHeaders;
|
||||||
|
import org.springframework.http.HttpMethod;
|
||||||
import org.springframework.http.server.reactive.ServerHttpRequest;
|
import org.springframework.http.server.reactive.ServerHttpRequest;
|
||||||
import org.springframework.web.server.ServerWebExchange;
|
import org.springframework.web.server.ServerWebExchange;
|
||||||
|
|
||||||
|
@ -48,14 +49,13 @@ class ServerWebExchangeTraceableRequestTests {
|
||||||
this.exchange = mock(ServerWebExchange.class);
|
this.exchange = mock(ServerWebExchange.class);
|
||||||
this.request = mock(ServerHttpRequest.class);
|
this.request = mock(ServerHttpRequest.class);
|
||||||
given(this.exchange.getRequest()).willReturn(this.request);
|
given(this.exchange.getRequest()).willReturn(this.request);
|
||||||
|
given(this.request.getMethod()).willReturn(HttpMethod.GET);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void getMethod() {
|
void getMethod() {
|
||||||
String method = "POST";
|
|
||||||
given(this.request.getMethodValue()).willReturn(method);
|
|
||||||
ServerWebExchangeTraceableRequest traceableRequest = new ServerWebExchangeTraceableRequest(this.exchange);
|
ServerWebExchangeTraceableRequest traceableRequest = new ServerWebExchangeTraceableRequest(this.exchange);
|
||||||
assertThat(traceableRequest.getMethod()).isSameAs(method);
|
assertThat(traceableRequest.getMethod()).isEqualTo("GET");
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -34,14 +34,11 @@ dependencies {
|
||||||
optional("io.r2dbc:r2dbc-pool")
|
optional("io.r2dbc:r2dbc-pool")
|
||||||
optional("io.rsocket:rsocket-core")
|
optional("io.rsocket:rsocket-core")
|
||||||
optional("io.rsocket:rsocket-transport-netty")
|
optional("io.rsocket:rsocket-transport-netty")
|
||||||
optional("io.undertow:undertow-servlet") {
|
optional("io.undertow:undertow-servlet-jakartaee9") {
|
||||||
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
||||||
exclude group: "org.jboss.spec.javax.servlet", module: "jboss-servlet-api_4.0_spec"
|
|
||||||
}
|
}
|
||||||
optional("io.undertow:undertow-websockets-jsr") {
|
optional("io.undertow:undertow-websockets-jsr-jakartaee9") {
|
||||||
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
exclude group: "org.jboss.spec.javax.annotation", module: "jboss-annotations-api_1.3_spec"
|
||||||
exclude group: "org.jboss.spec.javax.servlet", module: "jboss-servlet-api_4.0_spec"
|
|
||||||
exclude group: "org.jboss.spec.javax.websocket", module: "jboss-websocket-api_1.1_spec"
|
|
||||||
}
|
}
|
||||||
optional("jakarta.jms:jakarta.jms-api")
|
optional("jakarta.jms:jakarta.jms-api")
|
||||||
optional("jakarta.mail:jakarta.mail-api")
|
optional("jakarta.mail:jakarta.mail-api")
|
||||||
|
@ -78,12 +75,11 @@ dependencies {
|
||||||
exclude(group: "org.eclipse.jetty", module: "jetty-jndi")
|
exclude(group: "org.eclipse.jetty", module: "jetty-jndi")
|
||||||
}
|
}
|
||||||
optional("org.eclipse.jetty:jetty-reactive-httpclient")
|
optional("org.eclipse.jetty:jetty-reactive-httpclient")
|
||||||
optional("org.eclipse.jetty.websocket:javax-websocket-server-impl") {
|
optional("org.eclipse.jetty.websocket:websocket-jakarta-server") {
|
||||||
exclude group: "javax.annotation", module: "javax.annotation-api"
|
exclude(group: "org.eclipse.jetty", module: "jetty-jndi")
|
||||||
exclude group: "javax.servlet", module: "javax.servlet-api"
|
}
|
||||||
exclude group: "javax.websocket", module: "javax.websocket-api"
|
optional("org.eclipse.jetty.websocket:websocket-jetty-server") {
|
||||||
exclude group: "javax.websocket", module: "javax.websocket-client-api"
|
exclude(group: "org.eclipse.jetty", module: "jetty-jndi")
|
||||||
exclude group: "org.eclipse.jetty", module: "jetty-jndi"
|
|
||||||
}
|
}
|
||||||
optional("org.elasticsearch.client:elasticsearch-rest-client") {
|
optional("org.elasticsearch.client:elasticsearch-rest-client") {
|
||||||
exclude group: "commons-logging", module: "commons-logging"
|
exclude group: "commons-logging", module: "commons-logging"
|
||||||
|
@ -96,17 +92,9 @@ dependencies {
|
||||||
}
|
}
|
||||||
optional("org.flywaydb:flyway-core")
|
optional("org.flywaydb:flyway-core")
|
||||||
optional("org.freemarker:freemarker")
|
optional("org.freemarker:freemarker")
|
||||||
optional("org.hibernate:hibernate-core") {
|
optional("org.hibernate:hibernate-core-jakarta")
|
||||||
exclude group: "javax.activation", module: "javax.activation-api"
|
|
||||||
exclude group: "javax.persistence", module: "javax.persistence-api"
|
|
||||||
exclude group: "javax.xml.bind", module: "jaxb-api"
|
|
||||||
exclude group: "org.jboss.spec.javax.transaction", module: "jboss-transaction-api_1.2_spec"
|
|
||||||
}
|
|
||||||
optional("org.hibernate:hibernate-jcache") {
|
optional("org.hibernate:hibernate-jcache") {
|
||||||
exclude group: "javax.activation", module: "javax.activation-api"
|
exclude group: "org.hibernate", module: "hibernate-core"
|
||||||
exclude group: "javax.persistence", module: "javax.persistence-api"
|
|
||||||
exclude group: "javax.xml.bind", module: "jaxb-api"
|
|
||||||
exclude group: "org.jboss.spec.javax.transaction", module: "jboss-transaction-api_1.2_spec"
|
|
||||||
}
|
}
|
||||||
optional("org.hibernate.validator:hibernate-validator")
|
optional("org.hibernate.validator:hibernate-validator")
|
||||||
optional("org.influxdb:influxdb-java")
|
optional("org.influxdb:influxdb-java")
|
||||||
|
@ -164,21 +152,24 @@ dependencies {
|
||||||
optional("org.springframework.session:spring-session-core")
|
optional("org.springframework.session:spring-session-core")
|
||||||
optional("org.springframework.session:spring-session-data-mongodb")
|
optional("org.springframework.session:spring-session-data-mongodb")
|
||||||
optional("org.springframework.session:spring-session-data-redis")
|
optional("org.springframework.session:spring-session-data-redis")
|
||||||
optional("org.springframework.session:spring-session-hazelcast") {
|
optional("org.springframework.session:spring-session-hazelcast")
|
||||||
exclude group: "javax.annotation", module: "javax.annotation-api"
|
|
||||||
}
|
|
||||||
optional("org.springframework.session:spring-session-jdbc")
|
optional("org.springframework.session:spring-session-jdbc")
|
||||||
optional("org.springframework.amqp:spring-rabbit")
|
optional("org.springframework.amqp:spring-rabbit")
|
||||||
optional("org.springframework.amqp:spring-rabbit-stream")
|
optional("org.springframework.amqp:spring-rabbit-stream")
|
||||||
optional("org.springframework.kafka:spring-kafka")
|
optional("org.springframework.kafka:spring-kafka")
|
||||||
optional("org.springframework.ws:spring-ws-core")
|
optional("org.springframework.ws:spring-ws-core") {
|
||||||
|
exclude group: "com.sun.mail", module: "jakarta.mail"
|
||||||
|
exclude group: "jakarta.platform", module: "jakarta.jakartaee-api"
|
||||||
|
exclude group: "org.eclipse.jetty", module: "jetty-server"
|
||||||
|
exclude group: "org.eclipse.jetty", module: "jetty-servlet"
|
||||||
|
exclude group: "jakarta.mail", module: "jakarta.mail-api"
|
||||||
|
}
|
||||||
optional("redis.clients:jedis")
|
optional("redis.clients:jedis")
|
||||||
|
|
||||||
testImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
|
testImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
|
||||||
testImplementation(project(":spring-boot-project:spring-boot-test"))
|
testImplementation(project(":spring-boot-project:spring-boot-test"))
|
||||||
testImplementation("ch.qos.logback:logback-classic")
|
testImplementation("ch.qos.logback:logback-classic")
|
||||||
testImplementation("commons-fileupload:commons-fileupload")
|
testImplementation("commons-fileupload:commons-fileupload")
|
||||||
testImplementation("com.atomikos:transactions-jms")
|
|
||||||
testImplementation("com.github.h-thurow:simple-jndi")
|
testImplementation("com.github.h-thurow:simple-jndi")
|
||||||
testImplementation("com.ibm.db2:jcc")
|
testImplementation("com.ibm.db2:jcc")
|
||||||
testImplementation("com.jayway.jsonpath:json-path")
|
testImplementation("com.jayway.jsonpath:json-path")
|
||||||
|
|
|
@ -20,8 +20,8 @@ import java.nio.charset.StandardCharsets;
|
||||||
import java.util.concurrent.CountDownLatch;
|
import java.util.concurrent.CountDownLatch;
|
||||||
import java.util.concurrent.atomic.AtomicBoolean;
|
import java.util.concurrent.atomic.AtomicBoolean;
|
||||||
|
|
||||||
import javax.validation.Configuration;
|
import jakarta.validation.Configuration;
|
||||||
import javax.validation.Validation;
|
import jakarta.validation.Validation;
|
||||||
|
|
||||||
import org.springframework.boot.context.event.ApplicationEnvironmentPreparedEvent;
|
import org.springframework.boot.context.event.ApplicationEnvironmentPreparedEvent;
|
||||||
import org.springframework.boot.context.event.ApplicationFailedEvent;
|
import org.springframework.boot.context.event.ApplicationFailedEvent;
|
||||||
|
@ -139,7 +139,7 @@ public class BackgroundPreinitializer implements ApplicationListener<SpringAppli
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Early initializer for javax.validation.
|
* Early initializer for jakarta.validation.
|
||||||
*/
|
*/
|
||||||
private static class ValidationInitializer implements Runnable {
|
private static class ValidationInitializer implements Runnable {
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,9 +16,10 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.batch;
|
package org.springframework.boot.autoconfigure.batch;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
|
||||||
import javax.sql.DataSource;
|
import javax.sql.DataSource;
|
||||||
|
|
||||||
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import org.springframework.batch.core.configuration.annotation.BatchConfigurer;
|
import org.springframework.batch.core.configuration.annotation.BatchConfigurer;
|
||||||
import org.springframework.beans.factory.ObjectProvider;
|
import org.springframework.beans.factory.ObjectProvider;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,9 +16,10 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.batch;
|
package org.springframework.boot.autoconfigure.batch;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
|
||||||
import javax.sql.DataSource;
|
import javax.sql.DataSource;
|
||||||
|
|
||||||
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.condition;
|
package org.springframework.boot.autoconfigure.condition;
|
||||||
|
|
||||||
import javax.servlet.ServletContext;
|
import jakarta.servlet.ServletContext;
|
||||||
|
|
||||||
import org.springframework.context.annotation.Condition;
|
import org.springframework.context.annotation.Condition;
|
||||||
import org.springframework.context.annotation.ConditionContext;
|
import org.springframework.context.annotation.ConditionContext;
|
||||||
|
|
|
@ -22,7 +22,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
||||||
import org.springframework.boot.autoconfigure.elasticsearch.ElasticsearchRestClientAutoConfiguration;
|
import org.springframework.boot.autoconfigure.elasticsearch.ElasticsearchRestClientAutoConfiguration;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.context.annotation.Import;
|
import org.springframework.context.annotation.Import;
|
||||||
import org.springframework.data.elasticsearch.core.ElasticsearchRestTemplate;
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.ElasticsearchRestTemplate;
|
||||||
import org.springframework.data.elasticsearch.repository.config.EnableElasticsearchRepositories;
|
import org.springframework.data.elasticsearch.repository.config.EnableElasticsearchRepositories;
|
||||||
import org.springframework.data.elasticsearch.repository.config.EnableReactiveElasticsearchRepositories;
|
import org.springframework.data.elasticsearch.repository.config.EnableReactiveElasticsearchRepositories;
|
||||||
|
|
||||||
|
|
|
@ -29,11 +29,11 @@ import org.springframework.context.ApplicationContext;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.data.elasticsearch.annotations.Document;
|
import org.springframework.data.elasticsearch.annotations.Document;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.ElasticsearchRestTemplate;
|
||||||
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.ReactiveElasticsearchTemplate;
|
||||||
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
import org.springframework.data.elasticsearch.core.ElasticsearchOperations;
|
import org.springframework.data.elasticsearch.core.ElasticsearchOperations;
|
||||||
import org.springframework.data.elasticsearch.core.ElasticsearchRestTemplate;
|
|
||||||
import org.springframework.data.elasticsearch.core.ReactiveElasticsearchOperations;
|
import org.springframework.data.elasticsearch.core.ReactiveElasticsearchOperations;
|
||||||
import org.springframework.data.elasticsearch.core.ReactiveElasticsearchTemplate;
|
|
||||||
import org.springframework.data.elasticsearch.core.RefreshPolicy;
|
import org.springframework.data.elasticsearch.core.RefreshPolicy;
|
||||||
import org.springframework.data.elasticsearch.core.convert.ElasticsearchConverter;
|
import org.springframework.data.elasticsearch.core.convert.ElasticsearchConverter;
|
||||||
import org.springframework.data.elasticsearch.core.convert.ElasticsearchCustomConversions;
|
import org.springframework.data.elasticsearch.core.convert.ElasticsearchCustomConversions;
|
||||||
|
|
|
@ -22,7 +22,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.context.annotation.Import;
|
import org.springframework.context.annotation.Import;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
import org.springframework.data.elasticsearch.repository.ReactiveElasticsearchRepository;
|
import org.springframework.data.elasticsearch.repository.ReactiveElasticsearchRepository;
|
||||||
import org.springframework.data.elasticsearch.repository.config.EnableReactiveElasticsearchRepositories;
|
import org.springframework.data.elasticsearch.repository.config.EnableReactiveElasticsearchRepositories;
|
||||||
import org.springframework.data.elasticsearch.repository.support.ReactiveElasticsearchRepositoryFactoryBean;
|
import org.springframework.data.elasticsearch.repository.support.ReactiveElasticsearchRepositoryFactoryBean;
|
||||||
|
|
|
@ -32,8 +32,8 @@ import org.springframework.boot.context.properties.EnableConfigurationProperties
|
||||||
import org.springframework.boot.context.properties.PropertyMapper;
|
import org.springframework.boot.context.properties.PropertyMapper;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
import org.springframework.data.elasticsearch.backend.elasticsearch7.client.reactive.ReactiveElasticsearchClient;
|
||||||
import org.springframework.data.elasticsearch.client.ClientConfiguration;
|
import org.springframework.data.elasticsearch.client.ClientConfiguration;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveElasticsearchClient;
|
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveRestClients;
|
import org.springframework.data.elasticsearch.client.reactive.ReactiveRestClients;
|
||||||
import org.springframework.data.elasticsearch.client.reactive.ReactiveRestClients.WebClientConfigurationCallback;
|
import org.springframework.data.elasticsearch.client.reactive.ReactiveRestClients.WebClientConfigurationCallback;
|
||||||
import org.springframework.util.Assert;
|
import org.springframework.util.Assert;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.data.jpa;
|
package org.springframework.boot.autoconfigure.data.jpa;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import org.springframework.beans.factory.config.BeanDefinition;
|
import org.springframework.beans.factory.config.BeanDefinition;
|
||||||
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.freemarker;
|
package org.springframework.boot.autoconfigure.freemarker;
|
||||||
|
|
||||||
import javax.servlet.DispatcherType;
|
import jakarta.servlet.DispatcherType;
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -19,7 +19,7 @@ package org.springframework.boot.autoconfigure.groovy.template;
|
||||||
import java.security.CodeSource;
|
import java.security.CodeSource;
|
||||||
import java.security.ProtectionDomain;
|
import java.security.ProtectionDomain;
|
||||||
|
|
||||||
import javax.servlet.Servlet;
|
import jakarta.servlet.Servlet;
|
||||||
|
|
||||||
import groovy.text.markup.MarkupTemplateEngine;
|
import groovy.text.markup.MarkupTemplateEngine;
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.hazelcast;
|
package org.springframework.boot.autoconfigure.hazelcast;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import com.hazelcast.core.HazelcastInstance;
|
import com.hazelcast.core.HazelcastInstance;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.http;
|
package org.springframework.boot.autoconfigure.http;
|
||||||
|
|
||||||
import javax.json.bind.Jsonb;
|
import jakarta.json.bind.Jsonb;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -21,7 +21,8 @@ import java.util.Map;
|
||||||
|
|
||||||
import javax.sql.DataSource;
|
import javax.sql.DataSource;
|
||||||
import javax.sql.XADataSource;
|
import javax.sql.XADataSource;
|
||||||
import javax.transaction.TransactionManager;
|
|
||||||
|
import jakarta.transaction.TransactionManager;
|
||||||
|
|
||||||
import org.springframework.beans.BeanUtils;
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.BeanClassLoaderAware;
|
import org.springframework.beans.factory.BeanClassLoaderAware;
|
||||||
|
|
|
@ -18,8 +18,8 @@ package org.springframework.boot.autoconfigure.jms;
|
||||||
|
|
||||||
import java.time.Duration;
|
import java.time.Duration;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
import javax.jms.ExceptionListener;
|
import jakarta.jms.ExceptionListener;
|
||||||
|
|
||||||
import org.springframework.jms.config.DefaultJmsListenerContainerFactory;
|
import org.springframework.jms.config.DefaultJmsListenerContainerFactory;
|
||||||
import org.springframework.jms.support.converter.MessageConverter;
|
import org.springframework.jms.support.converter.MessageConverter;
|
||||||
|
|
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.jms;
|
package org.springframework.boot.autoconfigure.jms;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
import javax.jms.ExceptionListener;
|
import jakarta.jms.ExceptionListener;
|
||||||
|
|
||||||
import org.springframework.beans.factory.ObjectProvider;
|
import org.springframework.beans.factory.ObjectProvider;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,8 +18,8 @@ package org.springframework.boot.autoconfigure.jms;
|
||||||
|
|
||||||
import java.time.Duration;
|
import java.time.Duration;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
import jakarta.jms.ConnectionFactory;
|
||||||
import javax.jms.Message;
|
import jakarta.jms.Message;
|
||||||
|
|
||||||
import org.springframework.beans.factory.ObjectProvider;
|
import org.springframework.beans.factory.ObjectProvider;
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -320,11 +320,11 @@ public class JmsProperties {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Translate the acknowledge modes defined on the {@link javax.jms.Session}.
|
* Translate the acknowledge modes defined on the {@link jakarta.jms.Session}.
|
||||||
*
|
*
|
||||||
* <p>
|
* <p>
|
||||||
* {@link javax.jms.Session#SESSION_TRANSACTED} is not defined as we take care of this
|
* {@link jakarta.jms.Session#SESSION_TRANSACTED} is not defined as we take care of
|
||||||
* already via a call to {@code setSessionTransacted}.
|
* this already via a call to {@code setSessionTransacted}.
|
||||||
*/
|
*/
|
||||||
public enum AcknowledgeMode {
|
public enum AcknowledgeMode {
|
||||||
|
|
||||||
|
@ -336,7 +336,7 @@ public class JmsProperties {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Messages are acknowledged once the message listener implementation has called
|
* Messages are acknowledged once the message listener implementation has called
|
||||||
* {@link javax.jms.Message#acknowledge()}. This mode gives the application
|
* {@link jakarta.jms.Message#acknowledge()}. This mode gives the application
|
||||||
* (rather than the JMS provider) complete control over message acknowledgement.
|
* (rather than the JMS provider) complete control over message acknowledgement.
|
||||||
*/
|
*/
|
||||||
CLIENT(2),
|
CLIENT(2),
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -18,9 +18,10 @@ package org.springframework.boot.autoconfigure.jms;
|
||||||
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
|
|
||||||
import javax.jms.ConnectionFactory;
|
|
||||||
import javax.naming.NamingException;
|
import javax.naming.NamingException;
|
||||||
|
|
||||||
|
import jakarta.jms.ConnectionFactory;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
|
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -27,7 +27,6 @@ import org.springframework.boot.autoconfigure.condition.SearchStrategy;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.context.annotation.EnableMBeanExport;
|
import org.springframework.context.annotation.EnableMBeanExport;
|
||||||
import org.springframework.context.annotation.MBeanExportConfiguration.SpecificPlatform;
|
|
||||||
import org.springframework.context.annotation.Primary;
|
import org.springframework.context.annotation.Primary;
|
||||||
import org.springframework.core.env.Environment;
|
import org.springframework.core.env.Environment;
|
||||||
import org.springframework.jmx.export.MBeanExporter;
|
import org.springframework.jmx.export.MBeanExporter;
|
||||||
|
@ -91,10 +90,6 @@ public class JmxAutoConfiguration {
|
||||||
@Bean
|
@Bean
|
||||||
@ConditionalOnMissingBean
|
@ConditionalOnMissingBean
|
||||||
public MBeanServer mbeanServer() {
|
public MBeanServer mbeanServer() {
|
||||||
SpecificPlatform platform = SpecificPlatform.get();
|
|
||||||
if (platform != null) {
|
|
||||||
return platform.getMBeanServer();
|
|
||||||
}
|
|
||||||
MBeanServerFactoryBean factory = new MBeanServerFactoryBean();
|
MBeanServerFactoryBean factory = new MBeanServerFactoryBean();
|
||||||
factory.setLocateExistingServerIfPossible(true);
|
factory.setLocateExistingServerIfPossible(true);
|
||||||
factory.afterPropertiesSet();
|
factory.afterPropertiesSet();
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.jsonb;
|
package org.springframework.boot.autoconfigure.jsonb;
|
||||||
|
|
||||||
import javax.json.bind.Jsonb;
|
import jakarta.json.bind.Jsonb;
|
||||||
import javax.json.bind.JsonbBuilder;
|
import jakarta.json.bind.JsonbBuilder;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
||||||
|
@ -34,8 +34,8 @@ import org.springframework.context.annotation.Configuration;
|
||||||
*/
|
*/
|
||||||
@Configuration(proxyBeanMethods = false)
|
@Configuration(proxyBeanMethods = false)
|
||||||
@ConditionalOnClass(Jsonb.class)
|
@ConditionalOnClass(Jsonb.class)
|
||||||
@ConditionalOnResource(resources = { "classpath:META-INF/services/javax.json.bind.spi.JsonbProvider",
|
@ConditionalOnResource(resources = { "classpath:META-INF/services/jakarta.json.bind.spi.JsonbProvider",
|
||||||
"classpath:META-INF/services/javax.json.spi.JsonProvider" })
|
"classpath:META-INF/services/jakarta.json.spi.JsonProvider" })
|
||||||
public class JsonbAutoConfiguration {
|
public class JsonbAutoConfiguration {
|
||||||
|
|
||||||
@Bean
|
@Bean
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -22,7 +22,7 @@ import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.annotation.PreDestroy;
|
import jakarta.annotation.PreDestroy;
|
||||||
|
|
||||||
import com.unboundid.ldap.listener.InMemoryDirectoryServer;
|
import com.unboundid.ldap.listener.InMemoryDirectoryServer;
|
||||||
import com.unboundid.ldap.listener.InMemoryDirectoryServerConfig;
|
import com.unboundid.ldap.listener.InMemoryDirectoryServerConfig;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.mail;
|
package org.springframework.boot.autoconfigure.mail;
|
||||||
|
|
||||||
import javax.activation.MimeType;
|
import jakarta.activation.MimeType;
|
||||||
import javax.mail.internet.MimeMessage;
|
import jakarta.mail.internet.MimeMessage;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
import org.springframework.boot.autoconfigure.condition.AnyNestedCondition;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2019 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,9 +16,10 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.mail;
|
package org.springframework.boot.autoconfigure.mail;
|
||||||
|
|
||||||
import javax.mail.Session;
|
|
||||||
import javax.naming.NamingException;
|
import javax.naming.NamingException;
|
||||||
|
|
||||||
|
import jakarta.mail.Session;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnJndi;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnJndi;
|
||||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.mail;
|
package org.springframework.boot.autoconfigure.mail;
|
||||||
|
|
||||||
import javax.mail.MessagingException;
|
import jakarta.mail.MessagingException;
|
||||||
|
|
||||||
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
|
||||||
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright 2012-2020 the original author or authors.
|
* Copyright 2012-2021 the original author or authors.
|
||||||
*
|
*
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
* you may not use this file except in compliance with the License.
|
* you may not use this file except in compliance with the License.
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.orm.jpa;
|
package org.springframework.boot.autoconfigure.orm.jpa;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import org.springframework.beans.factory.config.BeanDefinition;
|
import org.springframework.beans.factory.config.BeanDefinition;
|
||||||
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
package org.springframework.boot.autoconfigure.orm.jpa;
|
package org.springframework.boot.autoconfigure.orm.jpa;
|
||||||
|
|
||||||
import javax.persistence.EntityManager;
|
import jakarta.persistence.EntityManager;
|
||||||
|
|
||||||
import org.hibernate.engine.spi.SessionImplementor;
|
import org.hibernate.engine.spi.SessionImplementor;
|
||||||
|
|
||||||
|
|
|
@ -137,7 +137,7 @@ public class HibernateProperties {
|
||||||
if (this.ddlAuto != null) {
|
if (this.ddlAuto != null) {
|
||||||
return this.ddlAuto;
|
return this.ddlAuto;
|
||||||
}
|
}
|
||||||
if (existing.get(AvailableSettings.HBM2DDL_DATABASE_ACTION) != null) {
|
if (existing.get(AvailableSettings.JAKARTA_HBM2DDL_DATABASE_ACTION) != null) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
return defaultDdlAuto.get();
|
return defaultDdlAuto.get();
|
||||||
|
|
|
@ -19,9 +19,10 @@ package org.springframework.boot.autoconfigure.orm.jpa;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import javax.persistence.EntityManagerFactory;
|
|
||||||
import javax.sql.DataSource;
|
import javax.sql.DataSource;
|
||||||
|
|
||||||
|
import jakarta.persistence.EntityManagerFactory;
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue