Operation mapping
- •email:send (SMTP) → JavaMailSender.send(MimeMessage)
- •email:list-imap / email:list-pop3 → JavaMailSender.getSession() + the JavaMail Store/Folder APIs
Before and after: send
<email:send config-ref="Email_Config">
<email:to-addresses><email:to-address value="[email protected]"/></email:to-addresses>
</email:send>SimpleMailMessage msg = new SimpleMailMessage();
msg.setTo("[email protected]");
msg.setSubject(subject);
msg.setText(body);
mailSender.send(msg);How the conversion is validated
Email is verified against a real mail server (GreenMail) running in a container — the converted app actually sends and reads mail and the results are compared.
