@@ -62,7 +62,7 @@ void shouldAcquireAndReleaseFullPermits() {
62
62
.backPressureMode (BackPressureMode .ALWAYS_POLL_MAX_MESSAGES )
63
63
.maxDelayBetweenPolls (Duration .ofMillis (200 )).build ();
64
64
BackPressureHandler backPressureHandler = BackPressureHandlerFactory
65
- .concurrencyLimiterBackPressureHandler (options , Duration .ofMillis (100L ));
65
+ .adaptativeThroughputBackPressureHandler (options , Duration .ofMillis (100L ));
66
66
67
67
ExecutorService threadPool = Executors .newCachedThreadPool ();
68
68
CountDownLatch pollingCounter = new CountDownLatch (3 );
@@ -120,7 +120,7 @@ void shouldAdaptThroughputMode() {
120
120
.backPressureMode (BackPressureMode .ALWAYS_POLL_MAX_MESSAGES )
121
121
.maxDelayBetweenPolls (Duration .ofMillis (150 )).build ();
122
122
BackPressureHandler backPressureHandler = BackPressureHandlerFactory
123
- .concurrencyLimiterBackPressureHandler (options , Duration .ofMillis (100L ));
123
+ .adaptativeThroughputBackPressureHandler (options , Duration .ofMillis (100L ));
124
124
125
125
ExecutorService threadPool = Executors .newCachedThreadPool ();
126
126
CountDownLatch pollingCounter = new CountDownLatch (3 );
@@ -206,7 +206,7 @@ void shouldAcquireAndReleasePartialPermits() {
206
206
SqsContainerOptions options = SqsContainerOptions .builder ().maxMessagesPerPoll (10 ).maxConcurrentMessages (10 )
207
207
.backPressureMode (BackPressureMode .AUTO ).maxDelayBetweenPolls (Duration .ofMillis (150 )).build ();
208
208
BackPressureHandler backPressureHandler = BackPressureHandlerFactory
209
- .concurrencyLimiterBackPressureHandler (options , Duration .ofMillis (200L ));
209
+ .adaptativeThroughputBackPressureHandler (options , Duration .ofMillis (200L ));
210
210
211
211
ExecutorService threadPool = Executors
212
212
.newCachedThreadPool (new MessageExecutionThreadFactory ("test " + testCounter .incrementAndGet ()));
@@ -297,7 +297,7 @@ public org.springframework.messaging.Message<?> toMessagingMessage(Message sourc
297
297
.backPressureMode (BackPressureMode .ALWAYS_POLL_MAX_MESSAGES )
298
298
.maxDelayBetweenPolls (Duration .ofMillis (150 )).messageConverter (converter ).build ();
299
299
BackPressureHandler backPressureHandler = BackPressureHandlerFactory
300
- .concurrencyLimiterBackPressureHandler (options , Duration .ofMillis (100L ));
300
+ .adaptativeThroughputBackPressureHandler (options , Duration .ofMillis (100L ));
301
301
302
302
AtomicInteger messagesInSink = new AtomicInteger (0 );
303
303
AtomicBoolean hasFailed = new AtomicBoolean (false );
@@ -350,7 +350,7 @@ void shouldBackOffIfPollingThrowsAnError() {
350
350
.backPressureMode (BackPressureMode .ALWAYS_POLL_MAX_MESSAGES )
351
351
.maxDelayBetweenPolls (Duration .ofMillis (200 )).pollBackOffPolicy (policy ).build ();
352
352
BackPressureHandler backPressureHandler = BackPressureHandlerFactory
353
- .concurrencyLimiterBackPressureHandler (options , Duration .ofMillis (100L ));
353
+ .adaptativeThroughputBackPressureHandler (options , Duration .ofMillis (100L ));
354
354
355
355
var currentPoll = new AtomicInteger (0 );
356
356
var waitThirdPollLatch = new CountDownLatch (4 );
0 commit comments