"org.apache.commons.mail.EmailException: Invalid message supplied" 使用 ACS 公共电子邮件服务发送电子邮件通知时

"org.apache.commons.mail.EmailException: Invalid message supplied" while sending email notification using ACS commons email service

我正在尝试在工作流程中使用 ACS 公共电子邮件服务发送电子邮件通知,但出现错误 -

*ERROR* [JobHandler: /var/workflow/instances/server0/2020-04-17_3/workflow_59:/content/path/to/page] com.adobe.acs.commons.email.impl.EmailServiceImpl Error sending email to [ user@mail.com ]
org.apache.commons.mail.EmailException: Invalid message supplied
    at org.apache.commons.mail.HtmlEmail.setMsg(HtmlEmail.java:177) [org.apache.commons.email:1.5.0]
    at com.day.cq.commons.mail.MailTemplate.getEmail(MailTemplate.java:181) [com.day.cq.cq-commons:5.12.16]
    at com.adobe.acs.commons.email.impl.EmailServiceImpl.getEmail(EmailServiceImpl.java:234) [com.adobe.acs.acs-aem-commons-bundle:4.3.0]
    at com.adobe.acs.commons.email.impl.EmailServiceImpl.sendEmail(EmailServiceImpl.java:152) [com.adobe.acs.acs-aem-commons-bundle:4.3.0]
    at com.adobe.acs.commons.email.impl.EmailServiceImpl.sendEmail(EmailServiceImpl.java:125) [com.adobe.acs.acs-aem-commons-bundle:4.3.0]
    at <redacted>
    at <redacted>
    at com.adobe.granite.workflow.core.advance.DynamicParticipantNodeHandler.getParticipant(DynamicParticipantNodeHandler.java:206) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.advance.ParticipantNodeHandler.doTransition(ParticipantNodeHandler.java:185) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.advance.ParticipantNodeHandler.doTransition(ParticipantNodeHandler.java:134) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.advance.OrSplitNodeHandler.doTransition(OrSplitNodeHandler.java:126) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.advance.AdvanceUtil.transitionFrom(AdvanceUtil.java:126) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.WorkflowSessionImpl.completeInternal(WorkflowSessionImpl.java:1050) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.WorkflowSessionImpl.complete(WorkflowSessionImpl.java:1020) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at <redacted>
    at com.adobe.granite.workflow.core.job.HandlerBase.executeProcess(HandlerBase.java:195) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at com.adobe.granite.workflow.core.job.JobHandler.process(JobHandler.java:260) [com.adobe.granite.workflow.core:2.0.240.CQ650-B0002]
    at org.apache.sling.event.impl.jobs.JobConsumerManager$JobConsumerWrapper.process(JobConsumerManager.java:502) [org.apache.sling.event:4.2.12]
    at org.apache.sling.event.impl.jobs.queues.JobQueueImpl.startJob(JobQueueImpl.java:293) [org.apache.sling.event:4.2.12]
    at org.apache.sling.event.impl.jobs.queues.JobQueueImpl.access0(JobQueueImpl.java:60) [org.apache.sling.event:4.2.12]
    at org.apache.sling.event.impl.jobs.queues.JobQueueImpl.run(JobQueueImpl.java:229) [org.apache.sling.event:4.2.12]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)

我关注了https://adobe-consulting-services.github.io/acs-aem-commons/features/e-mail/email-api/index.html

附加 html 我在我的模板中使用过(我也尝试过使用普通文本的 .txt 文件)-

<html>
   <head></head>
   <body>
      -----------------------------------------<br/>
      Time :  ${time} <br/>
      Step : Approve Content <br/>
      Approver : userName <br/>
      Workflow :  wftitle<br/>
      -----------------------------------------<br/><br/>
      wftitle  workflow has been assigned to you. Please review the content: <a href=' url'>                            payloadTitle </a><br/><br/>----------------------------------------<br/>
      View the overview in your  <a href='test'>AEM Inbox</a><br/>
      -----------------------------------------<br/> This is an automatically generated message. Please do        not reply.
   </body>
</html>

请让我知道我在这里遗漏了什么。

提前致谢!

来自@Jens-

您似乎遗漏了电子邮件 headers:_ From_,主题后跟一个空行。还请确保模板的文件以“.html”结尾,如文档中所述。请务必仔细阅读您链接的文档