I was having a discussion with a colleague about Web Services. Now we both agree that a Web Method should only have one responsibility, as per single responsibility principle, but what about the entire service? I always considered the Web Service as a gateway, his argument was that if the web service has methods that have a different area functionally or from a domain perspective then those methods should be housed in a completely separate web service. I’m looking to see what the community has to say on the matter.
Should a web service with functionally different methods be housed in different services and URLs?
OR
Should a web service that’s considered an internal gateway house methods that are functionally different but related by the gateway concept?
I think that this will be a matter of opinion, but we chose to structure our web services using the same guidelines as used for class libraries in C# (Since we’re a .NET shop). Similar funcitonality goes into similar web services, named to clearly define what to expect in each web service.