You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Pedro Salazar <pe...@ptinovacao.pt> on 2003/10/07 15:43:43 UTC

org.apache.axis.wsdl.Java2WSDL --> WSDLException: faultCode=OTHER_ERROR: Can't find prefix for 'http://activation.javax'

Greetings,

I'm trying to create a WSDL from a java interface. However, I'm getting
problems in this method of my service interface:

public javax.activation.DataHandler testAttachment( DataHandler data)
       throws java.rmi.RemoteException ;

The trace error is:

The class javax.activation.DataHandler is defined in a java or javax
package and cannot be converted into an xml schema type.  An xml schema
anyType will be used to define this class in the wsdl file.
WSDLException: faultCode=OTHER_ERROR: Can't find prefix for
'http://activation.javax'. Namespace prefixes must be set on the
Definition object using the addNamespace(...) method.: 
        at com.ibm.wsdl.util.xml.DOMUtils.getPrefix(Unknown Source)
        at com.ibm.wsdl.util.xml.DOMUtils.getQualifiedValue(Unknown
Source)
        at
com.ibm.wsdl.util.xml.DOMUtils.printQualifiedAttribute(Unknown Source)
        at com.ibm.wsdl.xml.WSDLWriterImpl.printParts(Unknown Source)
        at com.ibm.wsdl.xml.WSDLWriterImpl.printMessages(Unknown Source)
        at com.ibm.wsdl.xml.WSDLWriterImpl.printDefinition(Unknown
Source)
        at com.ibm.wsdl.xml.WSDLWriterImpl.writeWSDL(Unknown Source)
        at com.ibm.wsdl.xml.WSDLWriterImpl.getDocument(Unknown Source)
        at org.apache.axis.wsdl.fromJava.Emitter.emit(Emitter.java:267)
        at org.apache.axis.wsdl.fromJava.Emitter.emit(Emitter.java:334)
        at org.apache.axis.wsdl.Java2WSDL.run(Java2WSDL.java:504)
        at org.apache.axis.wsdl.Java2WSDL.main(Java2WSDL.java:542)

I know that the IN/OUT objects on a WSDL operation in JAXRPC must be
serializable, with a default constructor and so on... But, I'm returning
that object because I want to provide an attachment and until now I
couldn't make a fine WSDL document with that specification (I'll post it
on another thread).

thanks,
Pedro Salazar
-- 
PS
pedro-b-salazar@ptinovacao.pt
PGP:0E129E31D803BC61