开发者

Are there any conflicts with a web service calling another web service?

While the intention of my solution isn't necessary, I have run into a situation where I need to write a 开发者_运维知识库web service as an intermediate step in between the client and another web service.

[client] => [my web service] => [3rd party web service]

I am looking to see if anyone has any experience with this situation who could offer any advise or advise on any caveats that I can expect.

Note: I am developing using .NET and VS2008


No, its fine. In fact, its a great method to avoid a client from calling two web services when those calls are expensive (say from a phone). I created a solution once upon a time where my phone app would call my own web service, which would call another one, strip away a lot of the data and return the rest. You can get some pretty impressive perf increases if the main web service returns a lot of data.

The only catch may be authentication and that depends on a lot of variables and such. Good luck!


I've done it. It works fine. The only real concern is the same concern you'd have anyway - if the connection is broken between the two web serices, it's just another possible point of failure.


You can definitely do this. But, remember if you are transmitting any kind of sensitive data, you need SSL for the webservices.


On the negative performance implication sides, just keep in mind that any calls to this will get you two expensive HTTP connections instead of one expensive HTTP connection. Might be good to think about caching results in each layer if at all possible.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