Migrate to jakarta package namespace ( and commons-email2 )#133
Migrate to jakarta package namespace ( and commons-email2 )#133reda-alaoui wants to merge 2 commits intoapache:masterfrom
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #133 +/- ##
============================================
- Coverage 65.90% 65.52% -0.38%
+ Complexity 305 303 -2
============================================
Files 18 18
Lines 1053 1053
Branches 138 138
============================================
- Hits 694 690 -4
- Misses 280 283 +3
- Partials 79 80 +1 ☔ View full report in Codecov by Sentry. |
89dd841 to
16142f9
Compare
|
So are there any plans to merge this pull request or is this library going to stay on outdated Java EE forever? |
|
@MaximeEsnol |
16142f9 to
f034c22
Compare
|
commons-email is a fairly small library, it could be possible to support both JEE namespaces with the same jar. New classes using the jakarta namespace would go into a different package, for example org.apache.commons.email.jakarta. |
|
Might be better to release as a separate jar. But I agree it is not appropriate to drop support for javax.mail just yet. |
|
Or indeed if the only change is the package name, then one could presumably use Maven Shade to generate a parallel jar |
|
Are there any rough plans for timing on this? Understand that this change must be very deliberate per @garydgregory, but with the forced migration to Spring Boot 3.0 later this year(based on 2.7 end of life) which has a Jakarta EE 9 baseline - it seems like applications will be forced off of this library. |
The use of `jakarta.mail` and its predecessor `javax.mail` cannot be mixed. As GreenMail 2.0 migrated to `jakarta.mail` [1] but `commons-email` does not support `jakarta.mail` yet [2], simply remove `commons-email` in favor of using `jakarta.mail` directly to resolve the conflict. For simplicity, this also slightly changes the behavior: In case of a plain text email, the email is now sent as single-part instead of multi-part. [1]: https://github.com/greenmail-mail-test/greenmail/releases/tag/release-2.0.0 [2]: apache/commons-email#133 Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
The use of `jakarta.mail` and its predecessor `javax.mail` cannot be mixed. As GreenMail 2.0 migrated to `jakarta.mail` [1] but `commons-email` does not support `jakarta.mail` yet [2], simply remove `commons-email` in favor of using `jakarta.mail` directly to resolve the conflict. For simplicity, this also slightly changes the behavior: In case of a plain-text email, the email is now sent as single-part instead of multi-part. [1]: https://github.com/greenmail-mail-test/greenmail/releases/tag/release-2.0.0 [2]: apache/commons-email#133 Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
The use of `jakarta.mail` and its predecessor `javax.mail` cannot be mixed. As GreenMail 2.0 migrated to `jakarta.mail` [1] but `commons-email` does not support `jakarta.mail` yet [2], simply remove `commons-email` in favor of using `jakarta.mail` directly to resolve the conflict. For simplicity, this also slightly changes the behavior: In case of a plain-text email, the email is now sent as single-part instead of multi-part. [1]: https://github.com/greenmail-mail-test/greenmail/releases/tag/release-2.0.0 [2]: apache/commons-email#133 Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
The use of `jakarta.mail` and its predecessor `javax.mail` cannot be mixed. As GreenMail 2.0 migrated to `jakarta.mail` [1] but `commons-email` does not support `jakarta.mail` yet [2], simply remove `commons-email` in favor of using `jakarta.mail` directly to resolve the conflict. For simplicity, this also slightly changes the behavior: In case of a plain-text email, the email is now sent as single-part instead of multi-part. [1]: https://github.com/greenmail-mail-test/greenmail/releases/tag/release-2.0.0 [2]: apache/commons-email#133 Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
The use of `jakarta.mail` and its predecessor `javax.mail` cannot be mixed. As GreenMail 2.0 migrated to `jakarta.mail` [1] but `commons-email` does not support `jakarta.mail` yet [2], simply remove `commons-email` in favor of using `jakarta.mail` directly to resolve the conflict. For simplicity, this also slightly changes the behavior: In case of a plain-text email, the email is now sent as single-part instead of multi-part. [1]: https://github.com/greenmail-mail-test/greenmail/releases/tag/release-2.0.0 [2]: apache/commons-email#133 Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
|
which commons-email version support jakarta? |
|
looking forward to this one, can i somehow support you in getting this pr done? |
|
FTR, -1 on this PR. I propose we take the same approach as Apache Commons FileUpload (see that master branch). |
|
+1 for this PR :) |
|
+1 for this PR too. We need this as it's blocking us from upgrading to Jetty 11. How does this get progressed? |
|
The next release will support Jakarta but not this way. See my previous comment. I should be able to work on this within a week or two. |
|
Hey! week or two already passed! Any news to support jakarta API? |
|
Sorry Jan, we've moved our system to spring-mail quicker.
…On Tue, Oct 10, 2023 at 3:41 PM Jan Cizmar ***@***.***> wrote:
Hey! week or two already passed? Any news to support jakarta API?
—
Reply to this email directly, view it on GitHub
<#133 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGJRTFEHGSYCRWMVX5I2KDX6VNDPAVCNFSM6AAAAAAUCTMGGCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJVGU4DINZXGA>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Hey! We're all volunteers with different priorities than yours ;-) |
|
Understood. Thanks for your work! ✅ Is there any workaround I can get attachments from |
|
@garydgregory as i said 2 prs earlier, i'm happy to help. and this is still blocking me in a few projects to upgrade to spring 3.x :/ so is there any update? how can i help? |
|
Hello @Loki-Afro, This is my current plan:
I need help with (1), please feel free to contribute a PR. |
|
@garydgregory here you go #186 |
|
@garydgregory let me know if i can assist further, maybe with 4.? |
|
I don't want to mix up the steps, especially if something goes wrong before 1.6, I don't want to deal with patching branches. If all goes well, I'll create a release candidate for 1.6.0 this Friday or Saturday. |
|
EDIT: Nevermind, found the answer here : https://issues.apache.org/jira/browse/EMAIL-203 Hello, Just to be sure to understand. Is version 1.6.0 compatible with Jakarta EE 9+ now ? |
|
That confused me too. Despite its name, jakarta.mail 1.6.7 has |
This PR fully migrates the project to jakarta package namespace .
It also introduces
commons-email2as asked by #80 (comment)Please note I removed
japicmpfrom thedefaultGoalin absence of a better known solution. Otherwise,japicmpfails the build for breaking changes.