WO2012083806A1 - Http-based communication method and system, http server and http client - Google Patents

Http-based communication method and system, http server and http client Download PDF

Info

Publication number
WO2012083806A1
WO2012083806A1 PCT/CN2011/083929 CN2011083929W WO2012083806A1 WO 2012083806 A1 WO2012083806 A1 WO 2012083806A1 CN 2011083929 W CN2011083929 W CN 2011083929W WO 2012083806 A1 WO2012083806 A1 WO 2012083806A1
Authority
WO
WIPO (PCT)
Prior art keywords
http
connection
type
client
server
Prior art date
Application number
PCT/CN2011/083929
Other languages
French (fr)
Chinese (zh)
Inventor
石磊
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2012083806A1 publication Critical patent/WO2012083806A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]

Definitions

  • an interface between a server and a client may use a Hyper Text Transfer Protocol (HTTP)-based connection, that is, an HTTP connection, for example, an IP Multimedia Subsystem (IMS).
  • HTTP Hyper Text Transfer Protocol
  • the HTTP connection may include two types of connections, one is an HTTP temporary connection, and the other is an HTTP permanent connection. Both of the above HTTP connections need to be established before the client initiates an HTTP request to the server. The former is removed after the server returns an HTTP response to the client, and the latter is removed when no message is sent on the HTTP connection established over a period of time. Therefore, in order to avoid duplicate HTTP connections and HTTP connections, the above interfaces can use HTTP permanent connections.
  • HTTP response message where the HTTP response message includes the processing identifier information header field.
  • a receiving module configured to receive, by using a concurrent type of HTTP permanent connection, an HTTP request message sent by the client, where the HTTP request message includes a processing identifier information header field;
  • a sending module configured to send an HTTP request message to the server by using a persistent HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
  • the embodiment of the invention further provides a communication system based on the hypertext transfer protocol HTTP, including a client and a server, wherein:
  • the client is configured to send an HTTP request message to the server by using a concurrent type of HTTP permanent connection, where the HTTP request message includes a processing identifier information header field, and receiving the server return by using the concurrent type HTTP permanent connection.
  • the HTTP response message where the HTTP response message includes the processing identifier information header field;
  • the server is configured to receive the HTTP request message sent by the client by using the concurrent type HTTP persistent connection, and return the HTTP response message to the client by using the concurrent type HTTP permanent connection.
  • FIG. 5 is a schematic structural diagram of an HTTP client according to Embodiment 5 of the present invention.
  • FIG. 6 is a schematic structural diagram of an HTTP-based communication processing system according to Embodiment 6 of the present invention. detailed description
  • connection type header field may also be used to indicate a concurrency type. If the connection type header field is included in the HTTP connection request message sent by the client to the server, a concurrent type HTTP permanent connection is established, if the client sends the server to the server. The connection type header field is not included in the establishment HTTP connection request message, and a pipeline type HTTP permanent connection is established.
  • the specific form can be: 3 ⁇ 4 mouth:
  • a 406 error message may be returned to the client, so that the client re-initiates the establishment of the header field that does not contain the connection type to the server.
  • the foregoing processing identifier information header field may be defined as a decimal positive integer, and the value ranges from 0 to 4294967295, and may be used for matching HTTP response messages and HTTP request messages on the HTTP type persistent connection of the concurrent type, and the specific form may be As follows:
  • the HTTP response message may include, but is not limited to, a GET response message, an OPTIONS response message.
  • the foregoing HTTP response message may be a success response message, or may also be a failure response message.
  • connection type header field may be used to indicate a concurrency type or a pipeline type, if the connection type header field indication included in the HTTP connection request message sent by the client to the server is sent to the server.
  • the concurrency type establishes a persistent type of HTTP persistent connection. If the connection type header field included in the HTTP connection request message sent by the client to the server indicates the pipeline type, a pipeline type HTTP permanent connection is established.
  • the specific form can be as follows:
  • the proxy device needs to be able to support transparent transmission of the above connection type header field.
  • Step 304 The AS returns a GET response message to the MRFC, where the GET response message includes the foregoing processing identifier information header field.
  • the MRFC sends an HTTP request message including a processing identifier information header field to the AS through a concurrent type HTTP persistent connection, so that the AS can pass the above-mentioned concurrent type HTTP.
  • the permanent connection returns an HTTP response message containing the above-mentioned processing identification information header field to the MRFC, so that multiple HTTP requests can be processed through a concurrent HTTP persistent connection, thereby reducing the complexity of the Sr interface configuration management and maintenance, and improving the complexity. The efficiency of the Sr interface.
  • the HTTP server in this embodiment may include a receiving module 41 and a sending module 42.
  • the receiving module 41 receives the HTTP request message sent by the client by using a persistent type HTTP persistent connection, where the HTTP request message includes a processing identifier information header field, and the sending module 42 returns the HTTP to the client by using the concurrent type HTTP permanent connection.
  • the HTTP response message includes the foregoing processing identifier information header field.
  • the functions of the server in the first embodiment of the present invention and the AS in the third embodiment of the present invention can be implemented by the HTTP server provided by the embodiment of the present invention.
  • the receiving module receives the HTTP request message that is sent by the client and includes the processing identifier information header field by using the HTTP type persistent connection of the concurrent type, so that the sending module can return the foregoing processing to the client by using the HTTP type permanent connection of the concurrent type.
  • the HTTP response message identifying the information header field enables multiple HTTP requests to be processed through a concurrent type of HTTP persistent connection, thereby reducing the complexity of interface configuration management and maintenance using HTTP connections, and improving the interface using HTTP connections. s efficiency.
  • the HTTP server of this embodiment may further include an establishing module 43, Interact with the above client to establish the HTTP type permanent connection of the above concurrency type.
  • the establishing module 43 is specifically configured to receive an HTTP connection request message sent by the client, where the HTTP connection request message includes a connection type header field, and is established between the client and the client according to the connection type header field. Concurrent type of HTTP permanent connection.
  • the server 62 is configured to receive the above HTTP request message sent by the client 61 through the HTTP type persistent connection of the concurrency type described above, and to the client through the HTTP type persistent connection of the concurrency type described above.
  • the function of the client in the second embodiment of the present invention and the function of the MRFC in the third embodiment of the present invention can be implemented by the client 61 in the HTTP-based communication processing system provided by the embodiment of the present invention;
  • the functions of the AS in the third embodiment of the present invention can be implemented by the server 62 in the HTTP-based communication processing system provided by the embodiment of the present invention.
  • the HTTP persistent connection returns an HTTP response message including the above-mentioned processing identification information header field to the above client, so that multiple HTTP requests can be processed through a concurrent type of HTTP permanent connection, thereby reducing interface configuration management and maintenance using HTTP connection. Complexity, and the efficiency of interfaces that use HTTP connections.
  • the client 61 in this embodiment may be further configured to interact with the server 62 to establish the HTTP type permanent connection of the concurrency type.
  • the server 62 may further be configured to interact with the client 61 to establish the foregoing. Concurrent type of HTTP permanent connection.

Abstract

The present invention provides an HTTP-based communication method and system, an HTTP server and an HTTP client. The method comprises: a server receiving, through an HTTP permanent connection of a concurrency type, an HTTP request message sent by a client, wherein the HTTP request message comprises a header field of processing identification information; and the server returning, through the HTTP permanent connection of the concurrency type, an HTTP response message to the client, wherein the HTTP response message comprises the header field of the processing identification information.

Description

