A web service using another web service

Posted on 2007-08-10
Last Modified: 2013-12-17
It seems logical for a web service to use another web service.

Are there any problems with this?  Are there any pitfalls I should know about?

Question by:newbieweb
    LVL 37

    Expert Comment

    You generally dont want to do this though you can ... preferred is a bus or a hub and spoke model..

    The reason for this is if this methodology (ervices calling eb services) is followed you end up with a web of depedencies
    LVL 11

    Expert Comment

    I have seen this used, and the only pitfall was that one of the web service layers was totally unnecessary- it added complexity needlesly. If you have a need for interprocess communications, then think about remoting or web services. However, if you just want a clean layer separation, just define some interfaces and separate the layers in their own DLLs.

    LVL 37

    Expert Comment


    On a small scale its not an issue. In an enterprise its considerred an anti-pattern, there are numerous products to avoid it: Biztalk and other products like websphere or Sonic offer solutions to the problems descibes a bit about what a service bus is.

    Basically the big issue can be easiest seen in deployment. Let's say I have a service which sits in front of a widget repository that the rest of my enterprise uses. There are 90 other services which use my service. I want to make a change to the widget web service to be queued service. I would now need to redeploy all 90 services that had dependencies on it (because they had a dependency on the endpint)

    Another example of where it gets to be nasty is that there is no good way of seeing my actual workflow associated with the process. Each service is calling out other services my logic is heavily fragmented throughout my enterprise.

    Another major issue is transaction management .. is a quick discussion DrDobbs had a great article on ESBs in July;jsessionid=0PYMV4CA5XZHSQSNDLRCKHSCJUNN2JVN?pgno=1 definately worth a read through.


    Author Comment

    I can see the disadvantage to this approach.  But if I were to need something quick, and for demo purposes, is it possible?

    Could I add a web reference to a web service to point at another web service?  Will it work the way it works for a Windows Forms application?

    LVL 37

    Accepted Solution

    yeah there is no technical difficulty in doing it ... as I said it can be done and in a small scale app isnt a problem but its not really a scalable model.



    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to improve team productivity

    Quip adds documents, spreadsheets, and tasklists to your Slack experience
    - Elevate ideas to Quip docs
    - Share Quip docs in Slack
    - Get notified of changes to your docs
    - Available on iOS/Android/Desktop/Web
    - Online/Offline

    This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
    Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now