File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
spring-rabbit/src/main/java/org/springframework/amqp/rabbit/listener Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -525,9 +525,6 @@ protected final boolean sharedConnectionEnabled() {
525
525
526
526
@ Override
527
527
protected void doInitialize () {
528
- Assert .state (!this .consumerBatchEnabled || getMessageListener () instanceof BatchMessageListener
529
- || getMessageListener () instanceof ChannelAwareBatchMessageListener ,
530
- "When setting 'consumerBatchEnabled' to true, the listener must support batching" );
531
528
Assert .state (!this .consumerBatchEnabled || isDeBatchingEnabled (),
532
529
"When setting 'consumerBatchEnabled' to true, 'deBatchingEnabled' must also be true" );
533
530
}
@@ -543,6 +540,9 @@ public int getActiveConsumerCount() {
543
540
*/
544
541
@ Override
545
542
protected void doStart () {
543
+ Assert .state (!this .consumerBatchEnabled || getMessageListener () instanceof BatchMessageListener
544
+ || getMessageListener () instanceof ChannelAwareBatchMessageListener ,
545
+ "When setting 'consumerBatchEnabled' to true, the listener must support batching" );
546
546
checkListenerContainerAware ();
547
547
super .doStart ();
548
548
synchronized (this .consumersMonitor ) {
You can’t perform that action at this time.
0 commit comments