-
-
Notifications
You must be signed in to change notification settings - Fork 271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement: Clarify dependency on Jakarta Activation: DataSources no longer work on Java 9+ #225
Comments
Ok, thanks for the forensic work! I'll check the size of the activation library and probably lock it in. Won't be for a few weeks though, currently away from home for two weeks. |
Ah. I haven't yet worked out how to use Maven dependencies. I just add libraries to my Eclipse build path that the docs request, plus what prevents compile errors. I guess this is one missing dependency that instead manifests as a run-time hang on Java ≥ 9. Perhaps your docs can mention this stealth dependency. |
Well, you made me think now. It comes as a transitive dependency (stealth dependency as you say), but it is also a direct dependency of Simple Java Mail, not just Jakarta JavaMail. That means I should include it as such in the pom.xml and NOTICE.txt. Would that be enough or are you looking at specific documentation for Simple Java Mail's dependencies? |
Sorry, I'm not familiar with Java's dependency-detection mechanisms. Explicit dependency documentation wouldn't be needed if the missing dependency generated a compilation error that suggested what's missing — though explicit docs would help in this case where a dependency is moving from a Java standard component to a third-party library. |
…ava Mail depends on it explicitly besides Jakarta JavaMail
That's not possible with jars unfortunately (with modules this works much better).
I'll make sure to mention it somewhere. For now I've included it in both the pom.xml and NOTICE.txt, which is not related to Maven. |
I've updated the documentation, but it will only show up once 6.0.0 is released. |
5.4.0 released. |
javax.activation
, which createsDataSource
objects for attachments, is deprecated in Java 9+. Without the interim fix of adding thejavax.activation
module to the JVM start, the JVM silently hangs looking for it. It was hard tracking down the reason why after moving from Java 8 to 11 my app hung when one of my classes was loaded.The docs should be updated to warn that
withAttachment
using ajavax.activation
DataSource
will fail on Java ≥ 9, and that either byte arrays should be used exclusively, or Jakarta Activation used instead.The text was updated successfully, but these errors were encountered: