I am using webservice with soap attachments in jboss-4.0.0.The method should
accept a file attachment and should return a file.
This is my SEI
public interface MyService extends java.rmi.Remote {
| public DataHandler myService(DataHandler in0) throws
java.rmi.RemoteException;
| }
WSDL file :
==========
| <?xml version="1.0" encoding="UTF-8"?>
| <wsdl:definitions targetNamespace="http://attachment.example.org"
| xmlns:impl="http://attachment.example.org"
| xmlns:intf="http://attachment.example.org"
| xmlns:apachesoap="http://xml.apache.org/xml-soap"
| xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
| xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
| xmlns:xsd="http://www.w3.org/2001/XMLSchema"
| xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
| xmlns="http://schemas.xmlsoap.org/wsdl/">
|
| <wsdl:message name="myServiceResponse">
|
| <wsdl:part name="myServiceReturn" type="javax.activtion.DataHandler"/>
|
| </wsdl:message>
|
| <wsdl:message name="myServiceRequest">
|
| <wsdl:part name="in0" type="javax.activtion.DataHandler"/>
|
| </wsdl:message>
|
| <wsdl:portType name="MyService">
|
| <wsdl:operation name="myService" parameterOrder="in0">
|
| <wsdl:input name="myServiceRequest"
message="impl:myServiceRequest"/>
|
| <wsdl:output name="myServiceResponse"
message="impl:myServiceResponse"/>
|
| </wsdl:operation>
|
| </wsdl:portType>
|
| <wsdl:binding name="MyServiceSoapBinding" type="impl:MyService">
|
| <wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
|
| <wsdl:operation name="myService">
|
| <wsdlsoap:operation soapAction=""/>
|
| <wsdl:input name="myServiceRequest">
|
| <wsdlsoap:body use="literal"
namespace="http://attachment.example.org"/>
|
| </wsdl:input>
|
| <wsdl:output name="myServiceResponse">
|
| <wsdlsoap:body use="literal"
namespace="http://attachment.example.org"/>
|
| </wsdl:output>
|
| </wsdl:operation>
|
| </wsdl:binding>
|
| <wsdl:service name="MyServiceService">
|
| <wsdl:port name="MyService" binding="impl:MyServiceSoapBinding">
|
| <wsdlsoap:address
location="http://192.10.10.58:8080/ws4ee/services/attachments"/>
|
| </wsdl:port>
|
| </wsdl:service>
|
| </wsdl:definitions>
I am using the wsdltojava to create wsdl file and javatowsdl .
When i deploy in the server it is giving me the below exception
WSDL published to:
file:/data/jboss-4.0.0/server/default/data/wsdl/attachments.war/attachment.wsdl
14:56:13,949 ERROR [ServiceDeployer] Cannot startup webservice for:
attachments.war
org.jboss.deployment.DeploymentException: Cannot deploy webservice; - nested
throwable: (RuntimeMBeanException: null Cause:
java.lang.IllegalArgumentException: Cannot find package type for:
{http://xml.apache.org/xml-soap}DataHandler)
at
org.jboss.webservice.ServiceDeployer.deployWebservices(ServiceDeployer.java:342)
at
org.jboss.webservice.ServiceDeployer.startWebservice(ServiceDeployer.java:203)
at
org.jboss.webservice.ServiceDeployer.handleNotification(ServiceDeployer.java:113)
at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.notification.NotificationListenerProxy.invoke(NotificationListenerProxy.java:138)
at $Proxy25.handleNotification(Unknown Source)
at
javax.management.NotificationBroadcasterSupport.handleNotification(NotificationBroadcasterSupport.java:104)
at
javax.management.NotificationBroadcasterSupport.sendNotification(NotificationBroadcasterSupport.java:87)
at
org.jboss.deployment.SubDeployerSupport.start(SubDeployerSupport.java:178)
at
org.jboss.web.AbstractWebContainer.start(AbstractWebContainer.java:378)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:935)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:746)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:709)
at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at
org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:119)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at
org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:242)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
at $Proxy8.deploy(Unknown Source)
at
org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:305)
at
org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:481)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:204)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:277)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:271)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:221)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:242)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:891)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:416)
at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:242)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:261)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:935)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:746)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:709)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:693)
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:324)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at
org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:119)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at
org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:131)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:242)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
at $Proxy5.deploy(Unknown Source)
at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:396)
at org.jboss.system.server.ServerImpl.start(ServerImpl.java:293)
at org.jboss.Main.boot(Main.java:151)
at org.jboss.Main$1.run(Main.java:405)
at java.lang.Thread.run(Thread.java:534)
when i tried to access the xml namespace http://xml.apache.org/xml-soap,it is
giving me the URL not found.
Please tell am i in the correct path ...
Is there any other way for soap attachments using wsdltojava
Thanks in Advance !!!
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3885441#3885441
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3885441
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user