Hello all!

My question has to do with reading remote files.  I am trying to build a
servlet solution that reads files from various servers and modifies them a
little (for accessiblity issues) and sends them back to the user.  I have
been able to do this with local files, as well as with remote files when an
*IP is attempted to be read* - when I give a hostname such as
java.apache.org it throws a HostNotFoundException!  Now, seeing this, I
tried to implement something like

InetAddress tempip = InetAddress.getByName("java.apache.org");

to get back the ip address.  The above line works when I run it in a plain
Java program, command line.  but, when I run it within my servlet, in an
attempt to get the IP address, it ALSO THROWS a HostNotFoundException!! So
the very method I implemented to fix a bug is actually cauing the same bug.
  I am attempting to run this servlet on, of course, Apache 1.3.6/Jserv
1.0b1  - and I figured it must have something to do with the server
configuration because when I run the line as a normal Java program is does
work.  Can anyone help me out here?  Is there some flag or command that I
need to include in the Apache configuration to allow DNS lookup, etc?  My
program needs to work on form input and there is no way people are going to
remember the IP addresses of any servers - they are just going to put in
"http://java.apache.org/".

Thanks in advance,


Jon Reinberg
[EMAIL PROTECTED]


----------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html/>
Problems?:           [EMAIL PROTECTED]

Reply via email to