Solved. Had to deploy on Tomcat 9 and not Tomcat 10.
On Wednesday, April 9, 2025 at 8:54:23 PM UTC+10 bryan wrote:
> I think the problem might be Tomcat expecting jakarta namespace not javax
> namespace.
>
> 09-Apr-2025 20:36:56.025 FINE [main]
> org.apache.catalina.util.Introspection.loadClass Failed to load class
> [com.webbtide.test.server.GreetingServiceImpl]
> java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
>
> In Tomcat lib directory:
> /opt/java/bin/jar -tvf servlet-api.jar | grep HttpServlet
> 223 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$1.class
> 1235 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$NoBodyAsyncContextListener.class
> 3491 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$NoBodyOutputStream.class
> 4233 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$NoBodyPrintWriter.class
> 4058 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$NoBodyResponse.class
> 1860 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServlet$TomcatHack.class
> 9778 Fri Feb 01 00:00:00 AEST 1980 jakarta/servlet/http/HttpServlet.class
> 297 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServletMapping.class
> 1052 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServletRequest$1.class
> 3086 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServletRequest.class
> 5783 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServletRequestWrapper.class
> 3708 Fri Feb 01 00:00:00 AEST 1980
> jakarta/servlet/http/HttpServletResponse.class
>
> Not sure what to do ?
> On Wednesday, April 9, 2025 at 7:12:16 PM UTC+10 bryan wrote:
>
>> Using Eclipse 2025-03 (4.35.0)
>> OpenJDK 21.0.2
>>
>> I created a GWT Web Application and deployed it on Tomcat 10.0.22,
>> listening on port 8081.
>>
>> Tomcat is deployed behind nginx. The relevant lines of the conf are:
>> location / {
>> expires -1;
>>
>> add_header Cache-Control "no-store, no-cache, must-revalidate";
>>
>> proxy_pass http://127.0.0.1:8081;
>> proxy_set_header Upgrade $http_upgrade;
>> proxy_set_header Connection "upgrade";
>> proxy_set_header X-Real-IP $remote_addr;
>>
>> proxy_set_header Host $host;
>> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
>> }
>>
>> When I point myself are https:[my weburl]/ the GWT Web Application
>> Starter Project loads. When I click on the "Send" button the browser debug
>> console says:
>> POST https://[my web url]/gwttest/greet 500 (Internal Server Error)
>>
>> Any help greatly appreciated.
>>
>>
>
--
You received this message because you are subscribed to the Google Groups "GWT
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/google-web-toolkit/1cc066e1-8909-4d7e-a439-a9c7f84df34an%40googlegroups.com.