-
Notifications
You must be signed in to change notification settings - Fork 874
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
Support for transformation from jakartaee8 to jakartaee10 applications #5847
Support for transformation from jakartaee8 to jakartaee10 applications #5847
Conversation
@mbien Can you help to start again the validations? |
@mbien please send another test for the validations |
@breakponchito you can run commit validation locally, build it first then simply run going to start it later since we have 7 test runs in parallel running atm and I don't want to DoS the shared apache infrastructure. |
...ansformer/src/org/netbeans/modules/fish/payara/jakarta/transformer/TransformerConstants.java
Outdated
Show resolved
Hide resolved
@mbien Do you know what is causing the following error on the pipeline? I tried to add both properties but this said that both are not reachable for the Plugin Manager, and this is happening for the following JDK's: 11, 17 and 21. Please let me know if you have any suggestion |
@breakponchito it's complaining that neither of those properties are Now we don't need to special case these for JDK 8, should consider a different way to enable these too, but I guess should be done together. |
@mbien @neilcsmith-net Do you know how to debug unit tests from local environment? or Do you have some references to see how to debug the commit-validations tests? |
@mbien @neilcsmith-net
|
@mbien I merged last changes from master branch, could you help me to send the pipeline validations? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, @breakponchito , thank you for this contribution. I'm looking forward to start using it when it's released!
...ansformer/src/org/netbeans/modules/fish/payara/jakarta/transformer/TransformerConstants.java
Outdated
Show resolved
Hide resolved
I added some commits, could you help me to send the pipeline validations? |
@OndroMih @jGauravGupta please let me know if any other comment about this PR. I'm waiting for approvals |
Hi @breakponchito, I have reviewed the code and it looks good to me. There are two improvements that I suggest:
|
already done, please review |
@mbien I added a new commit, Could you help me to send the pipeline validations? |
@breakponchito I am going to add a commit - I hope this is ok. I wanted to add review comments but it is faster to code it right away since some of it is UI.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not 100% convinced that a new project wizard is the best vehicle to integrate this kind of feature which is essentially code refactoring.
It is working but it feels a bit like it is sidelining all other IDE features, e.g diffs before changes are applied etc.
I am glad that it is here though since it certainly could be useful for some.
...rmer/src/org/netbeans/modules/fish/payara/jakarta/transformer/TransformerWizardIterator.java
Outdated
Show resolved
Hide resolved
thank you for your fixes |
Regarding the place of this, at the beginning we though to add the functionality to the pop up menus when selecting folder or file, but after reviewing we though to add it on the project wizard. If you have an idea where to add it to be a better place, please let me know and I can change it |
There are several places where code transformation could be integrated. It could be triggered by an in-editor code hint/inspection. But this could be still extended later if the feature remains popular. Not everything has to be solved by the same PR. |
The suggestion from @OndroMih sound sane, it would also imply, that not all suggested modes would work (at least I'm under the impression, that the hints engine always works in-place). Locating this in the "New project" dialog is odd and the last place I would look for modifying an existing project. If we want to get this in fast and now, then I suggest to make this an entry in the "Tools" menu. From a UX perspective though, I would prefer integration through the hint interface, as this nicely aligns with general cleanup and platform updates. |
@matthiasblaesing Honestly, tools menu isn't much better IMO - its also not a place where I look for refactoring tasks. The implementation right now is separate from everything and not intrusive, I would be ok with integrating it as experimental feature, it seems like there is interest to properly integrate it at some point in future. (But my initial reaction was similar to yours) The module has no public API (I removed that export), so we could remove it in future again if there is no interest to improve it. It could be extracted to a plugin (plugin portal) for example in that case. This could be even delivered as maven hint, since it could directly annotate the dependency in the pom, replace it, then run the transformation. We could of course also move this to NB 20, but the feature does work - maybe someone will find it useful in its early stage. |
I'm agree with you guys that this tool can be improved, as @mbien said probably we can accept, merge and go with this as an experimental feature, then I will work to improve it for the next release. What do you think? |
Co-authored-by: Michael Bien <mbien42@gmail.com>
I have a squashed and rebased version of this PR here: https://github.com/mbien/netbeans/tree/FISH-6771-support-transformation-jakartaee8-to-jakartaee10 (I removed the FISH-6771 from the msg since I believe that this is an internal issue tracker) If everyone is ok with this I can force push into this PR and merge on Sunday evening. (we don't use gh ui for squashing since it caused issues before with noreply mails in author headers etc) |
I'd be happy to see this in NetBeans 19 and improved in a future release, as needed. Nice work! This will be very nice indeed for helping to further Jakarta EE 10 adoption. |
68f7fe4
to
8af5722
Compare
@breakponchito congrats to your first contribution and thanks for your patience -> merging |
@mbien @jGauravGupta @OndroMih @matthiasblaesing thank you guys for your help an patience |
This PR adds support to transform applications from Jakarta EE 8 to Jakarta 10. When you have an older application and you want to transform to the Jakarta EE 10, then you can use the new option from the new project wizard to make the transformation. This is useful for developers that want to migrate older applications to the new Jakarta 10.
Case 1: file to a different folder
filetofolder.mp4
Case 2: folder to a different folder
foldertofolder.mp4
Case 3: file on the same location (override)
filetosamelocation.mp4
Case 4: folder on the same location (override)
folderonsamelocation.mp4
^Add meaningful description above
By opening a pull request you confirm that, unless explicitly stated otherwise, the changes -
Please make sure (eg.
git log
) that all commits have a valid name and email address for you in the Author field.If you're a first time contributor, see the Contributing guidelines for more information.
If you're a committer, please label the PR before pressing "Create pull request" so that the right test jobs can run.