*
The moose likes Servlets and the fly likes How to invoke a servlet running on IIS server from a java application?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "How to invoke a servlet running on IIS server from a java application?? " Watch "How to invoke a servlet running on IIS server from a java application?? " New topic
Author

How to invoke a servlet running on IIS server from a java application??

Sajee Joseph
Ranch Hand

Joined: Jan 17, 2001
Posts: 200
Hello everybody,
We are developing a Chat kinda application. Both the client and the server programs are written in java. We are running the IIS Server with ServletExec servlet engine.
We have put our servlets in the "Servlets" directory. We are able to invoke this servlet from the browser. But when we try to execute the servlet from our client java application using URL connection, we get the "FileNotFound" exception. Why is this so?... A fragment of the clinet code that makes a connection to the servlet is given below
1 URL url = new URL("http://SomeServer/servlet/MyServlet");
2 URLConnection connection = url.openConnection();
3 connection.connect();
4 in= new BufferedReader( new InputStreamReader(connection.getInputStream()));
The exception is got at the 4th line. Ie the Exception is thrown when we try to read the input stream. Another thing is that this servlet worked fine when we used Java WebServer instead of IIS server...
Pls help me out
....Regards
......Sajee Joseph
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to invoke a servlet running on IIS server from a java application??
 
Similar Threads
send session from applet to servlet
The browser asks for authentication when using Apache Tomcat Connector from another domain.
Multiple URLConnections
send session from applet to servlet
IBM HttpServer and websphere Appserver