You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by kz <kh...@gmail.com> on 2007/05/09 12:14:27 UTC

problem at port 8001

Hi,

I am working on an application that involves applet-servlet communication.
The problem is that when Tomcat is listening at 8001, then I get an
exception when I do connection.getInputStream() in applet. When I switch to
port 8080, the problem gets solved. Heres the exception:

java.io.FileNotFoundException:
http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
 at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
Source)
 at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
SiteDataLinkAGT.java:303)
 at WES.Agents.SiteDataLinkAGT.establishOfficeSession(SiteDataLinkAGT.java
:283)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
 at java.lang.reflect.Method.invoke(Unknown Source)
 at sun.plugin.javascript.invoke.JSInvoke.invoke(Unknown Source)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
 at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
 at java.lang.reflect.Method.invoke(Unknown Source)
 at sun.plugin.javascript.JSClassLoader.invoke(Unknown Source)
 at sun.plugin.com.MethodDispatcher.invoke(Unknown Source)
 at sun.plugin.com.DispatchImpl.invokeImpl(Unknown Source)
 at sun.plugin.com.DispatchImpl$1.run(Unknown Source)
 at java.security.AccessController.doPrivileged(Native Method)
 at sun.plugin.com.DispatchImpl.invoke(Unknown Source)

What could be different when 8080 port is used and any other is used?
I am using the embedded version of tomcat 5.5.23.

regards,

Khurram

Re: problem at port 8001

Posted by David Delbecq <de...@oma.be>.
There shouldn't be any difference. Use a network scanner (example
wireshark) to sniff connection and check what the request of applet was
and what the response of tomcat is.

I bet your applet is trying to connect to 8001 while tomcat is listening
to 8080

En l'instant précis du 09/05/07 12:14, kz s'exprimait en ces termes:
> Hi,
>
> I am working on an application that involves applet-servlet
> communication.
> The problem is that when Tomcat is listening at 8001, then I get an
> exception when I do connection.getInputStream() in applet. When I
> switch to
> port 8080, the problem gets solved. Heres the exception:
>
> java.io.FileNotFoundException:
> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
> at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
> Source)
> at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
> SiteDataLinkAGT.java:303)
> at WES.Agents.SiteDataLinkAGT.establishOfficeSession(SiteDataLinkAGT.java
> :283)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at sun.plugin.javascript.invoke.JSInvoke.invoke(Unknown Source)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at sun.plugin.javascript.JSClassLoader.invoke(Unknown Source)
> at sun.plugin.com.MethodDispatcher.invoke(Unknown Source)
> at sun.plugin.com.DispatchImpl.invokeImpl(Unknown Source)
> at sun.plugin.com.DispatchImpl$1.run(Unknown Source)
> at java.security.AccessController.doPrivileged(Native Method)
> at sun.plugin.com.DispatchImpl.invoke(Unknown Source)
>
> What could be different when 8080 port is used and any other is used?
> I am using the embedded version of tomcat 5.5.23.
>
> regards,
>
> Khurram
>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: problem at port 8001

Posted by Martin Gainty <mg...@hotmail.com>.
netstat -bv | grep 8001

M--
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.

----- Original Message ----- 
From: "David Delbecq" <de...@oma.be>
To: "Tomcat Users List" <us...@tomcat.apache.org>
Sent: Wednesday, May 09, 2007 7:15 AM
Subject: Re: problem at port 8001


> what's the content of the request and response when on port 8001,
> according to your scanner?
>
> check nothing is else than tomcat is listening on port 8001.
> try the request to
> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO using a
> simple browser instead of applet to see result.
>
> En l'instant précis du 09/05/07 13:05, kz s'exprimait en ces termes:
>> I used a scanner and tomcat is listening on port 8001 and not 8080. The
>> thing is that when I start Tomcat even on 8002 or any other port
>> (other than
>> 8080) and I change the applet also to connect to 8002 then the problem
>> doesn't come. WHy is that? I mean even if I am supposed to get a 404,
>> then I
>> should get that on any port other than 8001 also. The weird thing is that
>> the problem only comes on 8001.
>>
>>
>> On 5/9/07, Tim Funk <fu...@joedog.org> wrote:
>>>
>>> I believe that the HTTPURLCOnnection throws a
>>> java.io.FileNotFoundException in the case where a web server returns a
>>> 404.
>>>
>>> Look at your access logs and request
>>> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO via the
>>> browser and see what happens.
>>>
>>> -Tim
>>>
>>> kz wrote:
>>> > Hi,
>>> >
>>> > I am working on an application that involves applet-servlet
>>> communication.
>>> > The problem is that when Tomcat is listening at 8001, then I get an
>>> > exception when I do connection.getInputStream() in applet. When I
>>> switch
>>> to
>>> > port 8080, the problem gets solved. Heres the exception:
>>> >
>>> > java.io.FileNotFoundException:
>>> > http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
>>> > at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
>>> > Source)
>>> > at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
>>> > SiteDataLinkAGT.java:303)
>>> > at WES.Agents.SiteDataLinkAGT.establishOfficeSession(
>>> SiteDataLinkAGT.java
>>> > :283)
>>>
>>> ---------------------------------------------------------------------
>>> To start a new topic, e-mail: users@tomcat.apache.org
>>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>>> For additional commands, e-mail: users-help@tomcat.apache.org
>>>
>>>
>>
>
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
> 


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: problem at port 8001

