diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/CloseStatus.java b/spring-websocket/src/main/java/org/springframework/web/socket/CloseStatus.java index fe9972e7c87..bf68fcefe54 100644 --- a/spring-websocket/src/main/java/org/springframework/web/socket/CloseStatus.java +++ b/spring-websocket/src/main/java/org/springframework/web/socket/CloseStatus.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2021 the original author or authors. + * Copyright 2002-2022 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -139,7 +139,7 @@ public final class CloseStatus implements Serializable { public static final CloseStatus TLS_HANDSHAKE_FAILURE = new CloseStatus(1015); /** - * A status code for use within the framework the indicate a session has + * A status code for use within the framework that indicates a session has * become unreliable (e.g. timed out while sending a message) and extra * care should be exercised, e.g. avoid sending any further data to the * client that may be done during normal shutdown. diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketExtension.java b/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketExtension.java index 8c18d4ff8aa..da31a3b8c4e 100644 --- a/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketExtension.java +++ b/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketExtension.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2021 the original author or authors. + * Copyright 2002-2022 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -83,7 +83,7 @@ public class WebSocketExtension { /** - * Return the name of the extension (never {@code null) or empty}. + * Return the name of the extension (never {@code null} or empty). */ public String getName() { return this.name; diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketSession.java b/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketSession.java index 56388d9b47d..00878291d21 100644 --- a/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketSession.java +++ b/spring-websocket/src/main/java/org/springframework/web/socket/WebSocketSession.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2020 the original author or authors. + * Copyright 2002-2022 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -121,7 +121,7 @@ public interface WebSocketSession extends Closeable { /** * Send a WebSocket message: either {@link TextMessage} or {@link BinaryMessage}. *
Note: The underlying standard WebSocket session (JSR-356) does
- * not allow concurrent sending. Therefore sending must be synchronized. To ensure
+ * not allow concurrent sending. Therefore, sending must be synchronized. To ensure
* that, one option is to wrap the {@code WebSocketSession} with the
* {@link org.springframework.web.socket.handler.ConcurrentWebSocketSessionDecorator
* ConcurrentWebSocketSessionDecorator}.
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/adapter/jetty/JettyWebSocketSession.java b/spring-websocket/src/main/java/org/springframework/web/socket/adapter/jetty/JettyWebSocketSession.java
index 37a22a36eaa..880485d3a17 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/adapter/jetty/JettyWebSocketSession.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/adapter/jetty/JettyWebSocketSession.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2021 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -83,7 +83,7 @@ public class JettyWebSocketSession extends AbstractWebSocketSession NOTE that closing the session may not succeed in
* actually closing the physical socket and may also hang. This is true
* especially when using blocking IO such as the BIO connector in Tomcat
- * that is used by default on Tomcat 7. Therefore it is recommended to ensure
+ * that is used by default on Tomcat 7. Therefore, it is recommended to ensure
* the server is using non-blocking IO such as Tomcat's NIO connector that
* is used by default on Tomcat 8. If you must use blocking IO consider
* customizing OS-level TCP settings, for example
@@ -123,7 +123,7 @@ public class WebSocketTransportRegistration {
* NOTE that closing the session may not succeed in
* actually closing the physical socket and may also hang. This is true
* especially when using blocking IO such as the BIO connector in Tomcat
- * configured by default on Tomcat 7. Therefore it is recommended to ensure
+ * configured by default on Tomcat 7. Therefore, it is recommended to ensure
* the server is using non-blocking IO such as Tomcat's NIO connector used
* by default on Tomcat 8. If you must use blocking IO consider customizing
* OS-level TCP settings, for example {@code /proc/sys/net/ipv4/tcp_retries2}
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/handler/ConcurrentWebSocketSessionDecorator.java b/spring-websocket/src/main/java/org/springframework/web/socket/handler/ConcurrentWebSocketSessionDecorator.java
index 5e538550a64..158db36802f 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/handler/ConcurrentWebSocketSessionDecorator.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/handler/ConcurrentWebSocketSessionDecorator.java
@@ -289,7 +289,7 @@ public class ConcurrentWebSocketSessionDecorator extends WebSocketSessionDecorat
public enum OverflowStrategy {
/**
- * Throw {@link SessionLimitExceededException} that would will result
+ * Throw {@link SessionLimitExceededException} that will result
* in the session being terminated.
*/
TERMINATE,
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/handler/WebSocketHandlerDecoratorFactory.java b/spring-websocket/src/main/java/org/springframework/web/socket/handler/WebSocketHandlerDecoratorFactory.java
index f3110fc7195..8a3cc640f30 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/handler/WebSocketHandlerDecoratorFactory.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/handler/WebSocketHandlerDecoratorFactory.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2014 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -34,7 +34,7 @@ public interface WebSocketHandlerDecoratorFactory {
/**
* Decorate the given WebSocketHandler.
* @param handler the handler to be decorated.
- * @return the same handler or the handler wrapped with a sub-class of
+ * @return the same handler or the handler wrapped with a subclass of
* {@code WebSocketHandlerDecorator}.
*/
WebSocketHandler decorate(WebSocketHandler handler);
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/messaging/WebSocketAnnotationMethodMessageHandler.java b/spring-websocket/src/main/java/org/springframework/web/socket/messaging/WebSocketAnnotationMethodMessageHandler.java
index 847741b2c1f..f4a5eb4826c 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/messaging/WebSocketAnnotationMethodMessageHandler.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/messaging/WebSocketAnnotationMethodMessageHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2019 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -30,7 +30,7 @@ import org.springframework.messaging.simp.annotation.support.SimpAnnotationMetho
import org.springframework.web.method.ControllerAdviceBean;
/**
- * A sub-class of {@link SimpAnnotationMethodMessageHandler} to provide support
+ * A subclass of {@link SimpAnnotationMethodMessageHandler} to provide support
* for {@link org.springframework.web.bind.annotation.ControllerAdvice
* ControllerAdvice} with global {@code @MessageExceptionHandler} methods.
*
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/server/standard/ServerEndpointExporter.java b/spring-websocket/src/main/java/org/springframework/web/socket/server/standard/ServerEndpointExporter.java
index efd7c756f84..ab0ebbbd2f4 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/server/standard/ServerEndpointExporter.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/server/standard/ServerEndpointExporter.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2018 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -66,7 +66,7 @@ public class ServerEndpointExporter extends WebApplicationObjectSupport
/**
* Explicitly list annotated endpoint types that should be registered on startup. This
* can be done if you wish to turn off a Servlet container's scan for endpoints, which
- * goes through all 3rd party jars in the, and rely on Spring configuration instead.
+ * goes through all 3rd party jars in the classpath, and rely on Spring configuration instead.
* @param annotatedEndpointClasses {@link ServerEndpoint}-annotated types
*/
public void setAnnotatedEndpointClasses(Class>... annotatedEndpointClasses) {
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/server/support/AbstractHandshakeHandler.java b/spring-websocket/src/main/java/org/springframework/web/socket/server/support/AbstractHandshakeHandler.java
index 1f31808c6c1..a7a5f4e0d97 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/server/support/AbstractHandshakeHandler.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/server/support/AbstractHandshakeHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2021 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -49,7 +49,7 @@ import org.springframework.web.socket.server.HandshakeHandler;
import org.springframework.web.socket.server.RequestUpgradeStrategy;
/**
- * A base class for {@link HandshakeHandler} implementations, independent from the Servlet API.
+ * A base class for {@link HandshakeHandler} implementations, independent of the Servlet API.
*
* Performs initial validation of the WebSocket handshake request - possibly rejecting it
* through the appropriate HTTP status code - while also allowing its subclasses to override
@@ -58,7 +58,7 @@ import org.springframework.web.socket.server.RequestUpgradeStrategy;
*
* If the negotiation succeeds, the actual upgrade is delegated to a server-specific
* {@link org.springframework.web.socket.server.RequestUpgradeStrategy}, which will update
- * the response as necessary and initialize the WebSocket. Currently supported servers are
+ * the response as necessary and initialize the WebSocket. Currently, supported servers are
* Jetty 9.0-9.3, Tomcat 7.0.47+ and 8.x, Undertow 1.0-1.3, GlassFish 4.1+, WebLogic 12.1.3+.
*
* @author Rossen Stoyanchev
@@ -176,9 +176,9 @@ public abstract class AbstractHandshakeHandler implements HandshakeHandler, Life
* is accepted. If there are no matches the response will not contain a
* {@literal Sec-WebSocket-Protocol} header.
* Note that if the WebSocketHandler passed in at runtime is an instance of
- * {@link SubProtocolCapable} then there is not need to explicitly configure
+ * {@link SubProtocolCapable} then there is no need to explicitly configure
* this property. That is certainly the case with the built-in STOMP over
- * WebSocket support. Therefore this property should be configured explicitly
+ * WebSocket support. Therefore, this property should be configured explicitly
* only if the WebSocketHandler does not implement {@code SubProtocolCapable}.
*/
public void setSupportedProtocols(String... protocols) {
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/client/SockJsClient.java b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/client/SockJsClient.java
index 6f59483348e..004e796d2dc 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/client/SockJsClient.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/client/SockJsClient.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2021 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -50,7 +50,7 @@ import org.springframework.web.util.UriComponentsBuilder;
* A SockJS implementation of
* {@link org.springframework.web.socket.client.WebSocketClient WebSocketClient}
* with fallback alternatives that simulate a WebSocket interaction through plain
- * HTTP streaming and long polling techniques..
+ * HTTP streaming and long polling techniques.
*
* Implements {@link Lifecycle} in order to propagate lifecycle events to
* the transports it is configured with.
@@ -337,7 +337,7 @@ public class SockJsClient implements WebSocketClient, Lifecycle {
}
/**
- * By default the result of a SockJS "Info" request, including whether the
+ * By default, the result of a SockJS "Info" request, including whether the
* server has WebSocket disabled and how long the request took (used for
* calculating transport timeout time) is cached. This method can be used to
* clear that cache hence causing it to re-populate.
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/frame/AbstractSockJsMessageCodec.java b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/frame/AbstractSockJsMessageCodec.java
index e6baf97d77f..dbf3461f8bc 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/frame/AbstractSockJsMessageCodec.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/frame/AbstractSockJsMessageCodec.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2018 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -19,7 +19,7 @@ package org.springframework.web.socket.sockjs.frame;
import org.springframework.util.Assert;
/**
- * An base class for SockJS message codec that provides an implementation of
+ * A base class for SockJS message codec that provides an implementation of
* {@link #encode(String[])}.
*
* @author Rossen Stoyanchev
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/SockJsServiceConfig.java b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/SockJsServiceConfig.java
index dcf475f0f77..d6bb37216e1 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/SockJsServiceConfig.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/SockJsServiceConfig.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2018 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -60,7 +60,7 @@ public interface SockJsServiceConfig {
* property since even streaming transports recycle HTTP requests periodically.
* The amount of time between HTTP requests should be relatively brief and will not
* exceed the allows disconnect delay (see
- * {@link org.springframework.web.socket.sockjs.support.AbstractSockJsService#setDisconnectDelay(long)},
+ * {@link org.springframework.web.socket.sockjs.support.AbstractSockJsService#setDisconnectDelay(long)}),
* 5 seconds by default.
* The default size is 100.
*/
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/AbstractSockJsSession.java b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/AbstractSockJsSession.java
index 2ea6c1a4fb4..be3683d396a 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/AbstractSockJsSession.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/AbstractSockJsSession.java
@@ -61,7 +61,7 @@ public abstract class AbstractSockJsSession implements SockJsSession {
* Log category to use on network IO exceptions after a client has gone away.
* Servlet containers don't expose a client disconnected callback; see
* eclipse-ee4j/servlet-api#44.
- * Therefore network IO failures may occur simply because a client has gone away,
+ * Therefore, network IO failures may occur simply because a client has gone away,
* and that can fill the logs with unnecessary stack traces.
* We make a best effort to identify such network failures, on a per-server
* basis, and log them under a separate log category. A simple one-line message
diff --git a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/WebSocketServerSockJsSession.java b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/WebSocketServerSockJsSession.java
index a8ed9363270..611d51f739b 100644
--- a/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/WebSocketServerSockJsSession.java
+++ b/spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/WebSocketServerSockJsSession.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2019 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -159,7 +159,7 @@ public class WebSocketServerSockJsSession extends AbstractSockJsSession implemen
delegateConnectionEstablished();
this.webSocketSession.sendMessage(new TextMessage(SockJsFrame.openFrame().getContent()));
- // Flush any messages cached in the mean time
+ // Flush any messages cached in the meantime
while (!this.initSessionCache.isEmpty()) {
writeFrame(SockJsFrame.messageFrame(getMessageCodec(), this.initSessionCache.poll()));
}
diff --git a/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpReceivingTransportHandlerTests.java b/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpReceivingTransportHandlerTests.java
index 996391d16ee..9d9639cd5bf 100644
--- a/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpReceivingTransportHandlerTests.java
+++ b/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpReceivingTransportHandlerTests.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2019 the original author or authors.
+ * Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -35,7 +35,7 @@ import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.verifyNoMoreInteractions;
/**
- * Test fixture for {@link AbstractHttpReceivingTransportHandler} and sub-classes
+ * Test fixture for {@link AbstractHttpReceivingTransportHandler} and subclasses
* {@link XhrReceivingTransportHandler}.
*
* @author Rossen Stoyanchev
diff --git a/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpSendingTransportHandlerTests.java b/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpSendingTransportHandlerTests.java
index 4eafd96a4cc..355ccb06eb4 100644
--- a/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpSendingTransportHandlerTests.java
+++ b/spring-websocket/src/test/java/org/springframework/web/socket/sockjs/transport/handler/HttpSendingTransportHandlerTests.java
@@ -36,7 +36,7 @@ import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
/**
- * Test fixture for {@link AbstractHttpSendingTransportHandler} and sub-classes.
+ * Test fixture for {@link AbstractHttpSendingTransportHandler} and subclasses.
*
* @author Rossen Stoyanchev
*/