Deprecate types removed in 7.0

This commit `@Deprecate` for removal the following because support was
removed in 7.0:

* Netty 5 and Reactor Netty2 experimental support is abandonned
* Undertow does not support the Framework 7.0 baseline, developers
  should consider another Servlet container at this point

See gh-36591
This commit is contained in:
Brian Clozel
2026-04-03 17:50:38 +02:00
parent d78d80b02a
commit 39a6d4709f
56 changed files with 119 additions and 18 deletions
@@ -34,7 +34,10 @@ import org.springframework.util.MimeTypeUtils;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class Netty5BufferDecoder extends AbstractDataBufferDecoder<Buffer> {
public Netty5BufferDecoder() {
@@ -35,7 +35,10 @@ import org.springframework.util.MimeTypeUtils;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class Netty5BufferEncoder extends AbstractEncoder<Buffer> {
public Netty5BufferEncoder() {
@@ -36,7 +36,10 @@ import org.springframework.util.ObjectUtils;
* @author Violeta Georgieva
* @author Arjen Poutsma
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public final class Netty5DataBuffer implements CloseableDataBuffer, TouchableDataBuffer {
private final Buffer buffer;
@@ -33,7 +33,10 @@ import org.springframework.util.Assert;
* @author Violeta Georgieva
* @author Arjen Poutsma
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class Netty5DataBufferFactory implements DataBufferFactory {
private final BufferAllocator bufferAllocator;
@@ -34,6 +34,7 @@ import static org.assertj.core.api.Assertions.assertThat;
/**
* @author Arjen Poutsma
*/
@SuppressWarnings("removal")
class Netty5BufferDecoderTests extends AbstractDecoderTests<Netty5BufferDecoder> {
private final byte[] fooBytes = "foo".getBytes(StandardCharsets.UTF_8);
@@ -32,6 +32,7 @@ import static org.assertj.core.api.Assertions.assertThat;
/**
* @author Arjen Poutsma
*/
@SuppressWarnings("removal")
class Netty5BufferEncoderTests extends AbstractEncoderTests<Netty5BufferEncoder> {
private final byte[] fooBytes = "foo".getBytes(StandardCharsets.UTF_8);
@@ -457,7 +457,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void decreaseCapacityLowReadPosition(DataBufferFactory bufferFactory) {
assumeThat(bufferFactory).as("Netty 5 does not support decreasing the capacity")
.isNotInstanceOf(Netty5DataBufferFactory.class);
@@ -473,7 +473,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void decreaseCapacityHighReadPosition(DataBufferFactory bufferFactory) {
assumeThat(bufferFactory).as("Netty 5 does not support decreasing the capacity")
.isNotInstanceOf(Netty5DataBufferFactory.class);
@@ -578,6 +578,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("removal")
void asByteBufferIndexLength(DataBufferFactory bufferFactory) {
super.bufferFactory = bufferFactory;
@@ -604,7 +605,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void byteBufferContainsDataBufferChanges(DataBufferFactory bufferFactory) {
assumeThat(bufferFactory).as("Netty 5 does not support sharing data between buffers")
.isNotInstanceOf(Netty5DataBufferFactory.class);
@@ -624,7 +625,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void dataBufferContainsByteBufferChanges(DataBufferFactory bufferFactory) {
assumeThat(bufferFactory).as("Netty 5 does not support sharing data between buffers")
.isNotInstanceOf(Netty5DataBufferFactory.class);
@@ -857,7 +858,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void slice(DataBufferFactory bufferFactory) {
super.bufferFactory = bufferFactory;
@@ -885,7 +886,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void retainedSlice(DataBufferFactory bufferFactory) {
assumeThat(bufferFactory).as("Netty 5 does not support retainedSlice")
.isNotInstanceOf(Netty5DataBufferFactory.class);
@@ -915,7 +916,7 @@ class DataBufferTests extends AbstractDataBufferAllocatingTests {
}
@ParameterizedDataBufferAllocatingTest
@SuppressWarnings("deprecation")
@SuppressWarnings({"deprecation", "removal"})
void spr16351(DataBufferFactory bufferFactory) {
super.bufferFactory = bufferFactory;
@@ -44,7 +44,6 @@ class MonoToListenableFutureAdapterTests {
}
@Test
@SuppressWarnings("deprecation")
void failure() {
Throwable expected = new IllegalStateException("oops");
AtomicReference<Object> actual = new AtomicReference<>();
@@ -201,6 +201,7 @@ public abstract class AbstractDataBufferAllocatingTests {
public @interface ParameterizedDataBufferAllocatingTest {
}
@SuppressWarnings("removal")
static Stream<Arguments> dataBufferFactories() {
return Stream.of(
// Netty 4
@@ -74,6 +74,7 @@ public class ReactorNettyTcpStompClient extends StompClientSupport {
this.tcpClient = tcpClient;
}
@SuppressWarnings("removal")
private static TcpOperations<byte[]> initTcpClient(String host, int port) {
if (reactorNettyClientPresent) {
ReactorNettyTcpClient<byte[]> client = new ReactorNettyTcpClient<>(host, port, new StompReactorNettyCodec());
@@ -356,8 +356,7 @@ public class StompBrokerRelayMessageHandler extends AbstractBrokerMessageHandler
/**
* Configure a TCP client for managing TCP connections to the STOMP broker.
* <p>By default {@link ReactorNettyTcpClient} or
* {@link ReactorNetty2TcpClient} is used.
* <p>By default {@link ReactorNettyTcpClient} is used.
* <p><strong>Note:</strong> when this property is used, any
* {@link #setRelayHost(String) host} or {@link #setRelayPort(int) port}
* specified are effectively ignored.
@@ -470,6 +469,7 @@ public class StompBrokerRelayMessageHandler extends AbstractBrokerMessageHandler
}
}
@SuppressWarnings("removal")
private TcpOperations<byte[]> initTcpClient() {
StompDecoder decoder = new StompDecoder();
if (this.headerInitializer != null) {
@@ -60,7 +60,10 @@ import org.springframework.util.Assert;
* @author Rossen Stoyanchev
* @since 6.0
* @param <P> the type of payload for in and outbound messages
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class ReactorNetty2TcpClient<P> implements TcpOperations<P> {
private static final int PUBLISH_ON_BUFFER_SIZE = 16;
@@ -36,7 +36,9 @@ import org.springframework.messaging.tcp.TcpConnection;
* @author Rossen Stoyanchev
* @since 6.0
* @param <P> the type of payload for outbound messages
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class ReactorNetty2TcpConnection<P> implements TcpConnection<P> {
private final NettyInbound inbound;
@@ -28,6 +28,7 @@ import org.springframework.messaging.tcp.reactor.ReactorNetty2TcpClient;
* @author Rossen Stoyanchev
*/
@Disabled("gh-29287 :: Disabled because they fail too frequently")
@SuppressWarnings("removal")
public class ReactorNetty2StompBrokerRelayIntegrationTests extends AbstractStompBrokerRelayIntegrationTests {
@Override
@@ -62,6 +62,7 @@ class ReactorNettyTcpStompClientTests {
@BeforeEach
@SuppressWarnings("removal")
void setup(TestInfo testInfo) throws Exception {
logger.debug("Setting up before '" + testInfo.getTestMethod().get().getName() + "'");
@@ -314,6 +314,7 @@ class DefaultWebTestClientBuilder implements WebTestClient.Builder {
this.entityResultConsumer, this.responseTimeout, new DefaultWebTestClientBuilder(this));
}
@SuppressWarnings("removal")
private static ClientHttpConnector initConnector() {
if (reactorNettyClientPresent) {
return new ReactorClientHttpConnector();
@@ -77,6 +77,7 @@ public class HeadersAdapterBenchmark {
// Uncomment the following line and comment the similar line for setupImplementationBaseline below
// to benchmark current implementations
@Setup(Level.Trial)
@SuppressWarnings("removal")
public void initImplementationNew() {
this.entriesProvider = map -> new HttpHeaders(map).headerSet();
@@ -40,7 +40,10 @@ import org.springframework.util.Assert;
* @author Violeta Georgieva
* @since 6.0
* @see HttpClient
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class ReactorNetty2ClientHttpConnector implements ClientHttpConnector {
/**
@@ -45,6 +45,7 @@ import org.springframework.http.support.Netty5HeadersAdapter;
* @since 6.0
* @see reactor.netty5.http.client.HttpClient
*/
@SuppressWarnings("removal")
class ReactorNetty2ClientHttpRequest extends AbstractClientHttpRequest implements ZeroCopyHttpOutputMessage {
private final HttpMethod httpMethod;
@@ -52,6 +52,7 @@ import org.springframework.util.ObjectUtils;
* @since 6.0
* @see reactor.netty5.http.client.HttpClient
*/
@SuppressWarnings("removal")
class ReactorNetty2ClientHttpResponse implements ClientHttpResponse {
private static final Log logger = LogFactory.getLog(ReactorNetty2ClientHttpResponse.class);
@@ -42,7 +42,9 @@ import org.springframework.util.Assert;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class ReactorNetty2ResourceFactory implements InitializingBean, DisposableBean {
private boolean useGlobalResources = true;
@@ -33,8 +33,6 @@ import org.springframework.core.codec.DataBufferDecoder;
import org.springframework.core.codec.DataBufferEncoder;
import org.springframework.core.codec.Decoder;
import org.springframework.core.codec.Encoder;
import org.springframework.core.codec.Netty5BufferDecoder;
import org.springframework.core.codec.Netty5BufferEncoder;
import org.springframework.core.codec.NettyByteBufDecoder;
import org.springframework.core.codec.NettyByteBufEncoder;
import org.springframework.core.codec.ResourceDecoder;
@@ -417,6 +415,7 @@ class BaseDefaultCodecs implements CodecConfigurer.DefaultCodecs, CodecConfigure
* Reset and initialize typed readers.
* @since 5.3.3
*/
@SuppressWarnings("removal")
protected void initTypedReaders() {
this.typedReaders.clear();
if (!this.registerDefaults) {
@@ -429,7 +428,7 @@ class BaseDefaultCodecs implements CodecConfigurer.DefaultCodecs, CodecConfigure
addCodec(this.typedReaders, new DecoderHttpMessageReader<>(new NettyByteBufDecoder()));
}
if (netty5BufferPresent) {
addCodec(this.typedReaders, new DecoderHttpMessageReader<>(new Netty5BufferDecoder()));
addCodec(this.typedReaders, new DecoderHttpMessageReader<>(new org.springframework.core.codec.Netty5BufferDecoder()));
}
addCodec(this.typedReaders, new ResourceHttpMessageReader(new ResourceDecoder()));
addCodec(this.typedReaders, new DecoderHttpMessageReader<>(StringDecoder.textPlainOnly()));
@@ -667,6 +666,7 @@ class BaseDefaultCodecs implements CodecConfigurer.DefaultCodecs, CodecConfigure
/**
* Return "base" typed writers only, i.e. common to client and server.
*/
@SuppressWarnings("removal")
final List<HttpMessageWriter<?>> getBaseTypedWriters() {
if (!this.registerDefaults) {
return Collections.emptyList();
@@ -679,7 +679,7 @@ class BaseDefaultCodecs implements CodecConfigurer.DefaultCodecs, CodecConfigure
addCodec(writers, new EncoderHttpMessageWriter<>(new NettyByteBufEncoder()));
}
if (netty5BufferPresent) {
addCodec(writers, new EncoderHttpMessageWriter<>(new Netty5BufferEncoder()));
addCodec(writers, new EncoderHttpMessageWriter<>(new org.springframework.core.codec.Netty5BufferEncoder()));
}
addCodec(writers, new ResourceHttpMessageWriter());
addCodec(writers, new EncoderHttpMessageWriter<>(CharSequenceEncoder.textPlainOnly()));
@@ -37,7 +37,10 @@ import org.springframework.util.Assert;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class ReactorNetty2HttpHandlerAdapter implements BiFunction<HttpServerRequest, HttpServerResponse, Mono<Void>> {
private static final Log logger = HttpLogging.forLogName(ReactorNetty2HttpHandlerAdapter.class);
@@ -53,6 +53,7 @@ import org.springframework.util.MultiValueMap;
* @author Sebastien Deleuze
* @since 6.0
*/
@SuppressWarnings("removal")
class ReactorNetty2ServerHttpRequest extends AbstractServerHttpRequest {
private static final Log logger = HttpLogging.forLogName(ReactorNetty2ServerHttpRequest.class);
@@ -49,6 +49,7 @@ import org.springframework.util.Assert;
* @author Violeta Georgieva
* @since 6.0
*/
@SuppressWarnings("removal")
class ReactorNetty2ServerHttpResponse extends AbstractServerHttpResponse implements ZeroCopyHttpOutputMessage {
private static final Log logger = LogFactory.getLog(ReactorNetty2ServerHttpResponse.class);
@@ -37,7 +37,9 @@ import org.springframework.util.Assert;
* @author Rossen Stoyanchev
* @author Arjen Poutsma
* @since 5.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class UndertowHttpHandlerAdapter implements io.undertow.server.HttpHandler {
private static final Log logger = HttpLogging.forLogName(UndertowHttpHandlerAdapter.class);
@@ -40,7 +40,10 @@ import org.springframework.util.MultiValueMap;
* @author Violeta Georgieva
* @author Simon Baslé
* @since 6.1
* deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public final class Netty5HeadersAdapter implements MultiValueMap<String, String> {
private final HttpHeaders headers;
@@ -71,7 +71,10 @@ public class ContentCachingRequestWrapper extends HttpServletRequestWrapper {
/**
* Create a new ContentCachingRequestWrapper for the given servlet request.
* @param request the original servlet request
* @deprecated in favor of {@link #ContentCachingRequestWrapper(HttpServletRequest, int)}
* in order to explicitly choose the cache limit
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public ContentCachingRequestWrapper(HttpServletRequest request) {
super(request);
int contentLength = request.getContentLength();
@@ -94,6 +94,7 @@ class ClientCodecConfigurerTests {
@Test
@SuppressWarnings("removal")
void defaultReaders() {
List<HttpMessageReader<?>> readers = this.configurer.getReaders();
assertThat(readers).hasSize(20);
@@ -121,6 +122,7 @@ class ClientCodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void defaultWriters() {
List<HttpMessageWriter<?>> writers = this.configurer.getWriters();
assertThat(writers).hasSize(18);
@@ -188,6 +190,7 @@ class ClientCodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void maxInMemorySize() {
int size = 99;
this.configurer.defaultCodecs().maxInMemorySize(size);
@@ -91,6 +91,7 @@ class CodecConfigurerTests {
@Test
@SuppressWarnings("removal")
void defaultReaders() {
List<HttpMessageReader<?>> readers = this.configurer.getReaders();
assertThat(readers).hasSize(19);
@@ -116,6 +117,7 @@ class CodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void defaultWriters() {
List<HttpMessageWriter<?>> writers = this.configurer.getWriters();
assertThat(writers).hasSize(18);
@@ -140,6 +142,7 @@ class CodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void defaultAndCustomReaders() {
Decoder<?> customDecoder1 = mock();
Decoder<?> customDecoder2 = mock();
@@ -188,6 +191,7 @@ class CodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void defaultAndCustomWriters() {
Encoder<?> customEncoder1 = mock();
Encoder<?> customEncoder2 = mock();
@@ -92,6 +92,7 @@ class ServerCodecConfigurerTests {
@Test
@SuppressWarnings("removal")
void defaultReaders() {
List<HttpMessageReader<?>> readers = this.configurer.getReaders();
assertThat(readers).hasSize(19);
@@ -117,6 +118,7 @@ class ServerCodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void defaultWriters() {
List<HttpMessageWriter<?>> writers = this.configurer.getWriters();
assertThat(writers).hasSize(19);
@@ -159,6 +161,7 @@ class ServerCodecConfigurerTests {
}
@Test
@SuppressWarnings("removal")
void maxInMemorySize() {
int size = 99;
this.configurer.defaultCodecs().maxInMemorySize(size);
@@ -98,6 +98,7 @@ class DefaultServerHttpRequestBuilderTests {
return argumentSet(description, headerMap, true);
}
@SuppressWarnings("removal")
static Stream<Arguments> headers() {
return Stream.of(
initHeader("Map", CollectionUtils.toMultiValueMap(new LinkedCaseInsensitiveMap<>(8, Locale.ENGLISH))),
@@ -279,6 +279,7 @@ class HeadersAdaptersTests {
@interface ParameterizedHeadersTest {
}
@SuppressWarnings("removal")
static Stream<Arguments> headers() {
return Stream.of(
argumentSet("Map", CollectionUtils.toMultiValueMap(new LinkedCaseInsensitiveMap<>(8, Locale.ENGLISH))),
@@ -298,6 +299,7 @@ class HeadersAdaptersTests {
@interface ParameterizedPopulatedHeadersTest {
}
@SuppressWarnings("removal")
static Stream<Arguments> nativeHeadersWithCasedEntries() {
return Stream.of(
argumentSet("Netty", new Netty4HeadersAdapter(withHeaders(new DefaultHttpHeaders(), h -> h::add))),
@@ -34,6 +34,7 @@ import static org.assertj.core.api.Assertions.assertThatIllegalStateException;
* @author Brian Clozel
* @author Stephane Nicoll
*/
@SuppressWarnings("removal")
class ContentCachingRequestWrapperTests {
protected static final String FORM_CONTENT_TYPE = MediaType.APPLICATION_FORM_URLENCODED_VALUE;
@@ -29,6 +29,7 @@ import org.springframework.http.server.reactive.ReactorNetty2HttpHandlerAdapter;
* @author Violeta Georgieva
* @since 6.0
*/
@SuppressWarnings("removal")
public class ReactorNetty2HttpServer extends AbstractHttpServer {
private ReactorNetty2HttpHandlerAdapter reactorHandler;
@@ -31,6 +31,7 @@ import org.springframework.http.server.reactive.ReactorNetty2HttpHandlerAdapter;
* @author Violeta Georgieva
* @since 6.0
*/
@SuppressWarnings("removal")
public class ReactorNetty2HttpsServer extends AbstractHttpServer {
private ReactorNetty2HttpHandlerAdapter reactorHandler;
@@ -25,6 +25,7 @@ import org.springframework.http.server.reactive.UndertowHttpHandlerAdapter;
/**
* @author Marek Hawrylczak
*/
@SuppressWarnings("removal")
public class UndertowHttpServer extends AbstractHttpServer {
private Undertow server;
@@ -332,6 +332,7 @@ final class DefaultWebClientBuilder implements WebClient.Builder {
new DefaultWebClientBuilder(this));
}
@SuppressWarnings("removal")
private ClientHttpConnector initConnector() {
if (reactorNettyClientPresent) {
return new ReactorClientHttpConnector();
@@ -272,8 +272,6 @@ public abstract class RouterFunctions {
* {@link org.springframework.http.server.reactive.ServletHttpHandlerAdapter}</li>
* <li>Reactor using the
* {@link org.springframework.http.server.reactive.ReactorHttpHandlerAdapter}
* <li>Undertow using the
* {@link org.springframework.http.server.reactive.UndertowHttpHandlerAdapter}</li>
* </ul>
* <p>Note that {@code HttpWebHandlerAdapter} also implements {@link WebHandler},
* allowing for additional filter and exception handler registration through
@@ -294,8 +292,6 @@ public abstract class RouterFunctions {
* {@link org.springframework.http.server.reactive.ServletHttpHandlerAdapter}</li>
* <li>Reactor using the
* {@link org.springframework.http.server.reactive.ReactorHttpHandlerAdapter}</li>
* <li>Undertow using the
* {@link org.springframework.http.server.reactive.UndertowHttpHandlerAdapter}</li>
* </ul>
* @param routerFunction the router function to convert
* @param strategies the strategies to use
@@ -196,6 +196,7 @@ public class WebSocketMessage {
}
@SuppressWarnings("removal")
private static class ReactorNetty2Helper {
static WebSocketMessage retain(WebSocketMessage message) {
@@ -44,7 +44,10 @@ import org.springframework.web.reactive.socket.WebSocketSession;
* @author Violeta Georgieva
* @since 6.0
* @param <T> the native delegate type
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public abstract class Netty5WebSocketSessionSupport<T> extends AbstractWebSocketSession<T> {
/**
@@ -43,7 +43,10 @@ import org.springframework.web.reactive.socket.WebSocketSession;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class ReactorNetty2WebSocketSession
extends Netty5WebSocketSessionSupport<ReactorNetty2WebSocketSession.WebSocketConnection> {
@@ -133,7 +136,10 @@ public class ReactorNetty2WebSocketSession
/**
* Simple container for {@link NettyInbound} and {@link NettyOutbound}.
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public static class WebSocketConnection {
private final WebsocketInbound inbound;
@@ -42,7 +42,10 @@ import org.springframework.web.reactive.socket.WebSocketMessage.Type;
* @author Violeta Georgieva
* @author Rossen Stoyanchev
* @since 5.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class UndertowWebSocketHandlerAdapter extends AbstractReceiveListener {
private final UndertowWebSocketSession session;
@@ -44,7 +44,9 @@ import org.springframework.web.reactive.socket.WebSocketSession;
* @author Violeta Georgieva
* @author Rossen Stoyanchev
* @since 5.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class UndertowWebSocketSession extends AbstractListenerWebSocketSession<WebSocketChannel> {
public UndertowWebSocketSession(WebSocketChannel channel, HandshakeInfo info, DataBufferFactory factory) {
@@ -43,7 +43,9 @@ import org.springframework.web.reactive.socket.adapter.ReactorNetty2WebSocketSes
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class ReactorNetty2WebSocketClient implements WebSocketClient {
private static final Log logger = LogFactory.getLog(ReactorNetty2WebSocketClient.class);
@@ -119,6 +121,7 @@ public class ReactorNetty2WebSocketClient implements WebSocketClient {
}
@Override
@SuppressWarnings("removal")
public Mono<Void> execute(URI url, HttpHeaders requestHeaders, WebSocketHandler handler) {
String protocols = StringUtils.collectionToCommaDelimitedString(handler.getSubProtocols());
WebsocketClientSpec clientSpec = buildSpec(protocols);
@@ -52,7 +52,10 @@ import org.springframework.web.reactive.socket.adapter.UndertowWebSocketSession;
* @author Violeta Georgieva
* @author Rossen Stoyanchev
* @since 5.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class UndertowWebSocketClient implements WebSocketClient {
private static final Log logger = LogFactory.getLog(UndertowWebSocketClient.class);
@@ -282,6 +282,7 @@ public class HandshakeWebSocketService implements WebSocketService, Lifecycle {
}
@SuppressWarnings("removal")
static RequestUpgradeStrategy initUpgradeStrategy() {
if (tomcatWsPresent) {
return new TomcatRequestUpgradeStrategy();
@@ -319,6 +320,7 @@ public class HandshakeWebSocketService implements WebSocketService, Lifecycle {
return new ReactorNettyRequestUpgradeStrategy();
}
@SuppressWarnings("removal")
public static RequestUpgradeStrategy forReactorNetty2() {
return new ReactorNetty2RequestUpgradeStrategy();
}
@@ -41,7 +41,10 @@ import org.springframework.web.server.ServerWebExchange;
*
* @author Violeta Georgieva
* @since 6.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class ReactorNetty2RequestUpgradeStrategy implements RequestUpgradeStrategy {
private final Supplier<WebsocketServerSpec.Builder> specBuilderSupplier;
@@ -48,7 +48,10 @@ import org.springframework.web.server.ServerWebExchange;
* @author Rossen Stoyanchev
* @author Brian Clozel
* @since 5.0
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
@SuppressWarnings("removal")
public class UndertowRequestUpgradeStrategy implements RequestUpgradeStrategy {
@Override
@@ -106,6 +106,7 @@ class WebClientIntegrationTests {
@interface ParameterizedWebClientTest {
}
@SuppressWarnings("removal")
static Stream<Arguments> arguments() {
return Stream.of(
argumentSet("Reactor Netty", new ReactorClientHttpConnector()),
@@ -194,6 +195,7 @@ class WebClientIntegrationTests {
}
@ParameterizedWebClientTest
@SuppressWarnings("removal")
void applyAttributesToNativeRequest(ClientHttpConnector connector) {
startServer(connector);
prepareResponse(response -> {});
@@ -948,6 +950,7 @@ class WebClientIntegrationTests {
}
@ParameterizedWebClientTest
@SuppressWarnings("removal")
void statusHandlerSuppressedErrorSignalWithFlux(ClientHttpConnector connector) {
// Temporarily disabled, leads to io.netty5.buffer.BufferClosedException
@@ -93,6 +93,7 @@ abstract class AbstractReactiveWebSocketIntegrationTests {
@interface ParameterizedWebSocketTest {
}
@SuppressWarnings("removal")
static Stream<Object[]> arguments() throws IOException {
List<Named<WebSocketClient>> clients = List.of(
@@ -214,6 +215,7 @@ abstract class AbstractReactiveWebSocketIntegrationTests {
}
@Configuration
@SuppressWarnings("removal")
static class ReactorNetty2Config extends AbstractHandlerAdapterConfig {
@Override
@@ -233,6 +235,7 @@ abstract class AbstractReactiveWebSocketIntegrationTests {
@Configuration
@SuppressWarnings("removal")
static class UndertowConfig extends AbstractHandlerAdapterConfig {
@Override
@@ -34,7 +34,9 @@ import jakarta.websocket.server.ServerEndpointConfig;
* @author Juergen Hoeller
* @since 4.0.1
* @see io.undertow.websockets.jsr.ServerWebSocketContainer#doUpgrade
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class UndertowRequestUpgradeStrategy extends StandardWebSocketUpgradeStrategy {
private static final String[] SUPPORTED_VERSIONS = new String[] {"13", "8", "7"};
@@ -403,6 +403,7 @@ public abstract class AbstractHandshakeHandler implements HandshakeHandler, Life
}
@SuppressWarnings("removal")
private static RequestUpgradeStrategy initRequestUpgradeStrategy() {
if (tomcatWsPresent) {
return new TomcatRequestUpgradeStrategy();
@@ -88,7 +88,9 @@ import org.springframework.web.socket.sockjs.frame.SockJsFrame;
* @author Rossen Stoyanchev
* @since 4.1.2
* @see org.xnio.Options
* @deprecated as of 6.2.18 with no replacement
*/
@Deprecated(since = "6.2.18", forRemoval = true)
public class UndertowXhrTransport extends AbstractXhrTransport {
private static final AttachmentKey<String> RESPONSE_BODY = AttachmentKey.create(String.class);
@@ -198,6 +198,7 @@ public abstract class AbstractWebSocketIntegrationTests {
@Configuration(proxyBeanMethods = false)
@SuppressWarnings("removal")
static class UndertowUpgradeStrategyConfig extends AbstractRequestUpgradeStrategyConfig {
@Override
@@ -29,6 +29,7 @@ import org.springframework.web.socket.server.standard.UndertowRequestUpgradeStra
/**
* @author Brian Clozel
*/
@SuppressWarnings("removal")
class UndertowSockJsIntegrationTests extends AbstractSockJsIntegrationTests {
@Override