-
1. Re: Problem Accessing Web Service
djayakaran Jun 21, 2007 12:12 PM (in response to djayakaran)Here's the code I wrote to invoke the web service:
{
CurrencyForm form = null;
CurrencyWSService svc = null;
form = populateCurrencyForm(); // Souce, target currencies
svc = new CurrencyWSService();
CurrencyWS currencyWS = svc.getCurrencyWSPort();
System.out.println(form);
form = currencyWS.convertCurrency(form);
System.out.println(form);
}
The exception is thrown at the getCurrencyWSPort() call.
Here's my Service Endpoint Interface (SEI):
@WebService(name = "CurrencyWS", targetNamespace = "http://currencyconverter.ws/")
public interface CurrencyWS
{
@WebMethod
@WebResult(targetNamespace = "")
@RequestWrapper(localName = "convertCurrency", targetNamespace = "http://currencyconverter.ws/", className = "ws.currencyconverter.ConvertCurrency")
@ResponseWrapper(localName = "convertCurrencyResponse", targetNamespace = "http://currencyconverter.ws/", className = "ws.currencyconverter.ConvertCurrencyResponse")
public CurrencyForm convertCurrency(@WebParam(name = "arg0", targetNamespace = "") CurrencyForm arg0);
}
I seem to have the necessary @WebService annotation, yet the JBoss container throws the exception (see my previous posting).
Any thoughts? -
2. Re: Problem Accessing Web Service
djayakaran Jun 25, 2007 11:19 AM (in response to djayakaran)I've tried everything short of looking into JBoss's source code to see why it's throwing the exception:
Here's a portion of the call stack in the exception:
javax.xml.ws.WebServiceException: SEI is missing @WebService annotation: interface ws.currencyconverter.CurrencyWS
at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.assertSEIConstraints(ServiceDelegateImpl.java:287)
at org.jboss.ws.core.jaxws.spi.ServiceDelegateImpl.getPort(ServiceDelegateImpl.java:180)
at javax.xml.ws.Service.getPort(Service.java:116)
at ws.currencyconverter.CurrencyWSService.getCurrencyWSPort(CurrencyWSService.java:54)
at commands.ConvertCurrencyCommand.invokeWebService(ConvertCurrencyCommand.java:76)
at commands.ConvertCurrencyCommand.execute(ConvertCurrencyCommand.java:59)
at web.CurrencyConverterServlet.process(CurrencyConverterServlet.java:52)
Can someone help? If you think you can help but need more info, please reply and I'll post any additional info needed.
Thanks,
David -
3. Re: Problem Accessing Web Service
djayakaran Jul 2, 2007 11:47 AM (in response to djayakaran)I'm still having the problem. Am I missing something obvious? Tried everything I know to do... can someone please help?
-
4. Re: Problem Accessing Web Service
palin Jul 8, 2007 3:35 PM (in response to djayakaran)I'd check the deployment; are client and server side sharing classes? JBossWS stack throws that exception when it can't find @WebService annotation on the specified SEI, thus I suspect the class it's checking for annotation is not what you think it should be (classloading issue?)
Bye
Alessio Soldano
http://www.javalinux.it -
5. Re: Problem Accessing Web Service
djayakaran Jul 18, 2007 11:24 AM (in response to djayakaran)Thanks Alessio. I'll check your suggestion out and post a reply when I resolve the problem.
David -
6. Re: Problem Accessing Web Service
miegimolle Oct 1, 2011 12:58 PM (in response to djayakaran)Hi,
I have a similiar problem. Do you have resolved it?
Thx.