WCF回调:它是否可以与Java互操作? [英] WCF Callback: Is it interoperable with Java?

查看:236
本文介绍了WCF回调:它是否可以与Java互操作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

目前,我以正常方式实现所有的web服务...也就是说,我在Eclipse中创建一个WSDL文件,然后使用WSCF.blue(一个visual studio扩展)来自动生成必要的代码,它是回复/请求。但我希望使用回调,所以我可以让我的服务成为推服务。



在我开始重新编写我的应用程序之前,我想知道它的互操作性。如果我使用回调(WCF),我的Java客户端仍然可以使用这个?



哦,我想我真的应该问...是不是可以互操作的Java还有吗?只是为了...

解决方案

否。 WSDualHttpBinding CompositeDuplexBindingElement 不能与 Java



p>

正如@ x0n所指出的,在我的答案中引用的原始博客帖子不是100%正确。有一个较新的博客帖子介绍了如何实现互操作性。根据我的理解,该方法类似于使用通过WS-Addressing关联的异步响应的服务(WCF在正常处理中不支持此交换模型)。 WsDualHttpBinding 使用一些额外的功能,如WS-ReliableMessaging,它也使服务是有状态的。



如果所描述的方法将在所有情况下工作,因为它仍然谈论单向消息,但是WCF中的双工通信可以在服务和回调合同中使用单向和双向消息交换模式。


Currently I implement all my webservices in the "normal" fashion... that is, I create a WSDL file in Eclipse and then use WSCF.blue (A visual studio extension) to auto-generate the necessary code and it is reply/request. However I was hoping to use callbacks instead, so I can have my services become "push" services.

Before I jump into reworking my application, I was wondering about its interoperability. If I use callbacks (WCF), can my Java client still use this?

Oh, and I guess I should really ask... is it interoperable with more than Java as well? Just in case...

解决方案

No. WSDualHttpBinding and CompositeDuplexBindingElement are not interoperable with Java.

Edit:

As pointed by @x0n the original blog post referenced in my answer is not 100% correct. There is a newer blog post describing the way how to achieve interoperability. As I understand it the approach is similar to using service with asynchronous response correlated through WS-Addressing (WCF doesn't support this exchange model in normal processing). WsDualHttpBinding uses some additional features like WS-ReliableMessaging and it also makes the service stateful.

I'm not sure if the described approach will work in all cases because it still talks about one-way messages but duplex communication in WCF can use both one-way and two-way message exchange patterns in both service and callback contracts.

这篇关于WCF回调:它是否可以与Java互操作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