axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Burati <mbur...@bowstreet.com>
Subject RE: Call with null namespace URI for method null
Date Tue, 21 Jan 2003 16:40:25 GMT

The error message is complaining about the method name (null) that you're
trying to call and it's namespace (null) - in other words, they're not set.

Something like:

    client.setOperationName(new QName(_methodNamespaceURI, _methodName) );

before your client.invoke(); ?


-----Original Message-----
From: Willie Slepecki [mailto:wslepecki@irsystems.org]
Sent: Tuesday, January 21, 2003 10:56 AM
To: axis-user@xml.apache.org
Subject: Call with null namespace URI for method null


i am trying to get a service going, and when i try to run the thing, i
get this:

[...]
AxisFault
 faultCode: {http://xml.apache.org/axis/}Call.invoke
 faultString: Cannot invoke Call with null namespace URI for method null
 faultActor: null
 faultDetail: 
	stackTrace: AxisFault
 faultCode: {http://xml.apache.org/axis/}Call.invoke
 faultString: Cannot invoke Call with null namespace URI for method null
 faultActor: null
 faultDetail: 

Cannot invoke Call with null namespace URI for method null
[...]

here is the XML i am trying to send via SOAP Messaging:

<wfeca xmlns:wfeca="http://www.360-degree.com/ns/wfeca">
   <Person xmlns:person="http://www.360-degree.com/ns/person">
      <FName>Willie</FName>
      <LName>Slepecki</LName>
      <MidInit>P</MidInit>
      <DOB>09051976</DOB>
      <SSN>123121234</SSN>
      <HomePhone>4124124125</HomePhone>
   </Person>
   <Address xmlns:address="http://www.360-degree.com/ns/address">
      <AddressLine>The Skateboard Warehouse</AddressLine>
      <City>Boston</City>
      <State>MA</State>
      <Zip>01775</Zip>
   </Address>
</wfeca>

and here is the code that fails:

package test.eca;

import java.io.InputStream;
import java.io.StringWriter;
import org.apache.axis.encoding.SerializationContextImpl;
import org.apache.axis.message.SOAPEnvelope;
import org.apache.axis.message.SOAPBodyElement;
import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import org.apache.axis.Message;
import org.apache.axis.MessageContext;


public class ECASubmissionClient
{
	/**
     * Target service URL
     */
    String url;
	 /**
     * Create a client with a target URL
     */
    public ECASubmissionClient(String url) {
        this.url = url;
    }
	
	public String invoke(InputStream po) throws Exception {
		
        // Send the message

		Call client = new Call(url);
		
		
        client.setRequestMessage(new Message(po, true));
		
        client.getMessageContext();
	
//.setTargetService("http://www.360-degree.com/ns/wfeca");
		
	
client.setSOAPActionURI("http://www.360-degree.com/ns/wfeca");
        
		client.invoke();
        
        // Retrieve the response body
        MessageContext ctx = client.getMessageContext();
        Message outMsg = ctx.getResponseMessage();
        SOAPEnvelope envelope = outMsg.getSOAPEnvelope();
        SOAPBodyElement body = envelope.getFirstBody();
        
        // Get the XML from the body
        StringWriter w = new StringWriter();
        SerializationContextImpl sc = new SerializationContextImpl(w, ctx);
        body.output(sc);
        return w.toString();
	//return "test message";
    }
}

i have a simple little JSP file that executes this class.  i know it can
execute
it fine because if i comment out the client.invoke() and everything after,
it
runs just fine.  i have been struggling with this for 2 weeks now, im out of
ideas, any help please?

thanks
willie


Mime
View raw message