基于 HTTP的通信方法及系统、 HTTP服务器、 HTTP客户端 本申请要求了 2010年 12月 21 日提交的、申请号为 201010613201 .0、 发明名称为 "基于 HTTP的通信方法及系统、 HTTP服务器、 HTTP客户 端" 的中国申请的优先权, 其全部内容通过引用结合在本申请中。  HTTP-based communication method and system, HTTP server, HTTP client This application claims the application number of 201010613201 . 0, the invention name is "HTTP-based communication method and system, HTTP server, HTTP" submitted on December 21, 2010. The priority of the Chinese application of the "client" is incorporated herein by reference in its entirety.
技术领域 Technical field
本发明实施例涉及通信技术,尤其涉及基于超文本传输协议 ( Hyper Text Transfer Protocol, 简称 HTTP ) 的通信方法及系统、 HTTP月良务器、 HTTP 客户端。 背景技术  The embodiments of the present invention relate to communication technologies, and in particular, to a Hypertext Transfer Protocol (HTTP)-based communication method and system, an HTTP server, and an HTTP client. Background technique
在通信系统中, 服务器与客户端之间的接口可以使用基于超文本传输 协议 ( Hyper Text Transfer Protocol , 简称 HTTP ) 连接即 HTTP连接, 例如: IP多媒体子系统 (IP Multimedia Subsystem , 简称 IMS ) 中, 应 用服务器 (Application Server , 简称 AS ) 与多媒体资源功能控制器 ( Multimedia Resource Function Controller, 简称 MRFC )之间的 Sr接 口。 其中, 上述 HTTP连接可以包括两种连接, 一种是 HTTP临时连接, 一种是 HTTP永久连接。上述两种 HTTP连接都需要在客户端向服务器发 起 HTTP请求前建立, 前者在服务器向客户端返回 HTTP响应后拆除, 后 者是在一段时间内建立的 HTTP连接上没有任何消息发送时拆除。 因此, 为了避免重复的建立 HTTP连接和拆除 HTTP连接, 上述接口可以使用 HTTP 永久连接。 HTTP 永久连接可以包括两种类型, 一种是并行 ( parallelism )方式的 HTTP永久连接, 另一种是流水线 ( pipelining )类 型的 HTTP 永久连接。 当存在多个用户同时通过客户端向服务器发起 HTTP请求时, 前者需要同时建立多条 HTTP永久连接才能实现以并行方 式同时处理多个用户的 HTTP请求, 后者只需要一条流水线类型的 HTTP 永久连接就能实现以流水线方式依次处理多个用户的 HTTP请求。 In a communication system, an interface between a server and a client may use a Hyper Text Transfer Protocol (HTTP)-based connection, that is, an HTTP connection, for example, an IP Multimedia Subsystem (IMS). The Sr interface between the Application Server (AS) and the Multimedia Resource Function Controller (MRFC). The HTTP connection may include two types of connections, one is an HTTP temporary connection, and the other is an HTTP permanent connection. Both of the above HTTP connections need to be established before the client initiates an HTTP request to the server. The former is removed after the server returns an HTTP response to the client, and the latter is removed when no message is sent on the HTTP connection established over a period of time. Therefore, in order to avoid duplicate HTTP connections and HTTP connections, the above interfaces can use HTTP permanent connections. HTTP persistent connections can include two types, one is a parallel permanent (HTTP) permanent connection, and the other is a pipelining type of HTTP permanent connection. When multiple users simultaneously initiate HTTP requests to the server through the client, the former needs to establish multiple HTTP permanent connections at the same time to implement HTTP requests for multiple users simultaneously in parallel. The latter only needs one pipeline type HTTP. A permanent connection enables sequential processing of HTTP requests from multiple users in a pipelined manner.
上述现有技术中, 如果使用 HTTP连接的接口使用并行方式的 HTTP 永久连接, 需要同时建立多条 HTTP永久连接, 才能实现以并行方式同时 处理多个用户的 HTTP请求, 增加了接口配置管理和维护的复杂性; 如果 使用 HTTP连接的接口使用流水线类型的 HTTP永久连接, 需要对 HTTP 请求与 HTTP响应进行保序, 降低了接口的效率。 发明内容  In the above prior art, if an HTTP-connected interface uses a parallel HTTP persistent connection, multiple HTTP permanent connections need to be established at the same time, so that HTTP requests of multiple users can be processed simultaneously in parallel, and interface configuration management and maintenance are added. Complexity; if an HTTP-connected interface uses a pipeline-type HTTP persistent connection, the HTTP request and the HTTP response need to be preserved, reducing the efficiency of the interface. Summary of the invention
本发明实施例提供基于 HTTP 的通信方法及系统、 HTTP 服务器、 HTTP客户端,用以降低使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高使用 HTTP连接的接口的效率。  The embodiments of the present invention provide an HTTP-based communication method and system, an HTTP server, and an HTTP client, which are used to reduce the complexity of interface configuration management and maintenance using an HTTP connection, and improve the efficiency of an interface using an HTTP connection.
本发明实施例提供了一种基于 HTTP的通信方法, 包括:  An embodiment of the present invention provides an HTTP-based communication method, including:
服务器通过并发类型的 HTTP永久连接接收客户端发送的 HTTP请求消 息, 所述 HTTP请求消息中包含处理标识信息头域;  The server receives the HTTP request message sent by the client by using a persistent type HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
所述服务器通过所述并发类型的 HTTP永久连接向所述客户端返回 The server returns to the client through the concurrent type HTTP persistent connection
HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。 An HTTP response message, where the HTTP response message includes the processing identifier information header field.
本发明实施例提供了另一种基于 HTTP的通信方法, 包括:  An embodiment of the present invention provides another HTTP-based communication method, including:
客户端通过并发类型的 HTTP永久连接向服务器发送 HTTP请求消息, 所述 HTTP请求消息中包含处理标识信息头域;  The client sends an HTTP request message to the server by using a persistent HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
所述客户端通过所述并发类型的 HTTP永久连接接收所述服务器返回 的 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。  The client receives the HTTP response message returned by the server by using the HTTP type persistent connection of the concurrent type, where the HTTP response message includes the processing identifier information header field.
本发明实施例还提供了一种 HTTP服务器, 包括:  An embodiment of the present invention further provides an HTTP server, including:
接收模块,用于通过并发类型的 HTTP永久连接接收客户端发送的 HTTP 请求消息, 所述 HTTP请求消息中包含处理标识信息头域;  a receiving module, configured to receive, by using a concurrent type of HTTP permanent connection, an HTTP request message sent by the client, where the HTTP request message includes a processing identifier information header field;
发送模块, 用于通过所述并发类型的 HTTP永久连接向所述客户端返 回 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。 本发明实施例还提供了一种 HTTP客户端, 包括: And a sending module, configured to return an HTTP response message to the client by using the HTTP persistent connection of the concurrent type, where the HTTP response message includes the processing identifier information header field. An embodiment of the present invention further provides an HTTP client, including:
发送模块, 用于通过并发类型的 HTTP永久连接向服务器发送 HTTP请 求消息, 所述 HTTP请求消息中包含处理标识信息头域;  a sending module, configured to send an HTTP request message to the server by using a persistent HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
接收模块, 用于通过所述并发类型的 HTTP永久连接接收所述服务器 返回的 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头 域。  And a receiving module, configured to receive, by using the HTTP type persistent connection of the concurrent type, an HTTP response message returned by the server, where the HTTP response message includes the processing identifier information header field.
本发明实施例再提供了一种基于超文本传输协议 HTTP的通信系统, 包 括客户端和服务器, 其中:  The embodiment of the invention further provides a communication system based on the hypertext transfer protocol HTTP, including a client and a server, wherein:
所述客户端用于通过并发类型的 HTTP 永久连接向所述服务器发送 HTTP请求消息, 所述 HTTP请求消息中包含处理标识信息头域, 以及通过 所述并发类型的 HTTP永久连接接收所述服务器返回的 HTTP响应消息, 所 述 HTTP响应消息中包含所述处理标识信息头域;  The client is configured to send an HTTP request message to the server by using a concurrent type of HTTP permanent connection, where the HTTP request message includes a processing identifier information header field, and receiving the server return by using the concurrent type HTTP permanent connection. The HTTP response message, where the HTTP response message includes the processing identifier information header field;
所述服务器用于通过所述并发类型的 HTTP永久连接接收所述客户端 发送的所述 HTTP请求消息,以及通过所述并发类型的 HTTP永久连接向所 述客户端返回所述 HTTP响应消息。  The server is configured to receive the HTTP request message sent by the client by using the concurrent type HTTP persistent connection, and return the HTTP response message to the client by using the concurrent type HTTP permanent connection.
由上述技术方案可知,本发明实施例服务器通过并发类型的 HTTP永 久连接接收客户端发送的包含处理标识信息头域的 HTTP请求消息,使得 能够通过上述并发类型的 HTTP永久连接向上述客户端返回包含上述处理 标识信息头域的 HTTP响应消息,实现了通过一条并发类型的 HTTP永久 连接可以处理多个 HTTP请求,从而降低了使用 HTTP连接的接口配置管 理和维护的复杂性, 以及提高了使用 HTTP连接的接口的效率。 附图说明  According to the foregoing technical solution, the server of the embodiment of the present invention receives the HTTP request message that is sent by the client and includes the processing identifier information header field by using the HTTP type persistent connection of the concurrency type, so that the HTTP persistent connection of the concurrency type can be returned to the client. The above process identifies the HTTP response message in the header field, which enables multiple HTTP requests to be processed through a concurrent type of HTTP persistent connection, thereby reducing the complexity of interface configuration management and maintenance using HTTP connections, and improving the use of HTTP connections. The efficiency of the interface. DRAWINGS
为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实 施例或现有技术描述中所需要使用的附图作一简单地介绍, 显而易见地, 下 面描述中的附图是本发明的一些实施例, 对于本领域普通技术人员来讲, 在 不付出创造性劳动的前提下, 还可以根据这些附图获得其他的附图。 In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, a brief description of the drawings used in the embodiments or the prior art description will be briefly described below, obviously, The drawings in the above description are some embodiments of the present invention, and those skilled in the art can obtain other drawings based on these drawings without any creative work.
图 1为本发明实施例一提供的一种基于 HTTP的通信方法的流程示意 图;  1 is a schematic flow chart of a method for communicating based on HTTP according to Embodiment 1 of the present invention;
图 2为本发明实施例二提供的另一种基于 HTTP的通信方法的流程示 意图;  2 is a schematic flowchart of another HTTP-based communication method according to Embodiment 2 of the present invention;
图 3为本发明实施例三提供的基于 HTTP的通信处理方法的流程示意 图;  FIG. 3 is a schematic flow chart of a HTTP-based communication processing method according to Embodiment 3 of the present invention; FIG.
图 4为本发明实施例四提供的 HTTP服务器的结构示意图;  4 is a schematic structural diagram of an HTTP server according to Embodiment 4 of the present invention;
图 5为本发明实施例五提供的 HTTP客户端的结构示意图;  FIG. 5 is a schematic structural diagram of an HTTP client according to Embodiment 5 of the present invention;
图 6为本发明实施例六提供的基于 HTTP的通信处理系统的结构示意 图。 具体实施方式  FIG. 6 is a schematic structural diagram of an HTTP-based communication processing system according to Embodiment 6 of the present invention. detailed description
为使本发明实施例的目的、 技术方案和优点更加清楚, 下面将结合本发 明实施例中的附图, 对本发明实施例中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部的实施例。 基于 本发明中的实施例, 本领域普通技术人员在没有作出创造性劳动前提下所获 得的所有其他实施例, 都属于本发明保护的范围。  The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is a partial embodiment of the invention, and not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
如果使用 HTTP连接的接口使用并行( parallelism )方式的 HTTP永久 连接, 需要同时建立多条 HTTP永久连接, 才能实现以并行方式同时处理多 个用户的 HTTP请求,增加了接口配置管理和维护的复杂性;如果使用 HTTP 连接的接口使用流水线(pipelining )类型的 HTTP永久连接, 需要对 HTTP 请求与 HTTP响应进行保序, 降低了接口的效率。 因此, 本发明实施例提出 另外一种 HTTP永久连接, 即并发( concurrence )类型的 HTTP永久连接。  If an HTTP connection interface uses a parallel permanent HTTP connection, multiple HTTP persistent connections need to be established at the same time, so that HTTP requests of multiple users can be processed simultaneously in parallel, which increases the complexity of interface configuration management and maintenance. If an HTTP-connected interface uses a pipelining type of HTTP persistent connection, the HTTP request and the HTTP response need to be preserved, reducing the efficiency of the interface. Therefore, the embodiment of the present invention proposes another HTTP permanent connection, that is, a concurrence type HTTP permanent connection.
图 1为本发明实施例一提供的一种基于 HTTP的通信方法的流程示意图, 如图 1所示, 本实施例的基于 HTTP的通信方法可以包括以下步骤: 步骤 101、 服务器通过并发类型的 HTTP 永久连接接收客户端发送的 HTTP请求消息,上述 HTTP请求消息中包含处理标识信息( Transaction-Id ) 头域; 1 is a schematic flowchart of a communication method based on HTTP according to Embodiment 1 of the present invention, where As shown in FIG. 1, the HTTP-based communication method of this embodiment may include the following steps: Step 101: A server receives an HTTP request message sent by a client by using a concurrent type HTTP persistent connection, where the HTTP request message includes processing identifier information ( Transaction-Id) header field;
其中的 HTTP请求消息可以包括但不限于 GET请求消息、 OPTIONS请 求消息。  The HTTP request message may include, but is not limited to, a GET request message and an OPTIONS request message.
具体地, 上述处理标识信息头域可以定义为一个十进制的正整数, 取值 范围为 0 ~ 4294967295,可以用于并发类型的 HTTP永久连接上的 HTTP响 应消息与 HTTP请求消息的匹配, 具体形式可以如下所示:  Specifically, the foregoing processing identifier information header field may be defined as a decimal positive integer, and the value ranges from 0 to 4294967295, and may be used for matching HTTP response messages and HTTP request messages on the HTTP type persistent connection of the concurrent type, and the specific form may be As follows:
Transaction-Id = "Transaction -Id" ":" 1*DIGIT  Transaction-Id = "Transaction -Id" ":" 1*DIGIT
本领域技术人员可以理解的是: 如果客户端与服务器之间存在代理 ( Proxy )设备, 则该代理设备需要能够支持透传上述处理标识信息头域。  Those skilled in the art can understand that if there is a proxy device between the client and the server, the proxy device needs to be able to support transparent transmission of the above-mentioned processing identifier information header field.
步骤 102、 上述服务器通过上述并发类型的 HTTP永久连接向上述客户 端返回 HTTP响应消息,上述 HTTP响应消息中包含上述处理标识信息头域。  Step 102: The server returns an HTTP response message to the client by using the HTTP persistent connection of the concurrency type, where the HTTP response message includes the processing identifier information header field.
其中的 HTTP响应消息可以包括但不限于 GET响应消息、 OPTIONS响 应消息。  The HTTP response message may include, but is not limited to, a GET response message, an OPTIONS response message.
具体地, 上述 HTTP响应消息具体可以为成功响应消息, 或者还可以为 失败响应消息。  Specifically, the foregoing HTTP response message may be a success response message, or may also be a failure response message.
进一步地, 在上述步骤 101之前, 还可以进一步包括上述服务器与上述 客户端进行交互, 建立上述并发类型的 HTTP永久连接的步骤。 具体地, 上 述服务器接收上述客户端发送的建立 HTTP连接请求消息, 上述建立 HTTP 连接请求消息中包含连接类型( Connection-Type )头域, 上述服务器根据上 述连接类型头域, 建立与上述客户端之间的并发类型的 HTTP永久连接。  Further, before the foregoing step 101, the method further includes the step of the server interacting with the client to establish the HTTP type permanent connection of the concurrent type. Specifically, the server receives the setup HTTP connection request message sent by the client, where the establishment HTTP connection request message includes a connection type (Connection-Type) header field, and the server establishes a connection with the client according to the connection type header field. A concurrent type of HTTP persistent connection.
具体地, 上述连接类型头域可以用于指示并发类型或流水线类型, 如果 客户端向服务器发送的建立 HTTP连接请求消息中包含的连接类型头域指示 并发类型, 则建立并发类型的 HTTP永久连接, 如果客户端向服务器发送的 建立 HTTP连接请求消息中包含的连接类型头域指示流水线类型, 则建立流 水线类型的 HTTP永久连接。 具体形式可以如下所示: Specifically, the connection type header field may be used to indicate a concurrency type or a pipeline type. If the connection type header field included in the setup HTTP connection request message sent by the client to the server indicates the concurrency type, a concurrent type HTTP persistent connection is established. If the client sends it to the server Establish a connection type header field contained in the HTTP connection request message indicating the pipeline type, and then establish a pipeline type HTTP permanent connection. The specific form can be as follows:
Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = pipelining | concurrence  Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = pipelining | concurrence
或者, 上述连接类型头域还可以用于指示并发类型, 如果客户端向服务 器发送的建立 HTTP连接请求消息中包含该连接类型头域, 则建立并发类型 的 HTTP永久连接, 如果客户端向服务器发送的建立 HTTP连接请求消息中 没有包含该连接类型头域, 则建立流水线类型的 HTTP永久连接。 具体形式 可以: ¾口下所示:  Alternatively, the foregoing connection type header field may also be used to indicate a concurrency type. If the connection type header field is included in the HTTP connection request message sent by the client to the server, a concurrent type HTTP permanent connection is established, if the client sends the server to the server. The connection type header field is not included in the establishment HTTP connection request message, and a pipeline type HTTP permanent connection is established. The specific form can be: 3⁄4 mouth:
Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = concurrence  Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = concurrence
本领域技术人员可以理解的是: 如果客户端与服务器之间存在代理 ( Proxy )设备, 则该代理设备需要能够支持透传上述连接类型头域。  Those skilled in the art can understand that if there is a proxy device between the client and the server, the proxy device needs to be able to support transparent transmission of the above connection type header field.
进一步地,如果服务器不支持上述连接类型头域,可以向客户端返回 406 错误消息, 以使客户端重新向该服务器发起不包含该连接类型头域的建立 Further, if the server does not support the above connection type header field, a 406 error message may be returned to the client, so that the client re-initiates the establishment of the header field that does not contain the connection type to the server.
HTTP连接请求消息, 按照现有技术中的方法, 建立流水线类型的 HTTP永 久连接或建立多条并行方式的 HTTP永久连接。 The HTTP connection request message, according to the method in the prior art, establishes a pipeline type HTTP persistent connection or establishes multiple parallel HTTP permanent connections.
进一步地,当存在多个用户同时通过客户端向服务器发起 HTTP请求时, 采用本实施例提供的基于 HTTP的通信方法, 能够通过建立的一条并发类型 的 HTTP永久连接, 实现以并发方式同时处理多个用户的 HTTP请求。  Further, when there are multiple users simultaneously requesting an HTTP request to the server through the client, the HTTP-based communication method provided by the embodiment can implement concurrent processing in a concurrent manner by establishing a persistent HTTP persistent connection. HTTP requests from users.
本实施例中, 服务器通过并发类型的 HTTP永久连接接收客户端发送的 包含处理标识信息头域的 HTTP 请求消息, 使得能够通过上述并发类型的 In this embodiment, the server receives the HTTP request message that is sent by the client and includes the processing identifier information header field by using the HTTP type persistent connection of the concurrency type, so that the concurrency type can be adopted.
HTTP永久连接向上述客户端返回包含上述处理标识信息头域的 HTTP响应 消息,实现了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低了使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高了使 用 HTTP连接的接口的效率。 图 2为本发明实施例二提供的另一种基于 HTTP的通信方法的流程示意 图, 如图 2所示, 本实施例的基于 HTTP的通信方法可以包括以下步骤: 步骤 201、 客户端通过并发类型的 HTTP永久连接向服务器发送 HTTP 请求消息,上述 HTTP请求消息中包含处理标识信息( Transaction-Id )头域; 其中的 HTTP请求消息可以包括但不限于 GET请求消息、 OPTIONS请 求消息。 The HTTP persistent connection returns an HTTP response message including the above-mentioned processing identification information header field to the above client, so that multiple HTTP requests can be processed through a concurrent type of HTTP permanent connection, thereby reducing interface configuration management and maintenance using HTTP connection. Complexity, and the efficiency of interfaces that use HTTP connections. FIG. 2 is a schematic flowchart of another HTTP-based communication method according to Embodiment 2 of the present invention. As shown in FIG. 2, the HTTP-based communication method in this embodiment may include the following steps: Step 201: A client passes a concurrency type. The HTTP persistent connection sends an HTTP request message to the server, where the HTTP request message includes a processing identifier information (Transaction-Id) header field; wherein the HTTP request message may include but is not limited to a GET request message and an OPTIONS request message.
具体地, 上述处理标识信息头域可以定义为一个十进制的正整数, 取值 范围为 0 ~ 4294967295,可以用于并发类型的 HTTP永久连接上的 HTTP响 应消息与 HTTP请求消息的匹配, 具体形式可以如下所示:  Specifically, the foregoing processing identifier information header field may be defined as a decimal positive integer, and the value ranges from 0 to 4294967295, and may be used for matching HTTP response messages and HTTP request messages on the HTTP type persistent connection of the concurrent type, and the specific form may be As follows:
Transaction-Id = "Transaction -Id" ":" 1*DIGIT  Transaction-Id = "Transaction -Id" ":" 1*DIGIT
本领域技术人员可以理解的是: 如果客户端与服务器之间存在代理 ( Proxy )设备, 则该代理设备需要能够支持透传上述处理标识信息头域。  Those skilled in the art can understand that if there is a proxy device between the client and the server, the proxy device needs to be able to support transparent transmission of the above-mentioned processing identifier information header field.
步骤 202、 上述客户端通过上述并发类型的 HTTP永久连接接收上述服 务器返回的 HTTP响应消息, 上述 HTTP响应消息中包含上述处理标识信息 头域。  Step 202: The client receives the HTTP response message returned by the server by using the HTTP persistent connection of the concurrency type, where the HTTP response message includes the processing identifier information header field.
其中的 HTTP响应消息可以包括但不限于 GET响应消息、 OPTIONS响 应消息。  The HTTP response message may include, but is not limited to, a GET response message, an OPTIONS response message.
具体地, 上述 HTTP响应消息具体可以为成功响应消息, 或者还可以为 失败响应消息。  Specifically, the foregoing HTTP response message may be a success response message, or may also be a failure response message.
进一步地, 在上述步骤 101之前, 还可以进一步包括上述客户端与上述 服务器进行交互, 建立上述并发类型的 HTTP永久连接的步骤。 具体地, 上 述客户端向上述服务器发送建立 HTTP连接请求消息, 上述建立 HTTP连接 请求消息中包含连接类型(Connection-Type )头域, 以使上述服务器根据上 述连接类型头域, 建立与上述客户端之间的并发类型的 HTTP永久连接。  Further, before the foregoing step 101, the method further includes the step of the client interacting with the server to establish the HTTP type permanent connection of the concurrent type. Specifically, the client sends an HTTP connection request message to the server, where the HTTP connection request message includes a connection type (Connection-Type) header field, so that the server establishes the client with the connection type header field. A persistent connection between HTTP types.
具体地, 上述连接类型头域可以用于指示并发类型或流水线类型, 如果 客户端向服务器发送的建立 HTTP连接请求消息中包含的连接类型头域指示 并发类型, 则建立并发类型的 HTTP永久连接, 如果客户端向服务器发送的 建立 HTTP连接请求消息中包含的连接类型头域指示流水线类型, 则建立流 水线类型的 HTTP永久连接。 具体形式可以如下所示: Specifically, the foregoing connection type header field may be used to indicate a concurrency type or a pipeline type, if the connection type header field indication included in the HTTP connection request message sent by the client to the server is sent to the server. The concurrency type establishes a persistent type of HTTP persistent connection. If the connection type header field included in the HTTP connection request message sent by the client to the server indicates the pipeline type, a pipeline type HTTP permanent connection is established. The specific form can be as follows:
Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = pipelining | concurrence  Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = pipelining | concurrence
或者, 上述连接类型头域还可以用于指示并发类型, 如果客户端向服务 器发送的建立 HTTP连接请求消息中包含该连接类型头域, 则建立并发类型 的 HTTP永久连接, 如果客户端向服务器发送的建立 HTTP连接请求消息中 没有包含该连接类型头域, 则建立流水线类型的 HTTP永久连接。 具体形式 可以^口下所示:  Alternatively, the foregoing connection type header field may also be used to indicate a concurrency type. If the connection type header field is included in the HTTP connection request message sent by the client to the server, a concurrent type HTTP permanent connection is established, if the client sends the server to the server. The connection type header field is not included in the establishment HTTP connection request message, and a pipeline type HTTP permanent connection is established. The specific form can be shown below:
Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = concurrence  Connection-Type = "Connection-Type" ":" 1#(connection-type) connection-type = concurrence
本领域技术人员可以理解的是: 如果客户端与服务器之间存在代理 ( Proxy )设备, 则该代理设备需要能够支持透传上述连接类型头域。  Those skilled in the art can understand that if there is a proxy device between the client and the server, the proxy device needs to be able to support transparent transmission of the above connection type header field.
进一步地,如果服务器不支持上述连接类型头域,可以向客户端返回 406 错误消息, 以使客户端重新向该服务器发起不包含该连接类型头域的建立 HTTP连接请求消息, 按照现有技术中的方法, 建立流水线类型的 HTTP永 久连接或建立多条并行方式的 HTTP永久连接。  Further, if the server does not support the connection type header field, a 406 error message may be returned to the client, so that the client re-initiates an HTTP connection request message that does not include the connection type header field to the server, according to the prior art. The method of establishing a pipeline type of HTTP permanent connection or establishing multiple HTTP parallel connections in parallel.
进一步地,当存在多个用户同时通过客户端向服务器发起 HTTP请求时, 采用本实施例提供的基于 HTTP的通信方法, 能够通过建立的一条并发类型 的 HTTP永久连接, 实现以并发方式同时处理多个用户的 HTTP请求。  Further, when there are multiple users simultaneously requesting an HTTP request to the server through the client, the HTTP-based communication method provided by the embodiment can implement concurrent processing in a concurrent manner by establishing a persistent HTTP persistent connection. HTTP requests from users.
本实施例中, 客户端通过并发类型的 HTTP永久连接向服务器发送包含 处理标识信息头域的 HTTP请求消息, 使得能够通过上述并发类型的 HTTP 永久连接接收上述服务器返回的包含上述处理标识信息头域的 HTTP响应消 息, 实现了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低了使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高了使 用 HTTP连接的接口的效率。 In this embodiment, the client sends an HTTP request message including a processing identifier information header field to the server through the HTTP type persistent connection of the concurrent type, so that the header type including the processing identifier information returned by the server is received through the HTTP type persistent connection of the concurrent type. HTTP response message, which can handle multiple HTTP requests through a concurrent HTTP persistent connection, which reduces the complexity of interface configuration management and maintenance using HTTP connections, and improves the complexity. The efficiency of the interface connected with HTTP.
以 IMS为例, 对上述本发明实施例一和上述本发明实施例二的技术方案 进行详细说明。 图 3为本发明实施例三提供的基于 HTTP的通信处理方法的 流程示意图, 如图 3所示, 本实施例的基于 HTTP的通信处理方法可以包括 以下步骤:  The technical solution of the first embodiment of the present invention and the above-mentioned second embodiment of the present invention will be described in detail by taking the IMS as an example. FIG. 3 is a schematic flowchart of a HTTP-based communication processing method according to Embodiment 3 of the present invention. As shown in FIG. 3, the HTTP-based communication processing method in this embodiment may include the following steps:
步骤 301、 MRFC向 AS发送建立 HTTP连接请求消息,上述建立 HTTP 连接请求消息中包含连接类型头域, 该连接类型头域指示并发类型;  Step 301: The MRFC sends an HTTP connection request message to the AS, where the HTTP connection request message includes a connection type header field, where the connection type header field indicates a concurrency type.
步骤 302、 AS根据上述连接类型头域, 建立与 MRFC之间的并发类型 的 HTTP永久连接, 并向 MRFC返回建立 HTTP连接响应消息;  Step 302: The AS establishes an HTTP permanent connection of a concurrency type with the MRFC according to the connection type header field, and returns an HTTP connection response message to the MRFC.
步骤 303、 MRFC向 AS发送 GET请求消息, 上述 GET请求消息中包 含处理标识信息头域;  Step 303: The MRFC sends a GET request message to the AS, where the GET request message includes a processing identifier information header field.
例如:  E.g:
GET http://154.48.0.80:80/PromptRecogAndPlayDTMF.vxml HTTP/1.1 Transaction-Id: 8118  GET http://154.48.0.80:80/PromptRecogAndPlayDTMF.vxml HTTP/1.1 Transaction-Id: 8118
Content-Length: 0  Content-Length: 0
Host: 154.48.0.80:80  Host: 154.48.0.80:80
Cache-Control: max-age= 1800000, max-stale= 1200000  Cache-Control: max-age= 1800000, max-stale= 1200000
步骤 304、 AS向 MRFC返回 GET响应消息, 上述 GET响应消息中包 含上述处理标识信息头域。  Step 304: The AS returns a GET response message to the MRFC, where the GET response message includes the foregoing processing identifier information header field.
例如:  E.g:
HTTP/1.1 200 OK  HTTP/1.1 200 OK
Transaction-Id: 8118  Transaction-Id: 8118
Content-Length: 14057  Content-Length: 14057
<?xml version="1.0" encoding="UTF-8"?>  <?xml version="1.0" encoding="UTF-8"?>
....vxml body....  ....vxml body....
本实施例中, MRFC通过并发类型的 HTTP永久连接向 AS发送包含处 理标识信息头域的 HTTP请求消息,使得 AS能够通过上述并发类型的 HTTP 永久连接向 MRFC返回包含上述处理标识信息头域的 HTTP响应消息,实现 了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低 了 Sr接口配置管理和维护的复杂性, 以及提高了 Sr接口的效率。 In this embodiment, the MRFC sends an HTTP request message including a processing identifier information header field to the AS through a concurrent type HTTP persistent connection, so that the AS can pass the above-mentioned concurrent type HTTP. The permanent connection returns an HTTP response message containing the above-mentioned processing identification information header field to the MRFC, so that multiple HTTP requests can be processed through a concurrent HTTP persistent connection, thereby reducing the complexity of the Sr interface configuration management and maintenance, and improving the complexity. The efficiency of the Sr interface.
需要说明的是: 对于前述的各方法实施例, 为了简单描述, 故将其都 表述为一系列的动作组合, 但是本领域技术人员应该知悉, 本发明并不受 所描述的动作顺序的限制, 因为依据本发明, 某些步骤可以采用其他顺序 或者同时进行。 其次, 本领域技术人员也应该知悉, 说明书中所描述的实 施例均属于优选实施例, 所涉及的动作和模块并不一定是本发明所必须 的。  It should be noted that, for the foregoing method embodiments, for the sake of simple description, they are all expressed as a series of action combinations, but those skilled in the art should understand that the present invention is not limited by the described action sequence. Because certain steps may be performed in other sequences or concurrently in accordance with the present invention. Further, those skilled in the art should also understand that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
在上述实施例中, 对各个实施例的描述都各有侧重, 某个实施例中没 有详述的部分, 可以参见其他实施例的相关描述。  In the above embodiments, the descriptions of the various embodiments are different, and the details are not described in detail in an embodiment, and the related descriptions of other embodiments can be referred to.
图 4为本发明实施例四提供的 HTTP服务器的结构示意图,如图 4所示, 本实施例的 HTTP服务器可以包括接收模块 41和发送模块 42。 其中, 接收 模块 41通过并发类型的 HTTP永久连接接收客户端发送的 HTTP请求消息, 上述 HTTP请求消息中包含处理标识信息头域, 发送模块 42通过上述并发 类型的 HTTP永久连接向上述客户端返回 HTTP响应消息, 上述 HTTP响应 消息中包含上述处理标识信息头域。  4 is a schematic structural diagram of an HTTP server according to Embodiment 4 of the present invention. As shown in FIG. 4, the HTTP server in this embodiment may include a receiving module 41 and a sending module 42. The receiving module 41 receives the HTTP request message sent by the client by using a persistent type HTTP persistent connection, where the HTTP request message includes a processing identifier information header field, and the sending module 42 returns the HTTP to the client by using the concurrent type HTTP permanent connection. In response to the message, the HTTP response message includes the foregoing processing identifier information header field.
上述本发明实施例一中服务器、 本发明实施例三中 AS的功能均可以 由本发明实施例提供的 HTTP服务器实现。  The functions of the server in the first embodiment of the present invention and the AS in the third embodiment of the present invention can be implemented by the HTTP server provided by the embodiment of the present invention.
本实施例中, 接收模块通过并发类型的 HTTP永久连接接收客户端发送 的包含处理标识信息头域的 HTTP请求消息, 使得发送模块能够通过上述并 发类型的 HTTP 永久连接向上述客户端返回包含上述处理标识信息头域的 HTTP响应消息, 实现了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低了使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高了使用 HTTP连接的接口的效率。  In this embodiment, the receiving module receives the HTTP request message that is sent by the client and includes the processing identifier information header field by using the HTTP type persistent connection of the concurrent type, so that the sending module can return the foregoing processing to the client by using the HTTP type permanent connection of the concurrent type. The HTTP response message identifying the information header field enables multiple HTTP requests to be processed through a concurrent type of HTTP persistent connection, thereby reducing the complexity of interface configuration management and maintenance using HTTP connections, and improving the interface using HTTP connections. s efficiency.
进一步地, 本实施例的 HTTP服务器还可以进一步包括建立模块 43, 用 于与上述客户端进行交互, 建立上述并发类型的 HTTP永久连接。 具体地, 建立模块 43具体可以用于接收上述客户端发送的建立 HTTP连接请求消息, 上述建立 HTTP连接请求消息中包含连接类型头域,根据上述连接类型头域, 建立与上述客户端之间的并发类型的 HTTP永久连接。 Further, the HTTP server of this embodiment may further include an establishing module 43, Interact with the above client to establish the HTTP type permanent connection of the above concurrency type. Specifically, the establishing module 43 is specifically configured to receive an HTTP connection request message sent by the client, where the HTTP connection request message includes a connection type header field, and is established between the client and the client according to the connection type header field. Concurrent type of HTTP permanent connection.
图 5为本发明实施例五提供的 HTTP客户端的结构示意图,如图 5所示, 本实施例的 HTTP客户端可以包括发送模块 51和接收模块 52。 其中, 发送 模块 51通过并发类型的 HTTP永久连接向服务器发送 HTTP请求消息, 上 述 HTTP请求消息中包含处理标识信息头域, 接收模块 52通过上述并发类 型的 HTTP永久连接接收上述服务器返回的 HTTP响应消息, 上述 HTTP响 应消息中包含上述处理标识信息头域。  FIG. 5 is a schematic structural diagram of an HTTP client according to Embodiment 5 of the present invention. As shown in FIG. 5, the HTTP client in this embodiment may include a sending module 51 and a receiving module 52. The sending module 51 sends an HTTP request message to the server by using a persistent type HTTP persistent connection, where the HTTP request message includes a processing identifier information header field, and the receiving module 52 receives the HTTP response message returned by the server by using the concurrent type HTTP permanent connection. The foregoing HTTP response message includes the foregoing processing identifier information header field.
上述本发明实施例二中客户端、 本发明实施例三中 MRFC 的功能均 可以由本发明实施例提供的 HTTP客户端实现。  The functions of the client in the second embodiment of the present invention and the function of the MRFC in the third embodiment of the present invention can be implemented by the HTTP client provided by the embodiment of the present invention.
本实施例中, 发送模块通过并发类型的 HTTP永久连接向服务器发送包 含处理标识信息头域的 HTTP请求消息, 使得接收模块能够通过上述并发类 型的 HTTP 永久连接接收上述服务器返回的包含上述处理标识信息头域的 HTTP响应消息, 实现了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低了使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高了使用 HTTP连接的接口的效率。  In this embodiment, the sending module sends the HTTP request message including the processing identifier information header field to the server through the concurrent type HTTP permanent connection, so that the receiving module can receive the foregoing processing identifier information returned by the server through the HTTP type persistent connection of the concurrent type. The HTTP response message of the header field enables multiple HTTP requests to be processed through a concurrent type of HTTP persistent connection, thereby reducing the complexity of interface configuration management and maintenance using HTTP connections, and improving the efficiency of interfaces using HTTP connections. .
进一步地, 本实施例的 HTTP客户端还可以进一步包括建立模块 53, 用 于与上述服务器进行交互, 建立上述并发类型的 HTTP永久连接。 具体地, 建立模块 53具体可以用于向上述服务器发送建立 HTTP连接请求消息, 上 述建立 HTTP连接请求消息中包含连接类型头域, 以使上述服务器根据上述 连接类型头域, 建立与上述客户端之间的并发类型的 HTTP永久连接。  Further, the HTTP client of this embodiment may further include an establishing module 53 for interacting with the server to establish the HTTP type permanent connection of the concurrency type. Specifically, the establishing module 53 is specifically configured to send an HTTP connection request message to the server, where the establishing the HTTP connection request message includes a connection type header field, so that the server establishes a connection with the client according to the connection type header field. A concurrent type of HTTP persistent connection.
图 6为本发明实施例六提供的基于 HTTP的通信处理系统的结构示意图, 如图 6所示, 本实施例的基于 HTTP的通信处理系统可以包括客户端 61和 服务器 62, 其中: 客户端 61用于通过并发类型的 HTTP永久连接向服务器 62发送 HTTP 请求消息, 上述 HTTP请求消息中包含处理标识信息头域, 以及通过上述并 发类型的 HTTP永久连接接收服务器 62返回的 HTTP响应消息,上述 HTTP 响应消息中包含上述处理标识信息头域; FIG. 6 is a schematic structural diagram of an HTTP-based communication processing system according to Embodiment 6 of the present invention. As shown in FIG. 6, the HTTP-based communication processing system of this embodiment may include a client 61 and a server 62, where: The client 61 is configured to send an HTTP request message to the server 62 through a concurrent type of HTTP persistent connection, where the HTTP request message includes a processing identification information header field, and an HTTP response message returned by the concurrent type HTTP permanent connection receiving server 62. The foregoing HTTP response message includes the foregoing processing identifier information header field;
服务器 62用于通过上述并发类型的 HTTP永久连接接收客户端 61发送 的上述 HTTP请求消息, 以及通过上述并发类型的 HTTP永久连接向客户端 The server 62 is configured to receive the above HTTP request message sent by the client 61 through the HTTP type persistent connection of the concurrency type described above, and to the client through the HTTP type persistent connection of the concurrency type described above.
61返回上述 HTTP响应消息。 61 returns the above HTTP response message.
上述本发明实施例二中客户端、 本发明实施例三中 MRFC 的功能均 可以由本发明实施例提供的基于 HTTP的通信处理系统中的客户端 61 实 现; 上述本发明实施例一中服务器、 本发明实施例三中 AS的功能均可以 由本发明实施例提供的基于 HTTP的通信处理系统中的服务器 62实现。  The function of the client in the second embodiment of the present invention and the function of the MRFC in the third embodiment of the present invention can be implemented by the client 61 in the HTTP-based communication processing system provided by the embodiment of the present invention; The functions of the AS in the third embodiment of the present invention can be implemented by the server 62 in the HTTP-based communication processing system provided by the embodiment of the present invention.
本实施例中, 服务器通过并发类型的 HTTP永久连接接收客户端发送的 包含处理标识信息头域的 HTTP 请求消息, 使得能够通过上述并发类型的 In this embodiment, the server receives the HTTP request message that is sent by the client and includes the processing identifier information header field by using the HTTP type persistent connection of the concurrency type, so that the concurrency type can be adopted.
HTTP永久连接向上述客户端返回包含上述处理标识信息头域的 HTTP响应 消息,实现了通过一条并发类型的 HTTP永久连接可以处理多个 HTTP请求, 从而降低了使用 HTTP连接的接口配置管理和维护的复杂性, 以及提高了使 用 HTTP连接的接口的效率。 The HTTP persistent connection returns an HTTP response message including the above-mentioned processing identification information header field to the above client, so that multiple HTTP requests can be processed through a concurrent type of HTTP permanent connection, thereby reducing interface configuration management and maintenance using HTTP connection. Complexity, and the efficiency of interfaces that use HTTP connections.
进一步地, 本实施例中的客户端 61还可以进一步用于与服务器 62进行 交互, 建立上述并发类型的 HTTP永久连接; 相应地, 服务器 62还可以进 一步用于与客户端 61进行交互, 建立上述并发类型的 HTTP永久连接。  Further, the client 61 in this embodiment may be further configured to interact with the server 62 to establish the HTTP type permanent connection of the concurrency type. Correspondingly, the server 62 may further be configured to interact with the client 61 to establish the foregoing. Concurrent type of HTTP permanent connection.
本领域普通技术人员可以理解: 实现上述方法实施例的全部或部分步骤 可以通过程序指令相关的硬件来完成, 前述的程序可以存储于一计算机可读 取存储介质中, 该程序在执行时, 执行包括上述方法实施例的步骤; 而前述 的存储介质包括: R〇M、 RAM,磁碟或者光盘等各种可以存储程序代码的介质。  A person skilled in the art can understand that all or part of the steps of implementing the above method embodiments may be completed by using hardware related to program instructions, and the foregoing program may be stored in a computer readable storage medium, and the program is executed when executed. The foregoing steps include the steps of the foregoing method embodiments; and the foregoing storage medium includes: a medium that can store program codes, such as R〇M, RAM, a magnetic disk, or an optical disk.
最后应说明的是: 以上实施例仅用以说明本发明的技术方案, 而非对其 限制; 尽管参照前述实施例对本发明进行了详细的说明, 本领域的普通技术 人员应当理解: 其依然可以对前述各实施例所记载的技术方案进行修改, 或 者对其中部分技术特征进行等同替换; 而这些修改或者替换, 并不使相应技 术方案的本质脱离本发明各实施例技术方案的精神和范围。 Finally, it should be noted that the above embodiments are merely illustrative of the technical solutions of the present invention, and are not intended to be limiting thereof; although the present invention has been described in detail with reference to the foregoing embodiments, It should be understood that: the technical solutions described in the foregoing embodiments may be modified, or some of the technical features may be equivalently replaced; and the modifications or substitutions do not deviate from the essence of the corresponding technical solutions. The spirit and scope of the technical programme.

