You are viewing a plain text version of this content. The canonical link for it is here.
Posted to sandesha-dev@ws.apache.org by Valerio Vianello <va...@yahoo.it> on 2006/07/12 12:56:23 UTC
URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Great!,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Thursday, July 13, 2006 5:03 AM
Subject: Re: URI$MalformedURIException
Hi Jaliya,
Thanks a lot. I resolved my problem.
P.S. in the server in the middle I have used also the instruction ctx.setSourceURL("http://localhost:8080/axis/services/RMService");
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Thursday, July 13, 2006 6:34 AM
Subject: Re: URI$MalformedURIException
Hi Valerio,
Let the three entities be A->B->C (A- Client, B - Service in the Middle, C - Final Service)
Do you have the client-config.wsdd in the classpath of B? B should have both client-config.wsdd and also the server-config.wsdd.
In addition the client-config.wsdd at B should be something like this as explained in the userguide under the normal invocation.
--------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================================
/*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*
*/
====================================================================================== -->
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="attachments.implementation" value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXMLDeclaration" value="true"/>
</globalConfiguration>
<handler name="RMSender" type="java:org.apache.sandesha.client.RMSender"/>
<transport name="java" pivot="java:org.apache.axis.transport.java.JavaSender"/>
<transport name="http" pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local" pivot="java:org.apache.axis.transport.local.LocalSender"/>
<transport name="RMTransport" pivot="RMSender"/>
</deployment>
One more change; when initializing SandeshaContext you can use the following to inform the server not to start a separate listener since we are inside a server already.
SandeshaContext ctx = new SandeshaContext(true);
Thanks,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Wednesday, July 12, 2006 10:09 AM
Subject: Re: URI$MalformedURIException
Thanks a lot, this is the code of the service that act as a client :
public class ServizioClient {
public void start() {
//ServizioServer endpoint
String endpoint = new String("http://localhost:8080/axis/services/ServizioServer");
try {
Service service = new Service();
Call call = (Call) service.createCall();
SandeshaContext ctx = new SandeshaContext();
ctx.setAcksToURL("http://localhost:8080/axis/services/RMService");
ctx.setReplyToURL("http://localhost:8080/axis/services/RMService");
ctx.initCall(call, endpoint, "urn:wsrm:ilNulla", Constants.ClientProperties.IN_ONLY);
call.setOperationName("ilNulla");
call.addParameter("arg1", XMLType.XSD_STRING, ParameterMode.IN);
ctx.setLastMessage(call);
call.invoke(new Object[]{"Chiamata a ilNulla"});
RMReport report = ctx.endSequence();
if (report != null) {
System.out.println("\n***********Printing RM Report***********");
System.out.println("Is all messages acked - " + report.isAllAcked());
System.out.println("****************************************\n");
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
Valerio
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 3:44 PM
Subject: Re: URI$MalformedURIException
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Great!,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Thursday, July 13, 2006 5:03 AM
Subject: Re: URI$MalformedURIException
Hi Jaliya,
Thanks a lot. I resolved my problem.
P.S. in the server in the middle I have used also the instruction ctx.setSourceURL("http://localhost:8080/axis/services/RMService");
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Thursday, July 13, 2006 6:34 AM
Subject: Re: URI$MalformedURIException
Hi Valerio,
Let the three entities be A->B->C (A- Client, B - Service in the Middle, C - Final Service)
Do you have the client-config.wsdd in the classpath of B? B should have both client-config.wsdd and also the server-config.wsdd.
In addition the client-config.wsdd at B should be something like this as explained in the userguide under the normal invocation.
--------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================================
/*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*
*/
====================================================================================== -->
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="attachments.implementation" value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXMLDeclaration" value="true"/>
</globalConfiguration>
<handler name="RMSender" type="java:org.apache.sandesha.client.RMSender"/>
<transport name="java" pivot="java:org.apache.axis.transport.java.JavaSender"/>
<transport name="http" pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local" pivot="java:org.apache.axis.transport.local.LocalSender"/>
<transport name="RMTransport" pivot="RMSender"/>
</deployment>
One more change; when initializing SandeshaContext you can use the following to inform the server not to start a separate listener since we are inside a server already.
SandeshaContext ctx = new SandeshaContext(true);
Thanks,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Wednesday, July 12, 2006 10:09 AM
Subject: Re: URI$MalformedURIException
Thanks a lot, this is the code of the service that act as a client :
public class ServizioClient {
public void start() {
//ServizioServer endpoint
String endpoint = new String("http://localhost:8080/axis/services/ServizioServer");
try {
Service service = new Service();
Call call = (Call) service.createCall();
SandeshaContext ctx = new SandeshaContext();
ctx.setAcksToURL("http://localhost:8080/axis/services/RMService");
ctx.setReplyToURL("http://localhost:8080/axis/services/RMService");
ctx.initCall(call, endpoint, "urn:wsrm:ilNulla", Constants.ClientProperties.IN_ONLY);
call.setOperationName("ilNulla");
call.addParameter("arg1", XMLType.XSD_STRING, ParameterMode.IN);
ctx.setLastMessage(call);
call.invoke(new Object[]{"Chiamata a ilNulla"});
RMReport report = ctx.endSequence();
if (report != null) {
System.out.println("\n***********Printing RM Report***********");
System.out.println("Is all messages acked - " + report.isAllAcked());
System.out.println("****************************************\n");
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
Valerio
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 3:44 PM
Subject: Re: URI$MalformedURIException
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Hi Valerio,
Let the three entities be A->B->C (A- Client, B - Service in the Middle, C - Final Service)
Do you have the client-config.wsdd in the classpath of B? B should have both client-config.wsdd and also the server-config.wsdd.
In addition the client-config.wsdd at B should be something like this as explained in the userguide under the normal invocation.
--------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================================
/*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*
*/
====================================================================================== -->
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="attachments.implementation" value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXMLDeclaration" value="true"/>
</globalConfiguration>
<handler name="RMSender" type="java:org.apache.sandesha.client.RMSender"/>
<transport name="java" pivot="java:org.apache.axis.transport.java.JavaSender"/>
<transport name="http" pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local" pivot="java:org.apache.axis.transport.local.LocalSender"/>
<transport name="RMTransport" pivot="RMSender"/>
</deployment>
One more change; when initializing SandeshaContext you can use the following to inform the server not to start a separate listener since we are inside a server already.
SandeshaContext ctx = new SandeshaContext(true);
Thanks,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Wednesday, July 12, 2006 10:09 AM
Subject: Re: URI$MalformedURIException
Thanks a lot, this is the code of the service that act as a client :
public class ServizioClient {
public void start() {
//ServizioServer endpoint
String endpoint = new String("http://localhost:8080/axis/services/ServizioServer");
try {
Service service = new Service();
Call call = (Call) service.createCall();
SandeshaContext ctx = new SandeshaContext();
ctx.setAcksToURL("http://localhost:8080/axis/services/RMService");
ctx.setReplyToURL("http://localhost:8080/axis/services/RMService");
ctx.initCall(call, endpoint, "urn:wsrm:ilNulla", Constants.ClientProperties.IN_ONLY);
call.setOperationName("ilNulla");
call.addParameter("arg1", XMLType.XSD_STRING, ParameterMode.IN);
ctx.setLastMessage(call);
call.invoke(new Object[]{"Chiamata a ilNulla"});
RMReport report = ctx.endSequence();
if (report != null) {
System.out.println("\n***********Printing RM Report***********");
System.out.println("Is all messages acked - " + report.isAllAcked());
System.out.println("****************************************\n");
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
Valerio
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 3:44 PM
Subject: Re: URI$MalformedURIException
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Hi Valerio,
Let the three entities be A->B->C (A- Client, B - Service in the Middle, C - Final Service)
Do you have the client-config.wsdd in the classpath of B? B should have both client-config.wsdd and also the server-config.wsdd.
In addition the client-config.wsdd at B should be something like this as explained in the userguide under the normal invocation.
--------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================================
/*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*
*/
====================================================================================== -->
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<globalConfiguration>
<parameter name="adminPassword" value="admin"/>
<parameter name="disablePrettyXML" value="true"/>
<parameter name="attachments.implementation" value="org.apache.axis.attachments.AttachmentsImpl"/>
<parameter name="sendXsiTypes" value="true"/>
<parameter name="sendMultiRefs" value="true"/>
<parameter name="sendXMLDeclaration" value="true"/>
</globalConfiguration>
<handler name="RMSender" type="java:org.apache.sandesha.client.RMSender"/>
<transport name="java" pivot="java:org.apache.axis.transport.java.JavaSender"/>
<transport name="http" pivot="java:org.apache.axis.transport.http.HTTPSender"/>
<transport name="local" pivot="java:org.apache.axis.transport.local.LocalSender"/>
<transport name="RMTransport" pivot="RMSender"/>
</deployment>
One more change; when initializing SandeshaContext you can use the following to inform the server not to start a separate listener since we are inside a server already.
SandeshaContext ctx = new SandeshaContext(true);
Thanks,
-Jaliya
----- Original Message -----
From: Valerio Vianello
To: Jaliya Ekanayake
Sent: Wednesday, July 12, 2006 10:09 AM
Subject: Re: URI$MalformedURIException
Thanks a lot, this is the code of the service that act as a client :
public class ServizioClient {
public void start() {
//ServizioServer endpoint
String endpoint = new String("http://localhost:8080/axis/services/ServizioServer");
try {
Service service = new Service();
Call call = (Call) service.createCall();
SandeshaContext ctx = new SandeshaContext();
ctx.setAcksToURL("http://localhost:8080/axis/services/RMService");
ctx.setReplyToURL("http://localhost:8080/axis/services/RMService");
ctx.initCall(call, endpoint, "urn:wsrm:ilNulla", Constants.ClientProperties.IN_ONLY);
call.setOperationName("ilNulla");
call.addParameter("arg1", XMLType.XSD_STRING, ParameterMode.IN);
ctx.setLastMessage(call);
call.invoke(new Object[]{"Chiamata a ilNulla"});
RMReport report = ctx.endSequence();
if (report != null) {
System.out.println("\n***********Printing RM Report***********");
System.out.println("Is all messages acked - " + report.isAllAcked());
System.out.println("****************************************\n");
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
Valerio
----- Original Message -----
From: Jaliya Ekanayake
To: Valerio Vianello
Cc: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 3:44 PM
Subject: Re: URI$MalformedURIException
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio
Re: URI$MalformedURIException
Posted by Jaliya Ekanayake <jn...@gmail.com>.
Hi,
Seems like there is a problem with the addressing header values that you have set. Can you send the client code in your first service where you use Call to invoke the other web service.
Thanks,
Jaliya
----- Original Message -----
From: Valerio Vianello
To: sandesha-dev@ws.apache.org
Sent: Wednesday, July 12, 2006 6:56 AM
Subject: URI$MalformedURIException
Hi all, I'm a new sandesha user and I'm trying to develop a service that calls another service using reliable messaging.
I published the client service using the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioClient" provider="java:RPC">
<parameter name="className" value="sandeshaMio.ServizioClient"/>
<parameter name="allowedMethods" value="*"/>
</service>
<service name="RMService" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMClientProvider"/>
<parameter name="className" value="org.apache.sandesha.client.RMService"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
and the service that act as a server with the following wsdd file:
<deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="ServizioServer" provider="Handler">
<requestFlow>
<handler type="java:org.apache.sandesha.ws.rm.handlers.RMServerRequestHandler"></handler>
<handler type="java:org.apache.axis.message.addressing.handler.AddressingHandler"></handler>
</requestFlow>
<parameter name="handlerClass" value="org.apache.sandesha.ws.rm.providers.RMProvider"/>
<parameter name="className" value="sandeshaMio.ServizioServer"/>
<parameter name="allowedMethods" value="*"/>
<parameter name="scope" value="request"/>
</service>
</deployment>
When the client service tries to invoke the other service I get the following error from the server :
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:org.apache.axis.types.URI$MalformedURIException: Cannot initialize URI with empty parameters.
at org.apache.axis.types.URI.initialize(URI.java:614)
at org.apache.axis.types.URI.<init>(URI.java:311)
at org.apache.axis.types.URI.<init>(URI.java:272)
at org.apache.axis.message.addressing.handler.AddressingHandler.processClientRequest(AddressingHandler.java:240)
at org.apache.axis.message.addressing.handler.AddressingHandler.invoke(AddressingHandler.java:108)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:127)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at sandeshaMio.ServizioClient.start(ServizioClient.java:50)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:453)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:615)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:688)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
................
any suggestion ?
Valerio