meaning is there a difference between
<WebService(Namespace:="http://theurl.com/")>
and
<WebService(Namespace:="http://www.theurl.com/")>
?
Don't know if you're asking one of two things so I'll mention both.
1. What's the namespace for?
The reasons all derive from the W3C standards.
Very short answer: If you're doing some simple ASP.NET web services, all connecting through .NET you'll probably never know any difference. In fact, a lot of web services I've seen I see are still using tempuri.org ;-) Shame. If you're doing interop or are publishing a number of web services, a proper namespace guarantees uniqueness for similarly named services.
2. Does the subdomain matter?
Yes, different subdomain, therefore, while semantically equivalent, they're different namespaces. A namespace can look like a Url, but it's not. You could just as easily use something like "urn:org.tempuri" as a valid namespace.
This indicates the XML Namespace of the web service, and has nothing to with an actual address.
So yes, the namespaces mentioned are different. Just as the System.Data and the System namespaces in C# are different namespaces.
Does it matter which one you choose when creating the service? No, just pick one...
Does it matter which one you choose when consuming the service? Yes, use the one that the creator picked. (Which is described in the WSDL)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With