Claims

权 利 要 求 书 Claim
1、 一种基于超文本传输协议 HTTP的通信方法, 其特征在于, 包括: 服务器通过并发类型的 HTTP永久连接接收客户端发送的 HTTP请求消 息, 所述 HTTP请求消息中包含处理标识信息头域;  A communication method based on the Hypertext Transfer Protocol (HTTP), comprising: the server receiving an HTTP request message sent by the client by using a persistent type of HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
所述服务器通过所述并发类型的 HTTP 永久连接向所述客户端返回 The server returns to the client through the concurrent type HTTP persistent connection
HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。 An HTTP response message, where the HTTP response message includes the processing identifier information header field.
2、 根据权利要求 1所述的方法, 其特征在于, 还包括: 所述服务器与所 述客户端进行交互, 建立所述并发类型的 HTTP永久连接。  2. The method according to claim 1, further comprising: the server interacting with the client to establish an HTTP permanent connection of the concurrent type.
3、 根据权利要求 2所述的方法, 其特征在于, 所述服务器与所述客户端 进行交互, 建立所述并发类型的 HTTP永久连接包括:  3. The method according to claim 2, wherein the server interacts with the client, and establishing the concurrent type of HTTP permanent connection comprises:
所述服务器接收所述客户端发送的建立 HTTP连接请求消息, 所述建立 HTTP连接请求消息中包含连接类型头域;  The server receives an establishment HTTP connection request message sent by the client, where the establishment HTTP connection request message includes a connection type header field;
所述服务器根据所述连接类型头域, 建立与所述客户端之间的并发类型 的 HTTP永久连接。  The server establishes a persistent type of HTTP permanent connection with the client according to the connection type header field.
4、 根据权利要求 1~3任一权利要求所述的方法, 其特征在于, 所述并 发类型的 HTTP永久连接用于 IP多媒体子系统 IMS中客户端与服务器之间 的 Sr接口。  The method according to any one of claims 1 to 3, wherein the concurrent type of HTTP permanent connection is used for an Sr interface between a client and a server in an IP Multimedia Subsystem IMS.
5、 一种基于超文本传输协议 HTTP的通信方法, 其特征在于, 包括: 客户端通过并发类型的 HTTP永久连接向服务器发送 HTTP请求消息, 所述 HTTP请求消息中包含处理标识信息头域;  A communication method based on the Hypertext Transfer Protocol (HTTP), comprising: the client sending an HTTP request message to the server through a concurrent type of HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
所述客户端通过所述并发类型的 HTTP永久连接接收所述服务器返回的 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。  The client receives the HTTP response message returned by the server by using the HTTP type persistent connection of the concurrent type, where the HTTP response message includes the processing identifier information header field.
6、 根据权利要求 5所述的方法, 其特征在于, 还包括: 所述客户端与所 述服务器进行交互, 建立所述并发类型的 HTTP永久连接。  The method according to claim 5, further comprising: the client interacting with the server to establish an HTTP permanent connection of the concurrent type.
7、 根据权利要求 6所述的方法, 其特征在于, 所述客户端与所述服务器 进行交互, 建立所述并发类型的 HTTP永久连接包括: 7. The method according to claim 6, wherein the client and the server To interact, establishing the HTTP type of the persistent connection of the concurrency type includes:
所述客户端向所述服务器发送建立 HTTP连接请求消息,所述建立 HTTP 连接请求消息中包含连接类型头域,以使所述服务器根据所述连接类型头域, 建立与所述客户端之间的并发类型的 HTTP永久连接。  The client sends an HTTP connection request message to the server, where the connection HTTP connection request message includes a connection type header field, so that the server establishes a relationship with the client according to the connection type header field. Concurrent type of HTTP permanent connection.
8、 根据权利要求 5~7任一权利要求所述的方法, 其特征在于, 所述并 发类型的 HTTP永久连接用于 IP多媒体子系统 IMS中客户端与服务器之间 的 Sr接口。  The method according to any one of claims 5 to 7, wherein the concurrent type HTTP permanent connection is used for an Sr interface between a client and a server in an IP Multimedia Subsystem IMS.
9、 一种超文本传输协议 HTTP服务器, 其特征在于, 包括:  9. A hypertext transfer protocol HTTP server, comprising:
接收模块,用于通过并发类型的 HTTP永久连接接收客户端发送的 HTTP 请求消息, 所述 HTTP请求消息中包含处理标识信息头域;  a receiving module, configured to receive, by using a concurrent type of HTTP permanent connection, an HTTP request message sent by the client, where the HTTP request message includes a processing identifier information header field;
发送模块, 用于通过所述并发类型的 HTTP永久连接向所述客户端返回 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。  And a sending module, configured to return an HTTP response message to the client by using the HTTP persistent connection of the concurrent type, where the HTTP response message includes the processing identifier information header field.
10、 根据权利要求 9所述的 HTTP服务器, 其特征在于, 还包括建立模 块, 用于与所述客户端进行交互, 建立所述并发类型的 HTTP永久连接。  10. The HTTP server of claim 9, further comprising a setup module for interacting with the client to establish the concurrent type of HTTP persistent connection.
11、 根据权利要求 10所述的 HTTP服务器, 其特征在于, 所述建立模 块具体用于  The HTTP server according to claim 10, wherein the establishment module is specifically used for
接收所述客户端发送的建立 HTTP连接请求消息, 所述建立 HTTP连接 请求消息中包含连接类型头域, 根据所述连接类型头域, 建立与所述客户端 之间的并发类型的 HTTP永久连接。  Receiving an HTTP connection request message sent by the client, where the HTTP connection request message includes a connection type header field, and establishing a concurrent type HTTP permanent connection with the client according to the connection type header field. .
12、 一种超文本传输协议 HTTP客户端, 其特征在于, 包括:  12. A hypertext transfer protocol HTTP client, comprising:
发送模块, 用于通过并发类型的 HTTP永久连接向服务器发送 HTTP请 求消息, 所述 HTTP请求消息中包含处理标识信息头域;  a sending module, configured to send an HTTP request message to the server by using a persistent HTTP persistent connection, where the HTTP request message includes a processing identifier information header field;
接收模块, 用于通过所述并发类型的 HTTP永久连接接收所述服务器返 回的 HTTP响应消息, 所述 HTTP响应消息中包含所述处理标识信息头域。  The receiving module is configured to receive, by using the HTTP type persistent connection of the concurrent type, an HTTP response message returned by the server, where the HTTP response message includes the processing identifier information header field.
13、 根据权利要求 12 所述的客户端, 其特征在于, 还包括建立模块, 用于与所述服务器进行交互, 建立所述并发类型的 HTTP永久连接。 The client according to claim 12, further comprising an establishing module, configured to interact with the server to establish the concurrent type HTTP permanent connection.
14、 根据权利要求 13 所述的客户端, 其特征在于, 所述建立模块具体 用于 The client according to claim 13, wherein the establishing module is specifically configured to be used
向所述服务器发送建立 HTTP连接请求消息, 所述建立 HTTP连接请求 消息中包含连接类型头域, 以使所述服务器根据所述连接类型头域, 建立与 所述客户端之间的并发类型的 HTTP永久连接。  Sending an HTTP connection request message to the server, where the establishment HTTP connection request message includes a connection type header field, so that the server establishes a concurrency type with the client according to the connection type header field. HTTP permanent connection.
15、 一种基于超文本传输协议 HTTP的通信系统, 其特征在于, 包括客 户端和服务器, 其中:  15. A communication system based on Hypertext Transfer Protocol (HTTP), characterized in that it comprises a client and a server, wherein:
所述客户端用于通过并发类型的 HTTP 永久连接向所述服务器发送 HTTP请求消息, 所述 HTTP请求消息中包含处理标识信息头域, 以及通过 所述并发类型的 HTTP永久连接接收所述服务器返回的 HTTP响应消息, 所 述 HTTP响应消息中包含所述处理标识信息头域;  The client is configured to send an HTTP request message to the server by using a concurrent type of HTTP permanent connection, where the HTTP request message includes a processing identifier information header field, and receiving the server return by using the concurrent type HTTP permanent connection. The HTTP response message, where the HTTP response message includes the processing identifier information header field;
所述服务器用于通过所述并发类型的 HTTP永久连接接收所述客户端发 送的所述 HTTP请求消息, 以及通过所述并发类型的 HTTP永久连接向所述 客户端返回所述 HTTP响应消息。  The server is configured to receive the HTTP request message sent by the client by using the concurrent type HTTP persistent connection, and return the HTTP response message to the client by using the concurrent type HTTP permanent connection.
16、 根据权利要求 15所述的系统, 其特征在于,  16. The system of claim 15 wherein:
所述客户端还用于与所述服务器进行交互, 建立所述并发类型的 HTTP 永久连接;  The client is further configured to interact with the server to establish an HTTP permanent connection of the concurrent type;
所述服务器还用于与所述客户端进行交互, 建立所述并发类型的 HTTP 永久连接。  The server is further configured to interact with the client to establish an HTTP permanent connection of the concurrent type.
PCT/CN2011/083929 2010-12-21 2011-12-14 Http-based communication method and system, http server and http client WO2012083806A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201010613201.0A CN102065143B (en) 2010-12-21 2010-12-21 Communication method and system based on HTTP (hyper Text Transfer Protocol), HTTP server and HTTP client
CN201010613201.0 2010-12-21

