SOLVED SMTP class com.sun.mail.handlers.text_html cannot be cast
-
Trying out wlsdm on one of our test servers, first time install. Copied the wlsdm.war to /console-ext and booted weblogic. Found the wlsdm setup wizard and tried to walk through the SMTP setup for email.
Have filled in our server info, names etc (no password required for this email relay).
When I try to test we get the below error. Can you help? This does not look like an actual email issue.
####<Apr 1, 2024, 3:43:19 PM EDT><SEVERE><WLSDM><BEA-000000><class com.sun.mail.handlers.text_html cannot be cast to class javax.activation.DataContentHandler (com.sun.mail.handlers.text_html and javax.activation.DataContentHandler are in unnamed module of loader 'app')
java.lang.ClassCastException: class com.sun.mail.handlers.text_html cannot be cast to class javax.activation.DataContentHandler (com.sun.mail.handlers.text_html and javax.activation.DataContentHandler are in unnamed module of loader 'app') at javax.activation.MailcapCommandMap.getDataContentHandler(MailcapCommandMap.java:601) at javax.activation.MailcapCommandMap.createDataContentHandler(MailcapCommandMap.java:555) at oracle.j2ee.ws.saaj.soap.MessageFactoryImpl$LocalClassloaderMailcapCommandMap.createDataContentHandler(MessageFactoryImpl.java:63) at javax.activation.DataHandler.getDataContentHandler(DataHandler.java:600) at javax.activation.DataHandler.writeTo(DataHandler.java:299) at javax.mail.internet.MimeUtility.getEncoding(MimeUtility.java:340) at javax.mail.internet.MimeBodyPart.updateHeaders(MimeBodyPart.java:1575) at javax.mail.internet.MimeMessage.updateHeaders(MimeMessage.java:2271) at javax.mail.internet.MimeMessage.saveChanges(MimeMessage.java:2231) at javax.mail.Transport.send(Transport.java:123) at com.wlsdm.R.l.send(EmailSender.java:5309) at com.wlsdm.P.J.K(Data.java:11504) at com.wlsdm.P.J.A(Data.java:316) at com.wlsdm.P.J.doGet(Data.java:171) at javax.servlet.http.HttpServlet.service(HttpServlet.java:645) at javax.servlet.http.HttpServlet.service(HttpServlet.java:750) at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:295) at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:260) at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:137) at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:353) at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:25) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:82) at com.wlsdm.P.D.doFilter(RRFilter.java:327) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:82) at com.bea.console.internal.ParamFilter.doFilter(ParamFilter.java:38) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:82) at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:32) at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:82) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3869) at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3832) at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:344) at weblogic.security.service.SecurityManager.runAsForUserCode(SecurityManager.java:197) at weblogic.servlet.provider.WlsSecurityProvider.runAsForUserCode(WlsSecurityProvider.java:203) at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:71) at weblogic.servlet.internal.WebAppServletContext.processSecuredExecute(WebAppServletContext.java:2505) at weblogic.servlet.internal.WebAppServletContext.doSecuredExecute(WebAppServletContext.java:2354) at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2329) at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2307) at weblogic.servlet.internal.ServletRequestImpl.runInternal(ServletRequestImpl.java:1798) at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1752) at weblogic.servlet.provider.ContainerSupportProviderImpl$WlsRequestExecutor.run(ContainerSupportProviderImpl.java:272) at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352) at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337) at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57) at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41) at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:651) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:420) at weblogic.work.ExecuteThread.run(ExecuteThread.java:360) >
-
@jbrinker We have released v4.1.1. Could you please give a try with this version and let us know the result. https://wlsdm.com/download
-
Hello @jbrinker,
I’m Deniz from the WLSDM Team, and I’m here to assist you in finding a solution to the issue you’re experiencing. Firstly, can you share with us the WebLogic and Java versions you are currently using in order to identify the problem?
-
@deniz-bedel-wlsdmteam
Thank you for your help-java 11.0.21 2023-10-17 LTS
Java SE Runtime Environment 18.9 (build 11.0.21+9-LTS-193)
Java HotSpot 64-Bit Server VM 18.9 (build 11.0.21+9-LTS-193, mixed mode)and the latest wlsdm from your website 3.9.2
-
Hello @jbrinker,
Thank you for the information you provided. In the environment list you have provided us with, could you please specify which Java version you were using when experiencing errors in which WebLogic instance? Additionally, could you please provide us with a screenshot of the SMTP configuration you made on WLSDM? Feel free to blur out any sensitive information. To access the Configuration -> WLSDM System Settings page, expand the menu on the left side under the Settings section.
-
java 11.0.21
I have tried it with and without username and password, seems to make no difference. It never makes it our mail relay (I see no connection attempt on the its-est-migr.syr.edu server)
We are currently patching to Java 11.0.22 (not this server yet, but we can try it)
-
@jbrinker Any ideas?
-
@jbrinker said in SMTP class com.sun.mail.handlers.text_html cannot be cast:
java 11.0.21
I have tried it with and without username and password, seems to make no difference. It never makes it our mail relay (I see no connection attempt on the its-est-migr.syr.edu server)
We are currently patching to Java 11.0.22 (not this server yet, but we can try it)
Hi,
As I understand from SS. Could you please switch the displayName and username properties then try it again by using “test email configuration” button.
Sometimes username must be full username.
If you are still going to have issue about sending email; try to setup postfix configuration on your VM amd point VM email as mail server to WLSDM.
Please also let us know the result after switching the values by sending screen captures and logs.
Regards…
-
@jbrinker We have released v4.1.1. Could you please give a try with this version and let us know the result. https://wlsdm.com/download