I am trying to set up my environment variables so that I can compile from my command line. To give a clear explanation of what the situation is my javac command is throwing 25 errors for a HelloServlet.java file. I believe the root cause of this is because my CLASSPATH variable is not set up correctly. First I have spent so much time trying to get JSP's up and running as well as Servlets I am not certain what is running what as far the J2SE and JavaEE versions are concerned. But Lo' and behold my Net Beans is finally running Servlets I can type local host/Servlets/MyServlet in my browser and vwaa lahhh there it is.. still having some problems though that you might be able to help me with. I am also reading an old Core Servlets book and might have to do with some of the errors and problems I am having as it refers to frameworks that are no longer distributed at Oracle.
Also my Apache Tomcat (Thank God) finally remedied the problem I was having with glassfish. Glassfish kept throwing errors when I attempted to run it. Like a mile long list of them. I had to install an Apache Tomcat and grab a a jar file from the glass fish javadb directory derbyclient.ja and have my NetBeans point at it when deploying my Web App... why is this? Is this the Jar file I need to point to when setting my CLASSPATH variable?
First the method process request versus using init and doGet(). My Netbeans is throwing an error that will not go away whenever I remove processRequest() or add init(),doGet() ect... I have to be careful how I make methods and cannot remove processRequest() in order to fix the error... why is this?
Also I cannot compile files that import servlet type classes. What is the name of the Jar file that I need to point to?
I cannot tell you for sure as to exactly which version of J2EE is at work here as the framework comes bundled with servers and IDE's and I have toiled with this night and day for a long time now. Please make this crystal clear if you can.