Publications (1)

Publication Number Publication Date
WO2012083806A1 true WO2012083806A1 (en) 2012-06-28

Family

ID=44000242

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/083929 WO2012083806A1 (en) 2010-12-21 2011-12-14 Http-based communication method and system, http server and http client

Country Status (2)

Country Link
CN (1) CN102065143B (en)
WO (1) WO2012083806A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102065143B (en) * 2010-12-21 2014-04-30 华为技术有限公司 Communication method and system based on HTTP (hyper Text Transfer Protocol), HTTP server and HTTP client
CN103516673A (en) * 2012-06-21 2014-01-15 腾讯科技(深圳)有限公司 Network data communication method, network data communication system, network data communication client and network data communication server
CN104113564A (en) * 2013-04-17 2014-10-22 中国移动通信集团公司 Hyper text transfer protocol connection multiplexing method, device, system, and terminal
CN106470221B (en) * 2015-08-18 2019-12-31 北京京东尚科信息技术有限公司 Method for improving inter-process communication coordination efficiency
CN113993143A (en) * 2018-05-22 2022-01-28 华为技术有限公司 Session management method, device and system
CN112187858B (en) * 2020-08-24 2023-04-18 浙江百应科技有限公司 Method for matching pipeline type http request and response

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101083667A (en) * 2007-07-04 2007-12-05 华为技术有限公司 Communication method, system and gateway equipment
CN101483599A (en) * 2009-02-18 2009-07-15 北京交通大学 Method for enhancing webpage browsing efficiency based on priority multi-connection
US20100268757A1 (en) * 2009-04-17 2010-10-21 Google Inc. Pseudo Pipelining of Client Requests
CN102065143A (en) * 2010-12-21 2011-05-18 华为技术有限公司 Communication method and system based on HTTP (hyper Text Transfer Protocol), HTTP server and HTTP client

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100539589C (en) * 2005-03-24 2009-09-09 北京北方烽火科技有限公司 A kind of high speed Le interface implementation method based on asynchronous multithreading

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101083667A (en) * 2007-07-04 2007-12-05 华为技术有限公司 Communication method, system and gateway equipment
CN101483599A (en) * 2009-02-18 2009-07-15 北京交通大学 Method for enhancing webpage browsing efficiency based on priority multi-connection
US20100268757A1 (en) * 2009-04-17 2010-10-21 Google Inc. Pseudo Pipelining of Client Requests
CN102065143A (en) * 2010-12-21 2011-05-18 华为技术有限公司 Communication method and system based on HTTP (hyper Text Transfer Protocol), HTTP server and HTTP client

