简体   繁体   中英

How to implement transaction in Spring Integration Mail Adapter for pop3

We have been trying to implement transaction in Pop3 and came across the documentation of Transaction Synchronization in release 4.2.0.RELEASE

http://docs.spring.io/spring-integration/docs/latest-ga/reference/html/mail.html#mail-tx-sync

But they are iterating through the folder mails to delete a particular message before committing the transaction.Is there any implicit way to delete the mails by id or does Spring Integration provide any sync factory to handle the email transaction internally.

Email is not transactional; the cited documentation shows the ability to synchronize some action when a transaction commits. But the action taken on a non-transactional resource is not really transactional.

Since the framework can't anticipate what a user might want to do, it provides nothing other than the hooks to enable such user actions.

The documentation simply shows one such action that might be taken another action might be to move the email to another folder (when using IMAP).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM