Please check that your tomcat is running correctly on your server.
Try this cmd and check if port 8080 is listening on 127.0.0.1:8080 :
netstat -ntplu
I think the problem is not on nginx but on tomcat check the logs.