Transform Source Code to Jakarta EE 10
VSCode’s Payara Tools allow users to automatically convert the source code of Java/Jakarta EE 8 applications to Jakarta EE 10.
Transform a Single File
To transform a single file, select the file, right-click on it and select the Transform to Jakarta EE 10 option:
Proceed to select the destination folder of the transformed file:
Finally you can check the output of the transformation process using the Output tab:
To verify that the resulting file is valid you’ll have to open it using either VSCode or a different editor.
Transform a Single File in the same Location
It is possible to save the transformed file in the same location where the original resides.
To do this, select the same location folder when inputting the destination folder:
Once the file has been transformed, it will override the current file in the IDE:
Transform all files in a Folder
To transform all source code files located in a folder, select the folder, right click and select the Transform to Jakarta EE 10 option.
Proceed to select the destination folder of the transformed files:
Finally you can check the output of the transformation process using the Output tab:
The IDE will also show a dialog with additional recommendations to configure the source code’s project POM configuration. These configuration changes will have to be done manually if required. |
To verify that the resulting files in the new folder are valid, open it from within the IDE.
Transform all files in a Folder in the same Location
It is possible to save all transformed files in the same location where the originals reside, effectively overriding them.
To do this, select the same location folder when inputting the destination folder:
Once the contents of the folder have been transformed, the new files will override the current ones in the IDE: