views:

34

answers:

0

I'm new in grails, and trying to build a backend for my webservice, the apps only access the webservice provided not access to databases directly.

package backend

import org.grails.plugins.wsclient.service.WebService

class BackendController {

    WebService webService

    def index = { 
        def wsdlUrl = "http://localhost8080/BackendService/Backend?wsdl"
        def proxy = webService.getClient(wsdlUrl)

        def result = proxy.getAll()
        render(text:result);
    }
}

and throw this error

Error 500: Executing action [index] of controller [backend.BackendController] caused exception: org.apache.cxf.interceptor.Fault: None of the policy alternatives can be satisfied.

How to fix that error ?