Web 服务器和 Web 服务之间有区别吗?

发布于 2024-08-20 00:34:59 字数 31 浏览 1 评论 0原文

对我来说,这些术语听起来非常相似。真的有区别吗?

To me, these terms sound very similar. Is there a difference really?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(16

感受沵的脚步 2024-08-27 00:34:59

Web 服务将在 Web 服务器上运行。

网络服务器是一款设计用于提供网页/网站/网络服务的软件。例如 IIS、Apache 等等。该名称也可以指运行该软件的硬件。

由于 Web 服务 将在 Web 服务器内运行 - 通常提供 XML 或执行某些操作作为响应输入。

来自维基百科:

如今的 Web 服务通常只是可通过网络访问的应用程序编程接口 (API) 或 Web API

A web service will be running on a web server.

A web server is a piece of software designed to serve web pages/web sites/web services. Examples are IIS, Apache and many more. The name can also refer to the hardware running this software.

As web service will be running inside a web server - normally serving up XML or performing some action in response to input.

From wikipedia:

Web services today are frequently just Application Programming Interfaces (API) or web APIs that can be accessed over a network

最丧也最甜 2024-08-27 00:34:59

Web 服务是由 Web 服务器运行的应用程序,它会产生一系列 URL,这些 URL 将以旨在由“通用”计算机程序而不是浏览器解析的格式返回其数据。因此,Web 服务可以使用它们想要的任何数据格式(只要双方同意),但通常使用 XML(特别是 SOAP 等)或 JSON 等格式。

A web service is an application that is run by a web server and that results in a series of URLs that will return their data in a format that is intended to be parsed by a 'generic' computer program instead of by a browser. As a result web services can use any data format they want (as long as both sides agree), but typically something like XML (specifically SOAP or so) or JSON is used.

愛上了 2024-08-27 00:34:59

“Web 服务器”和“Web 服务”之间的区别如下:

Web 服务器

  • 是运行在物理机或虚拟机上的一个软件,旨在为网页/网页提供服务网站/网络服务。
  • Web服务器使用的传输通道必然需要是HTTP协议。
  • 接受 HTTP 请求并通过给出 HTTP 响应进行响应。

Web 服务:

  • 是由 Web 服务器运行的应用程序,执行任务并向调用程序返回结构化数据,而不是浏览器的 HTML。

  • 由于这个原因,它可以使用他们希望的任何数据格式 - 也许像 XML、SOAP 或 JSON。

    由于

  • Web 服务使用的传输通道不一定是 HTTP 协议。
  • 主要有两种类型的Web服务(在微软领域):WCF和ASMX。 WCF 服务由 IIS“托管”,而 ASMX Web 服务在 IIS 内运行。

The differences between a "web server" and a "web service" are as follows:

Web Server:

  • is a piece of software that run on a physical or virtual machine, which designed to serve web pages/web sites/web services.
  • transport channel used by web server necessarily need to be HTTP protocol.
  • accept HTTP requests and respond by giving HTTP responses.

Web Services:

  • is an application run by a web server, performing tasks and returning structured data to a calling program, rather than HTML for a browser.

  • due to that reason, it can use any data format they wish—perhaps something like XML, SOAP, or JSON.

  • transport channel used by web services doesn't necessarily need to be the HTTP protocol.
  • mainly there are two types of web services (in Microsoft land): WCF and ASMX. WCF services are "hosted" by IIS, whereas ASMX web services run within IIS.
南巷近海 2024-08-27 00:34:59

其中许多答案都是错误的。

虽然 Web 服务器必然是 HTTP 服务器,但 Web 服务只是通过网络提供的服务。由于协议可能不是 HTTP,因此您可以通过邮件或其他协议提供 Web 服务,并且为此不需要 Web 服务器。

Web 服务使用的传输通道不一定是 HTTP 协议。

术语“Web 服务”也用于指代 SOAP xml 标准,它是对 Web 服务调用中的信息进行编码的标准方法。

Many of these answers are wrong.

While a Web Server is necessarily an HTTP server, a Web Service is simply a service that is available through the network. As the protocol may not be HTTP, you may provide WebServices over mail or other protocols, and you do not need a web server for that.

The transport channel used by Web Services doesn't necessarily need to be the HTTP protocol.

The term "Web Services" is also used to refer to the SOAP xml standard, that is a standard way to encode the information in Web Service invocations.

小苏打饼 2024-08-27 00:34:59

Web 服务器 的定义

WebService

Web 服务器通常是指运行在物理机或虚拟机上的处理 Web 请求的软件(例如,将页面返回到浏览器并执行对 Web 服务的调用)

Web 服务运行在 Web 服务器中执行任务并(通常)将结构化数据返回到调用程序,而不是浏览器的 html。

Definition of Web Server

Definition of WebService

A Web Server generally refers to software running on a physical or virtual machine that processes web requests (e.g. returning pages to browsers and executing calls to Web Services)

A Web Service runs in a Web Server performing tasks and (generally) returning structured data to a calling program, rather than html for a browser.

寄与心 2024-08-27 00:34:59

简而言之:

Web 服务是可以通过网络(例如 Internet)访问的应用程序。
Web 服务器是通过 HTTP 传送内容的程序。

因此,如果您希望通过 Internet 访问您的 Web 服务,您需要将其设置在 Web 服务器上。

我们是否需要过于技术化?

In a nutshell:

A Web Service is an application that can be accessed over a network, such as the internet.
A Web Server is a program that delivers content over HTTP.

So, if you want your Web service to be accessed over the internet, you'll set it up on a Web Server.

Should we need to go too technical?

迟到的我 2024-08-27 00:34:59

我希望对您有用:

  • “Web 服务器”是一种服务器应用程序(如 Microsoft IIS 或 Apache),用于编译和运行网站或“Web 应用程序”。 “Web 服务器”也可以托管一些“Web 服务”。

  • “Web 服务”是安装在“Web 服务器”上的组件。这些组件可以由网站或“Web 应用程序”使用 HTTP 请求来调用。

如果您想了解更多信息,请参阅 MSDN,搜索“web 服务”字符串

Bye

I hope to be useful to you saying you that :

  • A "web server" is a server application (like Microsoft IIS or Apache) which is used to compile and run websites, or "web application". A "web server" can host some "web services" too.

  • A "web service" is a component installed over a "web server". These components could be called by a website or a "web application" using HTTP requests.

If you want more information about that consult MSDN, searching the "web service" string

Bye

我的黑色迷你裙 2024-08-27 00:34:59

也许从底层技术的角度来看,没有太大区别(通过通道的请求-响应),但目的使含义多样化:

  • Web服务器通常指的是为用户传递网页内容。
  • Web 服务是指可通过标准 Web 协议调用的 API。

当然,如今随着 Web 3.5 的到来,短语之间的界限变得模糊;)

Maybe from an underlying technology perspective there is not much difference (request-response going over a channel), but the purpose diversifies the meaning:

  • Web server usually refers to delivering web page content for a user.
  • Web service refers to an API invocable over standard web protocols.

Of course nowadays with the coming of Web 3.5 the borders between phrases becomes fuzzy ;)

白云悠悠 2024-08-27 00:34:59

要添加给定的答案,询问“Web 服务和(由服务器创建的)网页之间有什么区别”会更有意义。

从技术上讲,没有。它们都在请求后输出类似 XML 的内容。

To add to the given answers, it would make more sense to ask "What is the difference between a web service and a (by-server-created) web page".

Technically there is none. They both output something XML-ish after a request.

萧瑟寒风 2024-08-27 00:34:59

服务器是调度用户 HTTP 请求和托管 Web 项目(还包括 Web 服务)的“机器”。

Server is a "machine" to dispatch user HTTP request and host web project, including also web services.

谁的新欢旧爱 2024-08-27 00:34:59

Web 服务是一种特定类型的 Web 服务器,它(通常)提供一组任意客户端可以调用的方法:类似于远程 API 机制。

Web 服务器只是一个通用术语,不仅包括 Web 服务,还包括 http 服务器等。

Web Service is a specific kind of web server, which (usually) provides a set of methods which arbitrary clients can call: something like a remote API mechanism.

Web server is just a generic term and would include not just web services, but http servers etc.

深居我梦 2024-08-27 00:34:59

来自维基百科:

网络服务器是一种使用超文本传输​​协议传递(提供)内容(例如网页)的计算机程序。

如今的 Web 服务通常只是应用程序编程接口 (API) 或 Web API,可以通过网络(例如 Internet)访问并在托管所请求服务的远程系统上执行。

虽然两者都是某种计算机程序,但目的不同。 Web 服务器具有交付 Web 内容的特定目的,而 Web 服务则具有更广泛的作用。

From wikipedia:

A web server is a computer program that delivers (serves) content, such as web pages, using the Hypertext Transfer Protocol.

Web services today are frequently just Application Programming Interfaces (API) or web APIs that can be accessed over a network, such as the Internet, and executed on a remote system hosting the requested services.

Though both are some sort of a computer program but with different purpose. Web Server's have a specific purpose of delivering web content whereas Web Services have a broader role to play.

执笔绘流年 2024-08-27 00:34:59

因为还没有人提到过,所以 Web 服务有两种类型(在 Microsoft 领域):WCF 和 asmx。
WCF 服务由 IIS“托管”,asmx Web 服务在 IIS 内运行。 WCF 服务还可以由单独的自包含服务托管(并且您仍然可以使用 HTTP 连接到它)。

Web 服务是一个庞大的主题,您确实应该从像这里这样的地方开始。

Because no-one else has mentioned it yet, there are two types of webservice (in Microsoft land): WCF and asmx.
WCF services are "hosted" by IIS, asmx webservices run within IIS. WCF services can also be hosted by a separate self contained service (and you can still use HTTP to connect to it).

Webservices is a huge subject, you really should start somewhere like here.

南七夏 2024-08-27 00:34:59

本身没有确切的区别,但在这些术语的使用上下文中,它们的含义如下:

  • 术语Web服务器用于指代为与/进行通信而编写的软件。来自浏览器并最终通过浏览器提供人类可读的内容(HTML/JS/图像/视频)。
  • 另一方面,Web 服务旨在用于计算机之间的通信(人类不会消耗最终结果,而是计算机),例如本机移动/桌面应用程序、单点登录。它们通常输出 JSON 或 XML 文档。

从开发人员的角度进一步简化它。如果您生成 HTML 作为响应,那么它就是一个 Web 服务器。如果您的响应是 JSON 或 XML 文件,则它是一个 Web 服务。

There is no exact differentiation as such, but in the context of usage of these terms, this is what they would mean:

  • The term Web servers is used for a piece of software that is written for communication to/from browsers and ends up serving human readable content via a browser (HTML/JS/Images/Video).
  • Web services on the other hand are intended for communication between computers (humans do not consume the end result, instead computers do), for example native mobile/desktop apps, Single Sign Ons. They usually output JSON or an XML documents.

Simplifying it further from a developer's perspective. If you are generating HTML as a response, it is a web server. If your response is a JSON or an XML file its a web service.

々眼睛长脚气 2024-08-27 00:34:59

据我所知,“网络服务”是一个编程组件,提供某种功能,而“网络服务器”要么是运行软件以满足网络服务需求的机器,要么是软件本身。

To my knowledge, a "web service" is a programmed component, that provides a certain functionality, while a "web server" is either a machine that runs software to provide for web service's needs, or the software itself.

对岸观火 2024-08-27 00:34:59

Web 服务器是一个接受 HTTP 请求并通过给出 HTTP 响应进行响应的程序。

Web 服务是一种软件系统,旨在帮助机器之间的交互或通过网络从一个 Web 应用程序到另一个 Web 应用程序。

Web Server is a program which accepts HTTP requests and respond by giving HTTP responses.

Web services is a software system developed to help machine to machine interaction or from one web application to another web application over the network.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文