GIT Repository URL
https://github.com/ChandraKodam5/jaka...
References
PART-2
• PART-2 : Examples by using java 16 tomcat ...
PART-1
• PART-1 : install java 16 tomcat 10 maven 3...
PART-1 : install java 16 tomcat 10 maven 3.8.1 in windows | install java 16 tomcat 10 maven 3.8.1
Installing Java related software's
Downloading and installing Java 16 software (Java Development Kit – 16)
Downloading and installing Tomcat 10 software
Downloading and installing Maven 3.8.1 software
Setting the Path variables
Writing and executing the Servlet 4.0 and Jakarta 5.0 programs
Writing and executing the Spring 5 programs
Issues with Tomcat 10 or Issues because of move from Java EE to Jakarta EE
NOTE : I am doing this on Windows 10 – 64 Bit Operating System. Please consider
this point while doing on your PC.
In case, your operating system is Ubuntu 20 – 64 Bit then you have to download
Ubuntu related software's.
Download and install JDK 16
● Open the browser
● Type download jdk 16 → Open Oracle official website → Click on download JDK 16
● Double click on downloaded JDK exe file → Click on next → next → Finish
● Take the jdk installation folder
● Go to,
– Type Env in the search bar → Click on Edit the system environment variables
– Click on Environment variables → Click on New... under System variables
– Enter JAVA_HOME as Variable name and JDK home directory as Variable
value and click on Ok → click on Ok → click on Ok
– Click on Environment variables again→ Select Path → Click on Edit...
– Click on New → Add %JAVA_HOME% \bin → click on Ok → click on Ok →
click on Ok
Download and install Apache Tomcat 10
● Open the browser →
● Type download Apache Tomcat 10 → Open Apache official website
● Click on download on Tomcat 10
● Double click on downloaded file → Click on next → next → Finish
● Take the Tomcat installation folder
● Go to,
– Type Env in the search bar → Click on Edit the system environment variables
– Click on Environment variables → Click on New... under System variables
– Enter TOMCAT_HOME as Variable name and Tomcat home directory as
Variable value and click on Ok → click on Ok → click on Ok
– Click on Environment variables again→ Select Path → Click on Edit...
– Click on New → Add %TOMCAT_HOME% \bin → and click on Ok → click on
Ok → click on Ok
Download and install Apache Maven 3.8.1
● Open the browser
● Type download Apache Maven 3.8.1 → Open Apache official website
● Click on download on Maven 3.8.1 → Extract Maven 3.8.1 ZIP File
● Go to,
– Type Env in the search bar → Click on Edit the system environment variables
– Click on Environment variables → Click on New... under System variables
– Enter MAVEN_HOME as Variable name and Extracted folder of Maven home
directory as Variable value and click on Ok → click on Ok → click on Ok
– Click on Environment variables again→ Select Path → Click on Edit...
– Click on New → Add %MAVEN_HOME% \bin → click on Ok → click on Ok →
click on Ok
NOTE : Set the path for M2_HOME as well, like MAVEN_HOME
Download the source code from GIT
Please download the source code from below GIT repository URL :
Enter this URL on browser - https://github.com/ChandraKodam5/jaka...
Click on Code Drop-down → Click on Download ZIP → Open eclipse IDE
Goto File → Import → Existing projects into workspace → Next → click on checkbox
(select archive file) → click on Browse → choose the downloaded
Spring5MVCExampleWithAnnotationConfig,Servlet4URLRewriting and JakartaServletEE5Project ZIP files.
OR
Type the below command in git bash
$ git clone https://github.com/ChandraKodam5/jaka...
Goto File → Import → Existing projects into workspace → Next → click on checkbox
(select archive file) → click on Browse → choose the downloaded
JakartaServletEE5Project, Servlet4URLRewriting and Spring5MVCExampleWithAnnotationConfig ZIP file.
Issues with Tomcat 10 & Spring 5
Spring MVC 5 does not run on Tomcat 10 because of the package renaming from
javax.* to jakarta.*.
After further research, I was able to find the answer to my question. Spring MVC 5
does NOT currently work on Tomcat 10. This is because Tomcat 10 is based on Jakarta EE 9
where package names for APIs have changed from javax.* to jakarta.*.
But, Spring has not changed the packages from javax.* to jakarta.* till the version of
Spring 5.3.7.
Please click the below for further confirmation,
https://stackoverflow.com/questions/6...
Thank you