Re: [j-t-c] OS poll = [j-t-c] webserver poll

2001-06-13 Thread Ansgar W. Konermann

GOMEZ Henri wrote:

 Now which webservers are you using :

Apache 1.3 on Linux + Solaris 8

-- 
Best regards,

Ansgar W. Konermann
eMail: [EMAIL PROTECTED]

--- Hello, I am a message footer. -



Re: [j-t-c] OS poll

2001-06-11 Thread Ansgar W. Konermann

GOMEZ Henri wrote:

 I: Redhat 6.2 / 7.1

Slackware 7.1 plus several tarballs

-- 
Best regards,

Ansgar W. Konermann
eMail: [EMAIL PROTECTED]

--- Hello, I am a message footer. -



Re: Proposal for implementation of lookup of localized web-resources

2001-03-15 Thread Ansgar W. Konermann

Mike Braden wrote:

 Of course, it also means that you would have to duplicate
 anything that is not lang dependent, such as images.

I typically use symbolic links to work around duplication.

-- 
Best regards,

Ansgar W. Konermann
eMail: [EMAIL PROTECTED]

--- Hello, I am a message footer. ---



Re: GenericServlet.getServletConfig buggy?

2001-02-22 Thread Ansgar W. Konermann

"Craig R. McClanahan" wrote:

 but failing to call:
 
 super.init(config);

THX, that's been the problem.

-- 
Best regards,

Ansgar W. Konermann
eMail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




GenericServlet.getServletConfig buggy?

2001-02-22 Thread Ansgar W. Konermann

Hi all,

I (still) have a problem with the context of a servlet.

Within a class derived from HttpServlet (nop.Receiver), this
is my doGet method:

-
public void doGet(HttpServletRequest rq, HttpServletResponse rs) 
throws IOException, ServletException 
{
rs.setBufferSize(0);
rs.setContentType("text/html");
PrintWriter out = rs.getWriter();
makeHead(out);
out.println("PChat Receiver/P\n");
rs.flushBuffer();

ServletConfig myConfig = getServletConfig();
out.println("myConfig == " + myConfig + "br"); // debug output
theContext = getServletContext();
out.println("theContext == " + theContext + "br"); // debug output

// ...

-

It gives me the following output when I call the servlet:

-

Chat Receiver

myConfig == null

Error: 500

Location: /trial/servlet/Receiver

Internal Servlet Error:

java.lang.NullPointerException
at javax.servlet.GenericServlet.getServletContext(GenericServlet.java:205)
at nop.Receiver.doGet(Receiver.java:59)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at 
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at 
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)

-

Please note that myConfig == null and that the following call to 
getServletContext fails with a NullPtrXcpt. From the source code
of GenericServlet I can see that getServletContext is merely
getServletConfig().getServletContext().

According to the Servlet API, Servlet.getServletConfig(),

"Implementations of this interface are responsible for storing
the ServletConfig object so that this method can return it.
The GenericServlet class, which implements this interface,
already does this."

To me, this looks like the implementation I am using is *not*
storing the ServletConfig (which was previously passed to init),
since it returns null. Therefore, GenericServlet.getServletContext
must fail (since it relies on getServletConfig).

Is this a bug or am I just too blind to see my mistake?
Any help would be greatly apreciated.

(Using Tomcat Web Server/3.2.1 (JSP 1.1; Servlet 2.2; Java 1.3.0;
Linux 2.2.16 i386; java.vendor=Sun Microsystems Inc.)

--

Best regards,

Ansgar W. Konermann

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]