This is an automated email from the ASF dual-hosted git repository. btellier pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/james-project.git
commit a120e6a1a3d4a81f63ccfc355bff83f325204760 Author: Benoit Tellier <[email protected]> AuthorDate: Tue Mar 14 18:19:28 2023 +0700 [FIX] Sequential execution for LIST commands Being non-sequential leads to data races writing the data at the transport layer, causing massive issues. --- .../src/main/java/org/apache/james/imap/processor/ListProcessor.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/protocols/imap/src/main/java/org/apache/james/imap/processor/ListProcessor.java b/protocols/imap/src/main/java/org/apache/james/imap/processor/ListProcessor.java index 7f7ad6b6be..a98a27e1ea 100644 --- a/protocols/imap/src/main/java/org/apache/james/imap/processor/ListProcessor.java +++ b/protocols/imap/src/main/java/org/apache/james/imap/processor/ListProcessor.java @@ -227,7 +227,7 @@ public class ListProcessor<T extends ListRequest> extends AbstractMailboxProcess } }) .doOnNext(metaData -> respondMyRights(request, responder, mailboxSession, metaData)) - .flatMap(metaData -> request.getStatusDataItems().map(statusDataItems -> statusProcessor.sendStatus(retrieveMessageManager(metaData, mailboxSession), statusDataItems, responder, session, mailboxSession)).orElse(Mono.empty())) + .concatMap(metaData -> request.getStatusDataItems().map(statusDataItems -> statusProcessor.sendStatus(retrieveMessageManager(metaData, mailboxSession), statusDataItems, responder, session, mailboxSession)).orElse(Mono.empty())) .then(); } @@ -247,7 +247,7 @@ public class ListProcessor<T extends ListRequest> extends AbstractMailboxProcess .flatMapIterable(list -> list) .doOnNext(pathAndResponse -> responder.respond(pathAndResponse.getMiddle())) .doOnNext(pathAndResponse -> pathAndResponse.getRight().ifPresent(mailboxMetaData -> respondMyRights(request, responder, mailboxSession, mailboxMetaData))) - .flatMap(pathAndResponse -> sendStatusWhenSubscribed(session, request, responder, mailboxSession, pathAndResponse)) + .concatMap(pathAndResponse -> sendStatusWhenSubscribed(session, request, responder, mailboxSession, pathAndResponse)) .then(); } --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
