|
36 | 36 | * Wrap a {@link org.springframework.web.socket.WebSocketSession WebSocketSession}
|
37 | 37 | * to guarantee only one thread can send messages at a time.
|
38 | 38 | *
|
39 |
| - * <p>If a send is slow, subsequent attempts to send more messages from other threads |
40 |
| - * will not be able to acquire the flush lock and messages will be buffered instead. |
41 |
| - * At that time, the specified buffer-size limit and send-time limit will be checked |
42 |
| - * and the session will be closed if the limits are exceeded. |
| 39 | + * <p>If a {@code send} is slow, subsequent attempts to send more messages from |
| 40 | + * other threads will not be able to acquire the flush lock, and messages will be |
| 41 | + * buffered instead. At that time, the specified buffer-size limit and send-time |
| 42 | + * limit will be checked, and the session will be closed if the limits are exceeded. |
43 | 43 | *
|
44 | 44 | * @author Rossen Stoyanchev
|
45 | 45 | * @author Juergen Hoeller
|
@@ -91,7 +91,7 @@ public ConcurrentWebSocketSessionDecorator(WebSocketSession delegate, int sendTi
|
91 | 91 | * @param sendTimeLimit the send-time limit (milliseconds)
|
92 | 92 | * @param bufferSizeLimit the buffer-size limit (number of bytes)
|
93 | 93 | * @param overflowStrategy the overflow strategy to use; by default the
|
94 |
| - * session is terminated. |
| 94 | + * session is terminated |
95 | 95 | * @since 5.1
|
96 | 96 | */
|
97 | 97 | public ConcurrentWebSocketSessionDecorator(
|
@@ -120,6 +120,14 @@ public int getBufferSizeLimit() {
|
120 | 120 | return this.bufferSizeLimit;
|
121 | 121 | }
|
122 | 122 |
|
| 123 | + /** |
| 124 | + * Return the configured {@link OverflowStrategy}. |
| 125 | + * @since 6.2.9 |
| 126 | + */ |
| 127 | + public OverflowStrategy getOverflowStrategy() { |
| 128 | + return this.overflowStrategy; |
| 129 | + } |
| 130 | + |
123 | 131 | /**
|
124 | 132 | * Return the current buffer size (number of bytes).
|
125 | 133 | */
|
@@ -276,13 +284,6 @@ public void close(CloseStatus status) throws IOException {
|
276 | 284 | }
|
277 | 285 | }
|
278 | 286 |
|
279 |
| - /** |
280 |
| - * Return the configured overflow strategy. |
281 |
| - * @since 6.3 |
282 |
| - */ |
283 |
| - public OverflowStrategy getOverflowStrategy() { |
284 |
| - return this.overflowStrategy; |
285 |
| - } |
286 | 287 |
|
287 | 288 | @Override
|
288 | 289 | public String toString() {
|
|
0 commit comments