@@ -306,21 +306,19 @@ void childClosing(ChildQueue child, boolean immediate) {
306306 * Called by MainEventBusProcessor after TaskStore persistence.
307307 */
308308 void distributeToChildren (EventQueueItem item ) {
309- synchronized (children ) {
310- int childCount = children .size ();
311- if (LOGGER .isDebugEnabled ()) {
312- LOGGER .debug ("MainQueue[{}]: Distributing event {} to {} children" ,
313- taskId , item .getEvent ().getClass ().getSimpleName (), childCount );
314- }
315- children .forEach (child -> {
316- LOGGER .debug ("MainQueue[{}]: Enqueueing event {} to child queue" ,
317- taskId , item .getEvent ().getClass ().getSimpleName ());
318- child .internalEnqueueItem (item );
319- });
320- if (LOGGER .isDebugEnabled ()) {
321- LOGGER .debug ("MainQueue[{}]: Completed distribution of {} to {} children" ,
322- taskId , item .getEvent ().getClass ().getSimpleName (), childCount );
323- }
309+ int childCount = children .size ();
310+ if (LOGGER .isDebugEnabled ()) {
311+ LOGGER .debug ("MainQueue[{}]: Distributing event {} to {} children" ,
312+ taskId , item .getEvent ().getClass ().getSimpleName (), childCount );
313+ }
314+ children .forEach (child -> {
315+ LOGGER .debug ("MainQueue[{}]: Enqueueing event {} to child queue" ,
316+ taskId , item .getEvent ().getClass ().getSimpleName ());
317+ child .internalEnqueueItem (item );
318+ });
319+ if (LOGGER .isDebugEnabled ()) {
320+ LOGGER .debug ("MainQueue[{}]: Completed distribution of {} to {} children" ,
321+ taskId , item .getEvent ().getClass ().getSimpleName (), childCount );
324322 }
325323 }
326324
0 commit comments