File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
sauron-service/src/main/java/com/freenow/sauron/config Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change 11package com .freenow .sauron .config ;
22
33import org .springframework .amqp .core .Queue ;
4+ import org .springframework .amqp .rabbit .config .SimpleRabbitListenerContainerFactory ;
5+ import org .springframework .beans .factory .annotation .Qualifier ;
46import org .springframework .boot .autoconfigure .condition .ConditionalOnProperty ;
57import org .springframework .context .annotation .Bean ;
68import org .springframework .context .annotation .Configuration ;
@@ -16,4 +18,12 @@ public Queue sauronQueue()
1618 {
1719 return new Queue (SAURON_QUEUE_NAME , true );
1820 }
21+
22+
23+ @ Bean
24+ public SimpleRabbitListenerContainerFactory eventBusPrefetchCount (@ Qualifier ("eventBus" ) SimpleRabbitListenerContainerFactory eventBus )
25+ {
26+ eventBus .setPrefetchCount (1 );
27+ return eventBus ;
28+ }
1929}
You can’t perform that action at this time.
0 commit comments