0

i followed this article: http://www.mkyong.com/webservices/jax-ws/jax-ws-hello-world-example/

so i have:

which serves as the endpoint.

on the other side i have the client which i generated with wsimport:

this runs fine in eclispe without alfresco being involved. however, i want to call the webservice from alfresco (from java backed web script for example)

i tried to copy the client side stuff to my amp file and calling it from a webscript but it fails!

Caused by: java.lang.IncompatibleClassChangeError: Class com.ibm.wsdl.DefinitionImpl does not implement the requested interface javax.wsdl.extensions.AttributeExtensible

1 - is there a more elegant way to configure the access to the wsdl by defining a spring bean (spring-ws) or such

2 - why is it not working? full trace: http://pastebin.com/ak1qzygA

using alfresco community 5.0.a

thanks

user1429166
  • 132
  • 12
  • 2
    http://stackoverflow.com/questions/1980452/what-causes-java-lang-incompatibleclasschangeerror . Dependancy jar issue? – M.. Sep 03 '14 at 17:12
  • i removed axis-wsdl4j-1.5.1.jar from the lib directory - now it works ... but that is very strange to me. – user1429166 Sep 04 '14 at 11:28
  • 1
    Maybe there were conflicts with other wsdl4j.jar; the axis-wsdl4j jar picked on priority over the other. With axiswsdl4j jar gone things work now?? – M.. Sep 04 '14 at 12:00
  • maybe. yes, its working with the axis wsdl jar gone – user1429166 Sep 04 '14 at 12:07
  • OK. let me just update it as an answer which could help others. – M.. Sep 04 '14 at 15:01
  • 1
    reported the issue at alfresco jira and fix is going to be in the next release https://issues.alfresco.com/jira/browse/ALF-21093 – user1429166 Sep 09 '14 at 07:21

1 Answers1

0

You will see IncompatibleClassChangeError usually when the dependancy/library jar has changed. Hence the method/code dependant on the library has to be recompiled against the changes.

Guessing the problem here has much to do with some dependancy jar being mispicked or an older version of jar present or one jar prioritized over the other. A look into the jars containing 'com.ibm.wsdl.DefinitionImpl' class in your classpath should be of some help.

M..
  • 880
  • 7
  • 15