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 ?
Solved! Go to Solution.
Views
Replies
Total Likes
Hi
The restarting of Bundle results in:
1. Changes to the individual configuration properties will take effect upon restart.
2. Restart the entire OSGi helps resolve/refresh the installed bundles, their bundle contexts and dependencies.
Please have a look at OSGI life-cycle: - http://eclipsesource.com/blogs/2013/01/23/how-to-track-lifecycle-changes-of-osgi-bundles/
I hope this will help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes
When you build your project did you find any error in logs? , If you didn't check, can you check this now.
Views
Replies
Total Likes
Yes, AEM may prefer higher version if its available,
To get detail understanding, check this out: http://blog.christianposta.com/osgi/understanding-how-osgi-bundles-get-resolved-part-i/
Views
Replies
Total Likes
Hi
The restarting of Bundle results in:
1. Changes to the individual configuration properties will take effect upon restart.
2. Restart the entire OSGi helps resolve/refresh the installed bundles, their bundle contexts and dependencies.
Please have a look at OSGI life-cycle: - http://eclipsesource.com/blogs/2013/01/23/how-to-track-lifecycle-changes-of-osgi-bundles/
I hope this will help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes
I tailed the error logs during code build. There is no error. Now I saw a strange thing. This issue is occurring only in our UAT environment. I saw that the Day CQ Mail Service Configuration in felix console are of two different versions. I am sure we are using the same AEM 6.0 and Service Pack 2.0 combination in all the environments.
Version in Local , Dev and QA - Day Communique 5 Mailer (com.day.cq.cq-mailer), Version 5.8.12 (No issues)
Version in UAT - Day Communique 5 Mailer (com.day.cq.cq-mailer), Version 5.8.14 (Issue occurring)
Is there any possibility that AEM can auto-update itself with the latest versions ?
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies