-
Cannot access HTTP
Hi
*Complete newbie to spring-remoting module*
Seems straight forward, however I am getting 404 errors, are there any gotcha's I am missing?
Here the the output from the remote client.
Code:
Sending HTTP invoker request for service at [http://127.0.0.1:8080/websara/TestService], with size 268
HttpConnectionManager.getConnection: config = HostConfiguration[host=127.0.0.1, protocol=http:80, port=8080], timeout = 0
Allocating new connection, hostConfig=HostConfiguration[host=127.0.0.1, protocol=http:80, port=8080]
HttpConnection.setSoTimeout(0)
Execute loop try 1
>> "POST /websara/TestService HTTP/1.1[\r][\n]"
Adding Host request header
>> "Content-Type: application/x-java-serialized-object[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/2.0.2[\r][\n]"
>> "Host: 127.0.0.1:8080[\r][\n]"
>> "Content-Length: 268[\r][\n]"
>> "[\r][\n]"
Using buffered request body
>> "[0xac][0xed][0x0][0x5]sr[0x0]5org.springframework.remoting.support.RemoteInvocation_l[0x8b][0x9f][0xf6][\n]"
>> "[0x11][\n]"
>> "[0x2][0x0][0x4][[0x0][0x9]argumentst[0x0][0x13][Ljava/lang/Object;L[0x0][\n]"
>> "attributest[0x0][0xf]Ljava/util/Map;L[0x0][\n]"
>> "methodNamet[0x0][0x12]Ljava/lang/String;[[0x0][0xe]parameterTypest[0x0][0x12][Ljava/lang/Class;xpppt[0x0][\r]getHelloWorldur[0x0][0x12][Ljava.lang.Class;[0xab][0x16][0xd7][0xae][0xcb][0xcd]Z[0x99][0x2][0x0][0x0]xp[0x0][0x0][0x0][0x0]"
Request body sent
<< "HTTP/1.1 404 /websara/TestService[\r][\n]"
<< "Server: Apache-Coyote/1.1[\r][\n]"
<< "X-Powered-By: Servlet 2.4; JBoss-4.0.5.GA (build: CVSTag=Branch_4_0 date=200610162339)/Tomcat-5.5[\r][\n]"
<< "Set-Cookie: JSESSIONID=13965CF9C0B6BD3F76DCB6D434C25C6A; Path=/[\r][\n]"
<< "Content-Type: text/html;charset=utf-8[\r][\n]"
<< "Content-Length: 1012[\r][\n]"
<< "Date: Fri, 16 Feb 2007 16:25:52 GMT[\r][\n]"
Cookie accepted: "$Version=0; JSESSIONID=13965CF9C0B6BD3F76DCB6D434C25C6A; $Path=/"
<< "<html><head><title>Apache Tomcat/5.5.20 - Error report</title><style><!--H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:Tahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}HR {color : #525D76;}--></style> </head><body><h1>HTTP Status 404 - /websara/TestService</h1><HR size="1" noshade="noshade"><p><b>type</b> Status report</p><p><b>message</b> <u>/websara/TestService</u></p><p><b>description</b> <u>The requested resource (/websara/TestService) is not available.</u></p><HR size="1" noshade="noshade"><h3>Apache Tomcat/5.5.20</h3></body></html>"
Resorting to protocol version default close connection policy
Should NOT close connection, using HTTP/1.1.
Freeing connection, hostConfig=HostConfiguration[host=127.0.0.1, protocol=http:80, port=8080]
Notifying no-one, there are no waiting threads
Exception in thread "main" org.springframework.remoting.RemoteAccessException: Cannot access HTTP invoker remote service at [http://127.0.0.1:8080/websara/TestService]; nested exception is org.apache.commons.httpclient.HttpException: Did not receive successful HTTP response: status code = 404, status message = [/websara/TestService]
org.apache.commons.httpclient.HttpException: Did not receive successful HTTP response: status code = 404, status message = [/websara/TestService]
at org.springframework.remoting.httpinvoker.CommonsHttpInvokerRequestExecutor.validateResponse(CommonsHttpInvokerRequestExecutor.java:179)
at org.springframework.remoting.httpinvoker.CommonsHttpInvokerRequestExecutor.doExecuteRequest(CommonsHttpInvokerRequestExecutor.java:101)
at org.springframework.remoting.httpinvoker.AbstractHttpInvokerRequestExecutor.executeRequest(AbstractHttpInvokerRequestExecutor.java:69)
at org.springframework.remoting.httpinvoker.HttpInvokerClientInterceptor.executeRequest(HttpInvokerClientInterceptor.java:146)
at org.springframework.remoting.httpinvoker.HttpInvokerClientInterceptor.invoke(HttpInvokerClientInterceptor.java:120)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
regards JC.
-
Basic error in url! Works fine now.