useOriginalwsdl=true is not working in axis2

后端 未结 2 1917
轻奢々
轻奢々 2020-12-21 09:23

I have followed contract first approach. So I first wrote the wsdl file and then generated the server side code. But when I hit the url for my web service in the browser the

相关标签:
2条回答
  • 2020-12-21 09:36

    useOriginalwsdl=true will work if you have followed the following steps:

    1. put the custom wsdl file inside the META-INF folder.
    2. the service name should be the same in both the custom wsdl as well as in the services.xml
    3. Name the custome wsdl as service.wsdl or (Your ServiceName).wsdl.
    4. Set useOriginalwsdl=true in services.xml file

    Note: If useOriginalwsdl=true, Axis2 engine first tries to use any wsdl file named service.wsdl. If not found, then it tries to find named (your service name).wsdl If not succeeds, then it shows error when u try to access the web service.

    0 讨论(0)
  • 2020-12-21 09:57

    Do you have external schema references in your WSDL..? If so, those should be also added to META-INF directory... Please also attach your WSDL..

    Since you are using contract first, better you validate your WSDL too.. there are wsdl validating tools available...

    Thanks...

    0 讨论(0)
提交回复
热议问题