Impacts of exposing the boot classpath in OSGI | Community
Skip to main content
Level 3
Oct 24, 2017 6:25 PM UTC
Solved

Impacts of exposing the boot classpath in OSGI

What can be the impacts of adding the following property in sling.properties to resolver class linkage error for the javax.activation errors?

(We have seen that adding this property is affecing sending HTMLemails)

org.osgi.framework.system.packages.extra=javax.activation;version\="1.1.1".

Is it advisable to use this fix in AEM 6.1 and above?

Thanks in advance.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
anushap40132887Accepted solution
Level 3
Oct 26, 2017 2:27 PM UTC

We are using the “HtmlEmail -Apache Commons Email API” for sending emails and exception occurred in the method for setting mail content (email.setMsg(message); ). We were able to resolve the issue by changing the method as email.setContent(message, "text/html");

We have modified the sling.properties file in order to fix the linkage error that occurred while invoking webservice from AEM(https://forums.adobe.com/thread/2336233)

5 replies

smacdonald2008
Level 10
Oct 26, 2017 3:29 PM UTC

Thanks for posting the fix.

Translate
anushap40132887AuthorAccepted solution
Level 3
Oct 26, 2017 2:27 PM UTC

We are using the “HtmlEmail -Apache Commons Email API” for sending emails and exception occurred in the method for setting mail content (email.setMsg(message); ). We were able to resolve the issue by changing the method as email.setContent(message, "text/html");

We have modified the sling.properties file in order to fix the linkage error that occurred while invoking webservice from AEM(https://forums.adobe.com/thread/2336233)

Translate
smacdonald2008
Level 10
Oct 25, 2017 7:48 PM UTC

So you are writing an AEM OSGi bundle that you want to use to send emails. This should be straightforward without getting this error or modifying the sling props file. WHat API are you using to send email messages?

Translate
Level 3
Oct 25, 2017 6:23 AM UTC

Hi Scott, Thanks for your reply. Yes, we are using maven and AEM dependencies.

Translate
smacdonald2008
Level 10
Oct 24, 2017 9:04 PM UTC

I have never seen an issue like this before - how are you building you AEM project? Are you using Maven Archetype and AEM dependencies?

Translate