`
taoeaten
  • 浏览: 1466 次
  • 性别: Icon_minigender_1
  • 来自: 淮南
最近访客 更多访客>>
文章分类
社区版块
存档分类
最新评论

How to avoid "Unable to generate EPR for transport" error in Axis2

UP 
阅读更多
How to avoid "Unable to generate EPR for transport" error in Axis2
"Unable to generate EPR for transport: http" is a FAQ in Axis2 mailing list. You may have experienced this when invoking a service using generated stubs.

Solution:

It's really simple. When creating the instance of stub, pass the actual service end point (epr) to the constructor as follows.

YourserviceStub stub = new YourserviceStub("http://<IP>:<PORT>/axis2/services/YourService")


Ideally when u generate a stub for a service it will pick up the Endpoint reference from the WSDL. So just instantiating stub with YourserviceStub stub = new YourserviceStub() could send the request to the address defined in the WSDL. In case you get the "Unable to generate EPR for transport: http" error, give a try with the above as well.
0
0
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics