0

Let me just preface this by saying I'm very new to the world of APIs and Web Services so please give me some slack if these questions are stupid.

So from what I understand, this is more or less how a web service (or web service architecture) works:

A web service provider describes its service parameters and how it to interface with the service in an XML document called the WSDL. The web service provider then registers with the UDDI. The "client" then queries the UDDI for relevant service providers. The UDDI returns multiple web service IP addresses and the client selects the best option. It then obtains that service provider's WSDL and proceeds to interface and utilize the web service.

My questions are:

  1. What exactly is a web service provider? I know a web service is essentially an API wrapped in HTTP (or some other transfer protocol) and it's used to facilitate communication over the internet. I also know that SOAP Web Services can utilize other transfer protocols besides HTTP, and WSDL and UDDI directories aren't used much outside of SOAP services. Is a web service provider just simply an application that is using SOAP web services?

  2. What is the "client" in this scenario? Is this a client web application or a browser?

  3. Why does the UDDI return multiple IP addresses for web service providers? Why doesn't the client just use the first web service it finds with the appropriate parameters, etc. ?

  4. How fast is all this happening? My dumbest question yet but are there developers manually querying the UDDI to find web services to integrate with their applications? Or is this all happening in a fraction of a second between computers?

Thank you so much. Couldn't find anything to address these questions online.

4

1 回答 1

0
  1. a) 究竟什么是网络服务提供商?我知道 Web 服务本质上是一个封装在 HTTP(或其他传输协议)中的 API,它用于促进 Internet 上的通信。我还知道 SOAP Web 服务可以使用除 HTTP 之外的其他传输协议,并且 WSDL 和 UDDI 目录在 SOAP 服务之外没有太多使用。

提供者?可能是提供某种服务的人、企业、开发人员,如谷歌、微软或亚马逊。如果您编写服务并通过将其托管在某种服务器上将其提供给其他人,那就是您。

  1. b) Web 服务提供者仅仅是一个使用 SOAP Web 服务的应用程序吗?

不使用服务,提供服务。

  1. 在这种情况下,“客户”是什么?这是客户端 Web 应用程序还是浏览器?

可以是任何人或任何东西,包括你的例子。

  1. a) 为什么 UDDI 会为 Web 服务提供商返回多个 IP 地址?

它返回多个绑定(服务的端点在哪里),因为运行一个服务的多个实例是很常见的,主要是为了提供冗余、负载平衡等。

  1. b) 为什么客户端不直接使用它找到的带有适当参数的第一个 Web 服务等?

这取决于编写客户端的人或该客户端的用户。第一个可能不是最佳选择(地理位置、延迟、性能等)

  1. a) 这一切发生得有多快?

如果采用 UDDI,通常每个客户端会话执行一次,或者如果性能或操作需要,则根据需要执行一次。这基本上是运行时发现。缺点是您需要知道一些东西(UDDI 在哪里以及查找键),然后才能与 UDDI 通信,然后是您的目标服务。

  1. b) 我最愚蠢的问题是,开发人员是否手动查询 UDDI 以查找要与他们的应用程序集成的 Web 服务?

可以这样,但实际上,大多数人只是使用搜索引擎

  1. c) 或者这一切都发生在计算机之间的几分之一秒内?

老实说,UDDI 的使用统计数据很可能非常低,但总体上几乎没有关于它的数据。难以确定

于 2017-03-04T20:48:59.740 回答