Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error creating client bean #59

Open
sufyanshoaib opened this issue Oct 27, 2015 · 1 comment
Open

error creating client bean #59

sufyanshoaib opened this issue Oct 27, 2015 · 1 comment

Comments

@sufyanshoaib
Copy link

I have added these client configuration into Config:

cxf {
  client {
    paymentRequestClient {
        wsdl = "https://sandbox.demo.com/payments.wsdl"
        namespace = "com.demo.soap"
        clientInterface = com.demo.soap.PaymentPortType
        serviceEndpointAddress = "https://sandbox.demo.com/payments.php"
    }

  }
}

After running grails wsdl2java grails has generated the required Java classes against the provided WSDL except for PaymentPortType class.

On running the application, I am getting this error:

Web service client paymentRequestClient cannot be created before setting the clientInterface=[:] and serviceEndpointAddress=https://sandbox.demo.com/payments.php properties
[ERROR] 2015-10-27 12:00:11,899 CxfClientGrailsPlugin - Web service client paymentRequestClient cannot be created before setting the clientInterface=[:] and serviceEndpointAddress=https://sandbox.demo.com/payments.php properties
Configuring Spring Security Core ...
... finished configuring Spring Security Core
Configuring Spring Security REST ...
... finished configuring Spring Security REST
[ERROR] 2015-10-27 12:00:39,401 
org.codehaus.groovy.grails.web.context.GrailsContextLoaderListener -             Error initializing the application: Error creating bean with name 'paymentRequestClient': Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'java.lang.String' to required type 'java.lang.Class' for property 'clientInterface'; nested exception is java.lang.IllegalArgumentException: Could not load class []!

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'paymentRequestClient': Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'java.lang.String' to required type 'java.lang.Class' for property 'clientInterface'; nested exception is java.lang.IllegalArgumentException: Could not load class []!
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)

Caused by: org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'java.lang.String' to required type 'java.lang.Class' for property 'clientInterface'; nested exception is java.lang.IllegalArgumentException: Could not load class []!
... 4 more

Caused by: java.lang.IllegalArgumentException: Could not load class []!
... 4 more

What could be the possible issue?

@andrebrov
Copy link

I had exactly the same problem, solved it by creating empty class from clientInterface.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants