无限期地使用推送的 SOAP 消息的服务?
我遇到的情况是,我的域中的另一个系统定期向给定数量的 IP:端口地址发送 SOAP 消息,而我能够接收这些消息。 现在,我对 Web 服务有了一些经验,但这次有所不同。
我认为我基本上需要的是运行某种侦听器服务并获取这些 SOAP 消息。该服务需要采用 .NET,并且可能是用 C# 编写的。
我目前正在研究从简单的 HttpListener 实现到 WCF 的所有内容。您建议如何解决这个问题?
注意:这是一个现有的互操作性接口,这就是为什么我不只是做一个 Web 服务或 WCF 服务并让其他系统调用它。
I'm in a situation where another system in my domain is sending SOAP messages periodically to a given number of IP:Port addresses, and i went to be able to receive those.
Now, I have experience with Web Services a bit, But this is different.
I thought that what i basically need is some kind of Listener service running and getting those SOAP messages. The service needs to be in .NET and probably written in C#.
I'm currently looking at anything from simple HttpListener implementation to WCF. How would you suggest to go about this?
Note: This is an existing interoperability interface, Which is why i'm not just doing a Web service or WCF Service and have the other system call it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您知道合约应该是什么样子,您可以创建一个简单的 WCF 服务来接受它并侦听指定的 IP:Port。使用 BasicHttpBinding 的 WCF 期望接收 SOAP 消息,因此正确设置后,它应该可以处理它。
如果您不这样做,并且由于某种原因无法弄清楚(或者它改变了很多),那么您可以打开一个接受该端口上的流量的套接字,并在消息出现时自己解析消息。
If you know what the contract is supposed to look like, you could create a simple WCF service that accepts it and listen on the specified IP:Port. WCF using BasicHttpBinding is expecting to receive a SOAP message, so with things set up correctly it should handle it.
If you don't, and can't figure it out for some reason (or it changes a lot), then you could just open a socket that accepts traffic on that port and parse the messages out yourself when they turn up.