Also Published As

Publication number Publication date
CN102065143A (en) 2011-05-18
CN102065143B (en) 2014-04-30

Similar Documents

Publication Publication Date Title
WO2012083806A1 (en) Http-based communication method and system, http server and http client
TWI462551B (en) Sip-http application correlator
EP2870735B1 (en) Method for adding client capability data to a sip message
WO2013097401A1 (en) Method, gateway and communication system for browser client directly communicating with back-end server
JP2012190490A5 (en)
JP2007272868A5 (en)
CA2793539A1 (en) Method and system for reliable protocol tunneling over http
US20080120705A1 (en) Systems, Methods and Computer Program Products Supporting Provision of Web Services Using IMS
WO2007068209A1 (en) A method, system and device for transmitting ims instant messages
WO2005114906A1 (en) Method and system for getting the state of sip network nodes
WO2011137777A1 (en) Method and device for callback processing in telecommunication capacity opening
EP2706728A1 (en) Method and device for improving voice or video transmission quality in a cloud computing mode
RU2608469C2 (en) Method and apparatus for high performance low latency real time notification delivery
WO2010139581A1 (en) Detecting an inactive client during a communication session
US7940748B2 (en) Systems, methods and computer program products supporting provision of web services using IMS
WO2011140852A1 (en) Method for accessing instant messaging service system store server and instant messaging service system
US20080120697A1 (en) Systems, Methods and Computer Program Products Supporting Provision of Web Services Using IMS
WO2012122730A1 (en) Method, auto-configuration server (acs), and system for obtaining status of device based on tr069 protocol
WO2015172629A1 (en) Message transmission method, apparatus and system
US7899058B2 (en) Using a hash value as a pointer to an application class in a communications device
WO2012130048A1 (en) Method and apparatus for initializing gateway in device management system
WO2010121525A1 (en) Method, apparatus and system for a real time streaming protocol terminal to obtain media resources
WO2013163847A1 (en) Single-pdp dual-stack serial dialing method and system
WO2013159492A1 (en) Method and system for reporting and downloading information
WO2014043868A1 (en) Conference access method, device and system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11852036

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11852036

Country of ref document: EP

Kind code of ref document: A1