I made web project, that based on Tomcat and Nginx in front of him. Had to work hard to make it work without errors. However, when I added ssl to nginx. Stopped working
Briefly, nginx detects if connection is alive with backend application and detection may not work correct in case of SSL, as described here
http://mailman.nginx.org/pipermail/nginx/2013-March/038120.html