Posted by David Delbecq <de...@oma.be>.
what's the content of the request and response when on port 8001,
according to your scanner?

check nothing is else than tomcat is listening on port 8001.
try the request to
http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO using a
simple browser instead of applet to see result.

En l'instant précis du 09/05/07 13:05, kz s'exprimait en ces termes:
> I used a scanner and tomcat is listening on port 8001 and not 8080. The
> thing is that when I start Tomcat even on 8002 or any other port
> (other than
> 8080) and I change the applet also to connect to 8002 then the problem
> doesn't come. WHy is that? I mean even if I am supposed to get a 404,
> then I
> should get that on any port other than 8001 also. The weird thing is that
> the problem only comes on 8001.
>
>
> On 5/9/07, Tim Funk <fu...@joedog.org> wrote:
>>
>> I believe that the HTTPURLCOnnection throws a
>> java.io.FileNotFoundException in the case where a web server returns a
>> 404.
>>
>> Look at your access logs and request
>> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO via the
>> browser and see what happens.
>>
>> -Tim
>>
>> kz wrote:
>> > Hi,
>> >
>> > I am working on an application that involves applet-servlet
>> communication.
>> > The problem is that when Tomcat is listening at 8001, then I get an
>> > exception when I do connection.getInputStream() in applet. When I
>> switch
>> to
>> > port 8080, the problem gets solved. Heres the exception:
>> >
>> > java.io.FileNotFoundException:
>> > http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
>> > at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
>> > Source)
>> > at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
>> > SiteDataLinkAGT.java:303)
>> > at WES.Agents.SiteDataLinkAGT.establishOfficeSession(
>> SiteDataLinkAGT.java
>> > :283)
>>
>> ---------------------------------------------------------------------
>> To start a new topic, e-mail: users@tomcat.apache.org
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: problem at port 8001

Posted by kz <kh...@gmail.com>.
I used a scanner and tomcat is listening on port 8001 and not 8080. The
thing is that when I start Tomcat even on 8002 or any other port (other than
8080) and I change the applet also to connect to 8002 then the problem
doesn't come. WHy is that? I mean even if I am supposed to get a 404, then I
should get that on any port other than 8001 also. The weird thing is that
the problem only comes on 8001.


On 5/9/07, Tim Funk <fu...@joedog.org> wrote:
>
> I believe that the HTTPURLCOnnection throws a
> java.io.FileNotFoundException in the case where a web server returns a
> 404.
>
> Look at your access logs and request
> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO via the
> browser and see what happens.
>
> -Tim
>
> kz wrote:
> > Hi,
> >
> > I am working on an application that involves applet-servlet
> communication.
> > The problem is that when Tomcat is listening at 8001, then I get an
> > exception when I do connection.getInputStream() in applet. When I switch
> to
> > port 8080, the problem gets solved. Heres the exception:
> >
> > java.io.FileNotFoundException:
> > http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
> > at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
> > Source)
> > at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
> > SiteDataLinkAGT.java:303)
> > at WES.Agents.SiteDataLinkAGT.establishOfficeSession(
> SiteDataLinkAGT.java
> > :283)
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

Re: problem at port 8001

Posted by Tim Funk <fu...@joedog.org>.
I believe that the HTTPURLCOnnection throws a 
java.io.FileNotFoundException in the case where a web server returns a 404.

Look at your access logs and request
http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO via the 
browser and see what happens.

-Tim

kz wrote:
> Hi,
> 
> I am working on an application that involves applet-servlet communication.
> The problem is that when Tomcat is listening at 8001, then I get an
> exception when I do connection.getInputStream() in applet. When I switch to
> port 8080, the problem gets solved. Heres the exception:
> 
> java.io.FileNotFoundException:
> http://localhost:8001/servlet/WESFWDataLink_BRK.class?DLCT=EO
> at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown
> Source)
> at WES.Agents.SiteDataLinkAGT.CallDataLinkServiceAtServer(
> SiteDataLinkAGT.java:303)
> at WES.Agents.SiteDataLinkAGT.establishOfficeSession(SiteDataLinkAGT.java
> :283)

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org