Day CQ Mail Service Configuration not working
We are using Day CQ Mail Service Configuration to send mails. I have referenced the configuration using the following code in my service impl.
@Reference private MessageGatewayService messageGatewayService; @Reference private MessageGateway<HtmlEmail> messageGateway;We are supplying the configuration values through the config nodes.After the code build , we are able to see the SMTP server values in the Day CQ Mail Service Felix configuration. The issue is that when I am submitting the form to send a mail , it throws a MailingException logging "Invalid Mail Service Configuration". Even though the configuration values are all proper , it still throws the same exception.
To resolve this issue , we went to the corresponding bundle "Day Communique 5 Mailercom.day.cq.cq-mailer" and restarted the bundle. Then the configuration started working and we were able to send emails.
Why do I have to explicitly go and restart the CQ OOTB Bundle to make the configuration work ?