All of JDK,
JAVA_HOME
and CLASSPATH
are set correctly.But as soon as I deploy a Hello World web app, this is what Glassfish returned
org.apache.jasper.JasperException: PWC6033: Unable to compile class for JSP PWC1406: Servlet.service() for servlet ... threw exception java.lang.NullPointerException at org.apache.jasper.compiler.Jsr199JavaCompiler.compile
There is direct solution to it. Update
<glassfish_home>/domains/<DOMAIN_NAME>/config/domain.xml
from
<java-config classpath-suffix="" ... java-home="${com.sun.aas.javaRoot}" java-options="-g" ...></java-config>
to
<java-config classpath-suffix="" ... java-home="C:/Program Files/Java/jdk1.6.0_14" java-options="-g" ...></java-config>
what I did is I hard coded
JDK_HOME
(C:/Program Files/Java/jdk1.6.0_14) in the XML .