CN115866050A - Request processing method, device, electronic device, and computer-readable storage medium - Google Patents
Request processing method, device, electronic device, and computer-readable storage medium Download PDFInfo
- Publication number
- CN115866050A CN115866050A CN202211485821.XA CN202211485821A CN115866050A CN 115866050 A CN115866050 A CN 115866050A CN 202211485821 A CN202211485821 A CN 202211485821A CN 115866050 A CN115866050 A CN 115866050A
- Authority
- CN
- China
- Prior art keywords
- display
- cloud server
- request
- target electronic
- responding
- Prior art date
- Legal status (The legal status 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 status listed.)
- Pending
Links
Images
Landscapes
- Information Transfer Between Computers (AREA)
Abstract
本申请实施例提供了一种请求处理方法、装置、电子设备及计算机可读存储介质,涉及计算机技术领域。该方法包括:根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。
Embodiments of the present application provide a request processing method, device, electronic equipment, and computer-readable storage medium, which relate to the technical field of computers. The method includes: according to the number of the requested target electronic signs in the display request and/or the expected response time for the central cloud server to respond to the display request, determine the responder that responds to the display request, based on The responding end responds to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server , relieve the processing pressure of the central cloud server, reduce the network bandwidth occupation, and reduce the calculation delay.
Description
技术领域technical field
本申请涉及计算机技术领域,具体而言,本申请涉及一种请求处理方法、装置、电子设备及计算机可读存储介质。The present application relates to the field of computer technology, and in particular, the present application relates to a request processing method, device, electronic equipment, and computer-readable storage medium.
背景技术Background technique
电子标牌【如电子纸显示标牌或电泳显示标牌(Electrophoretic,EPD即E-paper),一种采用EPD技术实现的显示屏幕】是一种带有信息收发功能的电子显示装置,其可代替传统纸质的标签,常用于不同的使用场景,使用场景包括智慧零售、智慧办公及智慧交通等。例如,电子标牌用于会议场景时,可以将不同的电子标牌分为门牌、桌牌和工位牌等,以用于显示相应标牌内容。Electronic signage [such as electronic paper display signs or electrophoretic display signs (Electrophoretic, EPD is E-paper), a display screen realized by EPD technology] is an electronic display device with information sending and receiving functions, which can replace traditional paper Quality labels are often used in different usage scenarios, including smart retail, smart office, and smart transportation. For example, when the electronic signage is used in a conference scene, different electronic signs can be divided into house cards, table cards, and workstation cards, etc., to display the corresponding sign content.
电子标牌的显示可以通过云服务器来控制,在相关技术中,通常通过公有云(公有云例如中心云)来控制并管理电子标牌的显示,然而这种依赖公有云的控制管理方式会使公有云产生系统压力、计算延迟、网络带宽占满等问题,影响电子标牌使用的稳定性。The display of electronic signage can be controlled by a cloud server. In related technologies, the display of electronic signage is usually controlled and managed through a public cloud (public cloud such as a central cloud). Problems such as system pressure, calculation delay, and full network bandwidth will occur, which will affect the stability of electronic signage.
发明内容Contents of the invention
本申请的目的旨在至少能解决上述的技术缺陷之一,特别是公有云系统压力较大、电子标牌使用的稳定性低的技术缺陷。The purpose of this application is to solve at least one of the above-mentioned technical defects, especially the technical defects of high pressure on the public cloud system and low stability of electronic signage.
根据本申请的一个方面,提供了一种请求处理方法,该方法包括:According to one aspect of the present application, a request processing method is provided, the method comprising:
接收客户端发送的请求显示目标电子标牌的显示请求;Receive the display request sent by the client to request to display the target electronic signage;
根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端;According to the number of the requested target electronic signs in the display request and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request;
其中,所述响应端包括所述中心云服务器和/或与所述中心云服务器具有通信连接的边缘云服务器;Wherein, the responder includes the central cloud server and/or an edge cloud server having a communication connection with the central cloud server;
基于所述响应端,响应所述显示请求。Respond to the display request based on the responder.
可选的,所述接收客户端发送的请求显示目标电子标牌的显示请求之后,所述方法还包括:Optionally, after receiving the display request sent by the client requesting to display the target electronic signage, the method further includes:
根据所述中心云服务器的空闲处理资源和/或处理速度,确定显示所述目标电子标牌的预计响应时长。According to the idle processing resources and/or processing speed of the central cloud server, determine the expected response time for displaying the target electronic signage.
可选的,所述确定响应所述显示请求的响应端,包括:Optionally, the determining the responder that responds to the display request includes:
确定所述目标电子标牌的数量小于第一预设阈值,和/或所述预计响应时长小于第二预设阈值的情况下,确定所述中心云服务器为所述响应端;When it is determined that the number of the target electronic signs is less than a first preset threshold, and/or the expected response time is less than a second preset threshold, determine that the central cloud server is the responding end;
确定所述目标电子标牌的数量大于第一预设阈值,和/或所述预计响应时长大于第二预设阈值的情况下,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端。When it is determined that the number of the target electronic signs is greater than a first preset threshold, and/or the expected response time is greater than a second preset threshold, it is determined that the central cloud server and at least one edge cloud server are the Response end.
可选的,确定所述中心云服务器为所述响应端的情况下,Optionally, when it is determined that the central cloud server is the responding end,
所述基于所述响应端,响应所述显示请求,包括:The responding to the display request based on the responding end includes:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
可选的,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端的情况下,Optionally, when it is determined that the central cloud server and at least one edge cloud server are the responding end,
所述基于所述响应端,响应所述显示请求,包括:The responding to the display request based on the responding end includes:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
与目标边缘云服务器建立通信连接;向所述目标边缘云服务器发送所述显示文件,以通过所述目标边缘云服务器向预设网关发送显示指令以及所述显示文件,通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。Establish a communication connection with the target edge cloud server; send the display file to the target edge cloud server, so as to send a display instruction and the display file to the preset gateway through the target edge cloud server, and send the display file to the default gateway through the target edge cloud server The display file is sent to the target electronic signage, instructing the target electronic signage to display the signage content through the preset display template.
可选的,在所述边缘云服务器包括多个服务器的情况下,所述生成显示文件之后,所述方法还包括:Optionally, when the edge cloud server includes multiple servers, after the display file is generated, the method further includes:
根据每个所述边缘云服务器对应的随机超时时长,确定所述边缘云服务器中的目标边缘云服务器;Determine a target edge cloud server in the edge cloud servers according to the random timeout period corresponding to each edge cloud server;
与所述目标边缘云服务器建立通信连接。Establish a communication connection with the target edge cloud server.
根据本申请的一个方面,提供了一种请求处理方法,该方法包括:According to one aspect of the present application, a request processing method is provided, the method comprising:
响应于客户端发送的请求显示目标电子标牌的显示请求,与中心云服务器建立通信连接;Establish a communication connection with the central cloud server in response to the display request sent by the client requesting to display the target electronic signage;
其中,所述目标电子标牌的数量大于第一预设阈值,和/或所述中心云服务器响应所述显示请求的预计响应时长大于第二预设阈值;Wherein, the number of the target electronic signs is greater than a first preset threshold, and/or the estimated response time of the central cloud server in response to the display request is greater than a second preset threshold;
响应所述显示请求。Respond to the display request.
可选的,所述响应所述显示请求,包括:Optionally, the response to the display request includes:
接收并存储所述中心云服务器发送的显示文件;其中,所述显示文件是基于在示模板中添加所述目标电子标牌的标牌内容生成的;receiving and storing the display file sent by the central cloud server; wherein, the display file is generated based on the sign content of the target electronic sign added to the display template;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
可选的,还包括第二边缘云服务器,Optionally, it also includes a second edge cloud server,
所述接收所述中心云服务器发送的显示文件之后,所述方法还包括:After receiving the display file sent by the central cloud server, the method further includes:
向所述第二边缘云服务器发送所述显示文件,以通过所述第二边缘云服务器向预设网关发送显示指令以及所述显示文件。Sending the display file to the second edge cloud server, so as to send a display instruction and the display file to a preset gateway through the second edge cloud server.
根据本申请的另一个方面,提供了一种请求处理装置,该装置包括:According to another aspect of the present application, a request processing device is provided, and the device includes:
接收模块,用于接收客户端发送的请求显示目标电子标牌的显示请求;A receiving module, configured to receive a display request sent by the client to request display of the target electronic signage;
确定模块,用于根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端;A determining module, configured to determine the responding end that responds to the display request according to the number of the requested target electronic signs in the display request and/or the expected response time for the central cloud server to respond to the display request;
其中,所述响应端包括所述中心云服务器和/或与所述中心云服务器具有通信连接的边缘云服务器;Wherein, the responder includes the central cloud server and/or an edge cloud server having a communication connection with the central cloud server;
响应模块,用于基于所述响应端,响应所述显示请求。A response module, configured to respond to the display request based on the responder.
根据本申请的另一个方面,提供了一种请求处理装置,该装置包括:According to another aspect of the present application, a request processing device is provided, and the device includes:
连接模块,用于响应于客户端发送的请求显示目标电子标牌的显示请求,与中心云服务器建立通信连接;A connection module, configured to establish a communication connection with the central cloud server in response to a display request sent by the client to request display of the target electronic signage;
其中,所述目标电子标牌的数量大于第一预设阈值,和/或所述中心云服务器响应所述显示请求的预计响应时长大于第二预设阈值;Wherein, the number of the target electronic signs is greater than a first preset threshold, and/or the estimated response time of the central cloud server in response to the display request is greater than a second preset threshold;
响应模块,用于响应所述显示请求。A response module, configured to respond to the display request.
根据本申请的另一个方面,提供了一种电子设备,该电子设备包括:According to another aspect of the present application, an electronic device is provided, and the electronic device includes:
一个或多个处理器;one or more processors;
存储器;memory;
一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个应用程序配置用于:执行上述第一方面或者第二方面任一项所述的请求处理方法。one or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, the one or more application programs are configured to: Execute the request processing method described in any one of the first aspect or the second aspect above.
例如,本申请的第五方面,提供了一种计算设备,包括:处理器、存储器、通信接口和通信总线,处理器、存储器和通信接口通过通信总线完成相互间的通信;For example, the fifth aspect of the present application provides a computing device, including: a processor, a memory, a communication interface, and a communication bus, and the processor, the memory, and the communication interface complete mutual communication through the communication bus;
存储器用于存放至少一可执行指令,可执行指令使处理器执行如本申请的第一方面所示的请求处理方法对应的操作。The memory is used to store at least one executable instruction, and the executable instruction causes the processor to perform operations corresponding to the request processing method shown in the first aspect of the present application.
根据本申请的再一个方面,提供了一种计算机可读存储介质,所述计算机程序被处理器执行时实现上述第一方面或者第二方面任一项所述的请求处理方法。According to still another aspect of the present application, a computer-readable storage medium is provided, and when the computer program is executed by a processor, the request processing method described in any one of the first aspect or the second aspect is implemented.
例如,本申请实施例的第六方面,提供了一种计算机可读存储介质,计算机可读存储介质上存储有计算机程序,该程序被处理器执行时实现本申请第一方面所示的请求处理方法。For example, the sixth aspect of the embodiments of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the request processing described in the first aspect of the present application is implemented. method.
根据本申请的一个方面,提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述第一方面或者第二方面的各种可选实现方式中提供的方法。According to an aspect of the present application there is provided a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the method provided in various optional implementation manners of the first aspect or the second aspect above.
本申请提供的技术方案带来的有益效果是:The beneficial effects brought by the technical solution provided by the application are:
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
附图说明Description of drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对本申请实施例描述中所需要使用的附图作简单地介绍。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings that need to be used in the description of the embodiments of the present application.
图1为本申请实施例提供的一种请求处理方法的系统架构示意图;FIG. 1 is a schematic diagram of a system architecture of a request processing method provided in an embodiment of the present application;
图2为本申请实施例提供的一种请求处理方法的流程示意图之一;FIG. 2 is one of the schematic flow diagrams of a request processing method provided in the embodiment of the present application;
图3为本申请实施例提供的一种请求处理方法的应用场景示意图之一;FIG. 3 is one of the application scenario schematic diagrams of a request processing method provided by the embodiment of the present application;
图4为为本申请实施例提供的一种请求处理方法的应用场景示意图之二;FIG. 4 is the second schematic diagram of an application scenario of a request processing method provided by an embodiment of the present application;
图5为为本申请实施例提供的一种请求处理方法的应用场景示意图之三;Fig. 5 is a third schematic diagram of an application scenario of a request processing method provided by an embodiment of the present application;
图6为本申请实施例提供的一种请求处理方法的流程示意图之二;FIG. 6 is the second schematic flow diagram of a request processing method provided by the embodiment of the present application;
图7为本申请实施例提供的一种请求处理装置的结构示意图之一;FIG. 7 is one of the structural schematic diagrams of a request processing device provided in the embodiment of the present application;
图8为本申请实施例提供的一种请求处理装置的结构示意图之二;Fig. 8 is the second structural schematic diagram of a request processing device provided by the embodiment of the present application;
图9为本申请实施例提供的一种请求处理的电子设备的结构示意图。FIG. 9 is a schematic structural diagram of an electronic device for request processing provided by an embodiment of the present application.
具体实施方式Detailed ways
下面结合本申请中的附图描述本申请的实施例。应理解,下面结合附图所阐述的实施方式,是用于解释本申请实施例的技术方案的示例性描述,对本申请实施例的技术方案不构成限制。Embodiments of the present application are described below with reference to the drawings in the present application. It should be understood that the implementation manner described below in conjunction with the accompanying drawings is an exemplary description for explaining the technical solutions of the embodiments of the present application, and does not limit the technical solutions of the embodiments of the present application.
本技术领域技术人员可以理解,除非特意声明,这里使用的单数形式“一”、“一个”、“所述”和“该”也可包括复数形式。应该进一步理解的是,本申请实施例所使用的术语“包括”以及“包含”是指相应特征可以实现为所呈现的特征、信息、数据、步骤、操作、元件和/或组件,但不排除实现为本技术领域所支持其他特征、信息、数据、步骤、操作、元件、组件和/或它们的组合等。应该理解,当我们称一个元件被“连接”或“耦接”到另一元件时,该一个元件可以直接连接或耦接到另一元件,也可以指该一个元件和另一元件通过中间元件建立连接关系。此外,这里使用的“连接”或“耦接”可以包括无线连接或无线耦接。这里使用的术语“和/或”指示该术语所限定的项目中的至少一个,例如“A和/或B”可以实现为“A”,或者实现为“B”,或者实现为“A和B”。Those skilled in the art will understand that unless otherwise stated, the singular forms "a", "an", "said" and "the" used herein may also include plural forms. It should be further understood that the terms "comprising" and "comprising" used in the embodiments of the present application mean that the corresponding features can be implemented as the presented features, information, data, steps, operations, elements and/or components, but do not exclude The realization is other features, information, data, steps, operations, elements, components and/or their combinations etc. supported by the technical field. It should be understood that when we say that an element is "connected" or "coupled" to another element, the one element can be directly connected or coupled to the other element, or it can mean that the one element and another element pass through intermediate elements. Establish a connection relationship. Additionally, "connected" or "coupled" as used herein may include wireless connection or wireless coupling. The term "and/or" used herein indicates at least one of the items defined by the term, for example, "A and/or B" can be implemented as "A", or as "B", or as "A and B ".
为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。In order to make the purpose, technical solution and advantages of the present application clearer, the implementation manners of the present application will be further described in detail below in conjunction with the accompanying drawings.
下面以具体地实施例对本申请的技术方案以及本申请的技术方案如何解决上述技术问题进行详细说明。下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例中不再赘述。下面将结合附图,对本申请的实施例进行描述。The technical solution of the present application and how the technical solution of the present application solves the above technical problems will be described in detail below with specific embodiments. The following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present application will be described below in conjunction with the accompanying drawings.
电子标牌的管理采用集中式的中心云的方式,如果云服务故障、宕机,会导致电子标牌的刷新延迟或者数据丢失,无法保证电子标牌的可用性。另一方面,当电子标牌的数量达到一定规模时,云服务会产生系统压力、计算延迟、网络带宽占满等问题,影响电子标牌可用性。The management of electronic signage adopts a centralized central cloud method. If the cloud service fails or goes down, it will cause delays in refreshing the electronic signage or loss of data, and the availability of the electronic signage cannot be guaranteed. On the other hand, when the number of electronic signage reaches a certain scale, cloud services will cause problems such as system pressure, computing delay, and full network bandwidth, which will affect the availability of electronic signage.
本申请实施例提供采用中心云与边缘云协同管理的请求处理方法,以解决上述技术问题。The embodiment of the present application provides a request processing method using the collaborative management of the central cloud and the edge cloud, so as to solve the above technical problems.
其中,云计算(Cloud Computing),是基于互联网的相关服务的增加、使用和交互模式,通常涉及通过互联网来提供动态易扩展且经常是虚拟化的资源。云计算是分布式计算(Distributed Computing)、并行计算(Parallel Computing)、效用计算(UtilityComputing)、网络存储(Network Storage Technologies)、虚拟化(Virtualization)、负载均衡(Load Balance)、热备份冗余(High Available)等传统计算机和网络技术发展融合的产物。Among them, cloud computing (Cloud Computing) is the increase, use and interaction mode of related services based on the Internet, usually involving the provision of dynamically scalable and often virtualized resources through the Internet. Cloud computing is distributed computing (Distributed Computing), parallel computing (Parallel Computing), utility computing (Utility Computing), network storage (Network Storage Technologies), virtualization (Virtualization), load balancing (Load Balance), hot backup redundancy ( High Available) and other traditional computer and network technology development fusion product.
中心云,其可以为基于云计算技术的能力,构筑在云计算数据中心基础设施上的云计算平台,通过对复杂、大规模的全局性数据处理任务进行汇总、分析等,可以有效地实现庞大数据量的存储、管理。The central cloud can be a cloud computing platform built on the cloud computing data center infrastructure based on the ability of cloud computing technology. By summarizing and analyzing complex and large-scale global data processing tasks, it can effectively realize huge Data volume storage and management.
边缘云:其是基于云计算技术的核心和边缘计算的能力,构筑在边缘基础设施之上的云计算平台,形成边缘位置的计算、网络、存储、安全等能力全面的弹性云平台,并与中心云和物联网终端形成“云边端三体协同”的端到端的技术架构,通过将网络转发、存储、计算、智能化数据分析等工作放在边缘处理,降低响应时延、减轻中心云压力、降低带宽成本,并提供全网调度、算力分发等云服务。Edge cloud: It is a cloud computing platform based on the core of cloud computing technology and edge computing capabilities. The central cloud and the Internet of Things terminal form an end-to-end technical architecture of "cloud-edge-terminal three-body collaboration". By placing network forwarding, storage, computing, and intelligent data analysis on the edge for processing, the response delay is reduced and the central cloud is relieved. pressure, reduce bandwidth costs, and provide cloud services such as network-wide scheduling and computing power distribution.
与中心云或者传统的云计算平台相比,边缘云是个相对概念,边缘云是相对靠近终端的云计算平台,或者说,与中心云或者传统的云计算平台相区别,中心云或者传统的云计算平台可以包括资源规模化且位置集中的数据中心,而边缘云节点覆盖的网络范围更广泛,也因此具备距离终端更近的特性,单个边缘云节点的资源规模较小,但是边缘云节点的数量多。本实施例的终端是指云计算服务的需求端,例如可以是互联网中的终端或者用户端,或者物联网中的终端或用户端。Compared with the central cloud or the traditional cloud computing platform, the edge cloud is a relative concept. The edge cloud is a cloud computing platform that is relatively close to the terminal. In other words, it is different from the central cloud or the traditional cloud computing platform. The central cloud or the traditional cloud Computing platforms can include data centers with large-scale resources and concentrated locations, while edge cloud nodes cover a wider network range, and therefore have the characteristics of being closer to terminals. The resource scale of a single edge cloud node is small, but the edge cloud node a large amount. The terminal in this embodiment refers to the demand side of the cloud computing service, for example, it may be a terminal or user end in the Internet, or a terminal or user end in the Internet of Things.
结合图1所示,其为本申请实施例的系统架构图,其中,包括中心云、边缘云、网关、电子标牌等。As shown in FIG. 1 , it is a system architecture diagram of an embodiment of the present application, including a central cloud, an edge cloud, a gateway, an electronic signage, and the like.
具体而言,中心云包括中心云的业务平台、云管服务端组件、网关通信代理等。中心云的业务平台实现了多用户体系、电子标牌业务的可视化配置及数据存储、电子标牌的可视化运维管理及业务操作、以及边缘云的可视化运维管理及用户关系维护。云管服务端组件实现了边缘云的注册管理、数据监听、向边缘云下发命令及同步用户业务数据。网关通信代理实现了与电子标牌网关的数据通信、命令下发等。Specifically, the central cloud includes the central cloud business platform, cloud management server components, gateway communication agent, etc. The business platform of the central cloud realizes the multi-user system, the visual configuration and data storage of the electronic signage business, the visual operation and maintenance management and business operation of the electronic signage, and the visual operation and maintenance management and user relationship maintenance of the edge cloud. The cloud management server component realizes the registration management of the edge cloud, data monitoring, sending commands to the edge cloud and synchronizing user business data. The gateway communication agent realizes the data communication and command delivery with the electronic signage gateway.
边缘云为部署在用户边缘侧的自治节点,包括边缘云的业务平台、云管客户端组件、分布式组件、网关通信代理等。边缘云的业务平台实现了用户业务数据的可视化、分布式的创建管理、电子标牌的业务操作等。云管客户端组件实现了入云注册、监听数据上报、边缘云-中心云的用户业务及命令数据上报。网关通信代理实现了与电子标牌网关的数据通信、命令下发。分布式组件实现了边缘云的分布式高可用性,并保证数据一致性。The edge cloud is an autonomous node deployed on the user's edge side, including the edge cloud business platform, cloud management client components, distributed components, gateway communication agents, etc. The edge cloud business platform realizes the visualization of user business data, distributed creation and management, and business operations of electronic signage. The cloud management client component realizes cloud registration, monitoring data reporting, edge cloud-central cloud user business and command data reporting. The gateway communication agent realizes the data communication and order issuing with the electronic signage gateway. Distributed components realize distributed high availability of edge cloud and ensure data consistency.
网关用于管控用户区域范围内的电子标牌,与中心云/边缘云进行上下行数据通信。The gateway is used to control the electronic signage within the user's area, and perform uplink and downlink data communication with the central cloud/edge cloud.
电子标牌用于显示网关下发的信息。The electronic signage is used to display the information issued by the gateway.
本申请实施例中,用户与中心云、中心云与边缘云、边缘云与网关等之间可以通过网络进行通信连接,当接收到用户通过客户端发出的电子标牌的显示请求,可以根据电子标牌的数量和/或中心云响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求。In the embodiment of this application, the communication between the user and the central cloud, the central cloud and the edge cloud, and the edge cloud and the gateway can be connected through the network. and/or the expected response time for the central cloud to respond to the display request, determine a responder that responds to the display request, and respond to the display request based on the responder.
具体的,图2示出了本申请实施例提供的一种请求处理方法的流程图。该方法应用于中心云服务器,该服务器可以提供云服务、云数据库、云计算、云函数、云存储、网络服务、云通信、中间件服务、域名服务、安全服务、CDN(Content Delivery Network,内容分发网络)、以及大数据和人工智能平台等基础云计算服务的云服务器或服务器集群。Specifically, FIG. 2 shows a flowchart of a request processing method provided by an embodiment of the present application. The method is applied to a central cloud server, which can provide cloud service, cloud database, cloud computing, cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, CDN (Content Delivery Network, content distribution network), and cloud servers or server clusters for basic cloud computing services such as big data and artificial intelligence platforms.
本领域技术人员应能理解上述服务器仅为举例,其他现有的或今后可能出现的服务器如可适用于本申请,也应包含在本申请保护范围以内,并在此以引用方式包含于此。Those skilled in the art should understand that the above servers are only examples, and other existing or future servers that are applicable to this application should also be included in the scope of protection of this application, and are included here by reference.
如图2所示,该方法包括以下步骤:As shown in Figure 2, the method includes the following steps:
步骤S201:接收客户端发送的请求显示目标电子标牌的显示请求。Step S201: Receive a display request from a client terminal for displaying a target electronic signage.
本申请实施例可以应用于计算机技术领域,具体可以应用于接收到请求显示目标电子标牌的显示请求,响应所述显示请求,控制所述目标电子标牌显示相应的标牌内容的应用场景。The embodiments of the present application can be applied to the field of computer technology, and specifically can be applied to an application scenario where a display request for displaying a target electronic sign is received, and the target electronic sign is controlled to display corresponding sign content in response to the display request.
具体而言,目标电子标牌可以是应用场景中欲显示标牌内容的电子标牌,其中,具体的应用场景例如智慧零售、智慧办公及智慧交通等场景,以智慧办公场景中的会议办公场景为例,常见的电子标牌产品包括会议门牌、桌牌及工位牌等。例如,在标牌是桌牌的情况下,所述标牌内容包括参会人员的相关信息,例如姓名、工作单位、职务等中的一类或多类等。在标牌是工位牌的情况下,所述标牌内容包括在该工位处的人员的信息、工位预定信息、广告信息等。在标牌是会议室门牌的情况下,所述标牌内容包括会议室的调度信息、广告信息等。Specifically, the target electronic signage can be an electronic signage that needs to display the content of the signage in the application scenario. The specific application scenarios include smart retail, smart office, and smart transportation. Take the conference office scene in the smart office scene as an example. Common electronic signage products include conference door signs, table signs and workstation signs, etc. For example, in the case that the signboard is a table card, the content of the signboard includes relevant information of the participants, such as one or more types of names, work units, positions, and the like. In the case that the sign is a work station sign, the contents of the sign include information on personnel at the work station, station reservation information, advertisement information, and the like. In the case that the sign is a conference room door plate, the content of the sign includes scheduling information, advertisement information, etc. of the meeting room.
显示请求可以通过终端上安装的客户端发出,例如,当需要在目标电子标牌上显示标牌内容时,可以通过所述客户端发出所述显示请求。例如,在会议办公场景中,终端可以为会议管理员对应的终端。需要说明的是,该会议管理员可以为参加会议的指定的用户的终端,例如,会议主持人持有的终端;当然,也可以为用来管理各会议、但未加入会议的用户终端,本申请实施例对此不做限制。The display request can be sent through the client installed on the terminal, for example, when the signage content needs to be displayed on the target electronic signage, the display request can be sent through the client. For example, in a conference office scenario, the terminal may be a terminal corresponding to a conference administrator. It should be noted that the conference administrator may be a terminal of a designated user participating in the conference, for example, a terminal held by the conference host; The application embodiment does not limit this.
可选的,所述显示请求中可以包括目标电子标牌的数量、目标电子标牌的编码(Identity document,ID)、目标电子标牌将显示的标牌内容、显示标牌内容的预设显示模板、目标电子标牌显示所述标牌内容的显示时间、更新标牌内容的更新时间等等。Optionally, the display request may include the quantity of the target electronic signage, the code (Identity document, ID) of the target electronic signage, the signage content to be displayed by the target electronic signage, the preset display template for displaying the content of the signage, and the target electronic signage The display time of the content of the signage, the update time of updating the content of the signage, etc. are displayed.
其中,预设显示模板为预先确定的显示标牌内容的模板,预设显示模板中可以包括显示标牌内容的字体、字号、颜色、排版格式等。Wherein, the preset display template is a predetermined template for displaying signage content, and the preset display template may include the font, font size, color, typesetting format, etc. of the display signage content.
步骤S202:根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端。Step S202: Determine the responder that responds to the display request according to the number of the requested target electronic signs in the display request and/or the estimated response time of the central cloud server to the display request.
其中,所述响应端包括所述中心云服务器和/或与所述中心云服务器具有通信连接的边缘云服务器。Wherein, the responding end includes the central cloud server and/or an edge cloud server having a communication connection with the central cloud server.
具体而言,响应端为响应所述显示请求的服务器,具体而言,响应端用于根据所述显示请求获取目标电子标牌的标牌内容,并将所述标牌内容通过网关等设备发送至目标电子标牌,控制所述目标电子标牌显示所述标牌内容。Specifically, the responding end is a server that responds to the display request. Specifically, the responding end is used to obtain the signage content of the target electronic signage according to the display request, and send the signage content to the target electronic signage through gateways and other devices. A signage, controlling the target electronic signage to display the content of the signage.
在确定响应所述响应请求的响应端时,可以根据所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定由所述中心云服务器和/或与所述边缘云服务器作为所述响应端。When determining the responding end that responds to the response request, it may be determined that the central cloud server and/or with The edge cloud server serves as the responding end.
可选的,当所述目标电子标牌的数量较少,或者所述预计响应时长较短时,可以通过所述中心云服务器作为响应端响应所述显示请求。当所述目标电子标牌的数量较多,或者所述预计响应时长较长时,可以通过所述中心云服务器及至少一个所述边缘云服务器作为响应端响应所述显示请求。Optionally, when the number of the target electronic signs is small, or the expected response time is short, the central cloud server may be used as a responding end to respond to the display request. When the number of the target electronic signs is large, or the expected response time is long, the central cloud server and at least one edge cloud server may be used as responders to respond to the display request.
具体而言,所述预计响应时长可以根据所述中心云服务器的空闲处理资源和/或处理速度确定。其中,空闲处理资源可以根据中央处理器(Central Processing Unit,CPU)的使用率、图形处理器(Graphic Processing Unit,GPU)的使用率、加速处理器(Accelerated Processing Units,APU)的使用率等确定。可以理解的是,中心云服务器的空闲处理资源越多、处理速度越快,所述预计响应时长越短;反之,中心云服务器的空闲处理资源越少、处理速度越慢,所述预计响应时长越长。Specifically, the estimated response time may be determined according to idle processing resources and/or processing speed of the central cloud server. Wherein, the idle processing resource may be determined according to the utilization rate of the central processing unit (Central Processing Unit, CPU), the utilization rate of the graphics processing unit (Graphic Processing Unit, GPU), the utilization rate of the accelerated processing unit (Accelerated Processing Units, APU), etc. . It can be understood that the more idle processing resources and faster processing speed of the central cloud server, the shorter the expected response time; longer.
也就是说,本申请实施例中,在目标电子标牌数量较少、所述中心云服务器的空闲处理资源较多、所述中心云服务器的处理速度较快等情况下,可以由中心云服务器响应所述显示请求;反之,在目标电子标牌数量较多、所述中心云服务器的空闲处理资源较少、所述中心云服务器的处理速度较慢等情况下,可以由中心云服务器以及边缘云服务器响应所述显示请求。That is to say, in this embodiment of the application, when the number of target electronic signs is small, the idle processing resources of the central cloud server are large, and the processing speed of the central cloud server is fast, etc., the central cloud server may respond The display request; on the contrary, when the number of target electronic signs is large, the idle processing resources of the central cloud server are less, and the processing speed of the central cloud server is slow, etc., the central cloud server and the edge cloud server can Respond to the display request.
需要说明的是,由中心云服务器以及边缘云服务器响应所述显示请求时,还可以根据所述目标电子标牌数量、所述中心云服务器的空闲处理资源、所述中心云服务器的处理速度的具体情况,确定由一个边缘云服务器或者多个边缘云服务器来响应。例如,当目标电子标牌数量极多(如目标电子标牌的数量大于相应阈值)、或者中心云服务器的空闲处理资源很少(如空闲处理资源小于相应阈值)、或者中心云服务器的处理速度很慢(如处理速度小于相应阈值)时,在这种待响应任务量很大、或者中心云服务器的空闲处理资源较少、处理速度较慢时,可以通过中心云服务器及多个边缘云服务器来响应,以降低任务处理压力,提升响应速度。It should be noted that when the central cloud server and the edge cloud server respond to the display request, they may also be based on the number of target electronic signs, the idle processing resources of the central cloud server, and the processing speed of the central cloud server. situation, it is determined that one edge cloud server or multiple edge cloud servers respond. For example, when the number of target electronic signs is extremely large (for example, the number of target electronic signs is greater than the corresponding threshold), or the idle processing resources of the central cloud server are few (for example, the idle processing resources are less than the corresponding threshold), or the processing speed of the central cloud server is very slow (such as the processing speed is less than the corresponding threshold), when the amount of tasks to be responded is large, or the central cloud server has less idle processing resources and the processing speed is slower, the central cloud server and multiple edge cloud servers can be used to respond , to reduce task processing pressure and improve response speed.
其中,由中心云服务器以及边缘云服务器响应所述显示请求时,中心云服务器可以与边缘云服务器进行通信连接,向边缘云服务器发送目标电子标牌的标牌内容等,以实现将数据下沉至所述边缘云服务器,以通过所述边缘云服务器控制所述目标电子标牌的显示。Wherein, when the central cloud server and the edge cloud server respond to the display request, the central cloud server can communicate with the edge cloud server, and send the sign content of the target electronic signage to the edge cloud server, so as to realize sinking the data to the edge cloud server. The edge cloud server is used to control the display of the target electronic signage through the edge cloud server.
可选的,边缘云服务器可以通过LwM2M、UDP、TCP、HTTP、MQTT等通讯协议连接中心云服务器。Optionally, the edge cloud server can connect to the central cloud server through communication protocols such as LwM2M, UDP, TCP, HTTP, and MQTT.
确定响应所述显示请求的响应端,可以实现根据实际场景中目标电子标牌的数量情况以及中心云服务器的空闲处理资源以及处理速度等情况,确定响应端,这样,可以根据实际场景需求,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。Determining the response end that responds to the display request can be determined according to the number of target electronic signs in the actual scene and the idle processing resources and processing speed of the central cloud server. In this way, it can be flexibly determined according to the actual scene requirements The display request is responded to by the central cloud server and/or the edge cloud server, which relieves the processing pressure of the central cloud server, reduces network bandwidth occupation, and reduces calculation delay.
步骤S203:基于所述响应端,响应所述显示请求。Step S203: Respond to the display request based on the responder.
确定响应端之后,可以基于所述响应端,响应所述显示请求。After the responder is determined, the display request may be responded based on the responder.
具体而言,当通过中心云服务器响应所述显示请求时,可以先根据所述显示请求获取所述目标电子标牌的标牌内容以及预设显示模板,并在预设显示模板中添加所述标牌内容,这样,可以基于添加标牌内容的预设显示模板生成显示文件。Specifically, when the central cloud server responds to the display request, the signage content and the preset display template of the target electronic signage can be obtained first according to the display request, and the signage content can be added to the preset display template , so that display files can be generated based on preset display templates that add signage content.
然后,向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。Then, send the display instruction and the display file to the preset gateway, so as to send the display file to the target electronic signage through the preset gateway, and instruct the target electronic signage to display the display file through the preset display template. The content of the label.
其中,在实际场景中,预设网关可以包括但不限于蓝牙网关、Wi-Fi(WirelessFidelity,无线保真技术)网关等,具体可以根据实际情况确定。Wherein, in an actual scenario, the preset gateway may include but not limited to a Bluetooth gateway, a Wi-Fi (Wireless Fidelity, wireless fidelity technology) gateway, etc., which may be determined according to actual conditions.
此外,当通过中心云服务器及至少一个所述边缘云服务器响应所述显示请求时,中心云服务器可以与边缘云服务器进行通信连接,向边缘云服务器发送上述显示文件,以通过边缘云服务器向预设网关发送显示指令以及所述显示文件,然后通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。In addition, when the central cloud server and at least one edge cloud server respond to the display request, the central cloud server can communicate with the edge cloud server and send the display file to the edge cloud server, so as to send the display file to the edge cloud server through the edge cloud server. It is assumed that the gateway sends a display instruction and the display file, and then sends the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the signage content through the preset display template.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
在本申请的一个实施例中,所述确定响应所述显示请求的响应端,包括:In an embodiment of the present application, the determination of the responder that responds to the display request includes:
确定所述目标电子标牌的数量小于第一预设阈值,和/或所述预计响应时长小于第二预设阈值的情况下,确定所述中心云服务器为所述响应端;When it is determined that the number of the target electronic signs is less than a first preset threshold, and/or the expected response time is less than a second preset threshold, determine that the central cloud server is the responding end;
确定所述目标电子标牌的数量大于第一预设阈值,和/或所述预计响应时长大于第二预设阈值的情况下,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端。When it is determined that the number of the target electronic signs is greater than a first preset threshold, and/or the expected response time is greater than a second preset threshold, it is determined that the central cloud server and at least one edge cloud server are the Response end.
具体而言,实际场景中,确定所述响应端时,可以将所述目标电子标牌的数量以及所述预计响应时长分别与对应的阈值进行比较。Specifically, in an actual scenario, when determining the responding end, the number of the target electronic signs and the expected response time may be compared with corresponding thresholds.
例如,可以在所述目标电子标牌的数量小于第一预设阈值,和/或所述预计响应时长小于第二预设阈值的情况下,确定所述中心云服务器为所述响应端;在所述目标电子标牌的数量大于第一预设阈值,和/或所述预计响应时长大于第二预设阈值的情况下,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端。For example, it may be determined that the central cloud server is the responding end when the number of the target electronic signs is less than a first preset threshold, and/or the expected response time is less than a second preset threshold; If the number of the target electronic signs is greater than the first preset threshold, and/or the expected response time is greater than the second preset threshold, determine the central cloud server and at least one edge cloud server as the responding end .
可选的,第二预设阈值可以设置为显示请求中携带的响应时长,该携带的响应时长可以理解为客户端设置的响应该显示请求的最大响应时长。Optionally, the second preset threshold may be set as the response duration carried in the display request, and the carried response duration may be understood as the maximum response duration set by the client to respond to the display request.
在一些实施例中,当所述目标电子标牌的数量大于第三预设阈值,和/或所述预计响应时长大于第四预设阈值时(第三预设阈值大于第一预设阈值;第四预设阈值小于第二预设阈值),也就是说,目标电子标牌的数量极多,或者客户端设置的最大响应时长很短,也即对响应所述显示请求的实时性要求极高时,可以确定中心云服务器及多个所述边缘云服务器作为所述响应端。In some embodiments, when the number of the target electronic signs is greater than a third preset threshold, and/or the expected response time is greater than a fourth preset threshold (the third preset threshold is greater than the first preset threshold; the second Four preset thresholds are less than the second preset threshold), that is, the number of target electronic signs is extremely large, or the maximum response time set by the client is very short, that is, when the real-time requirement for responding to the display request is extremely high , a central cloud server and multiple edge cloud servers may be determined as the responding end.
在本申请的一个实施例中,确定所述中心云服务器为所述响应端的情况下,In one embodiment of the present application, when it is determined that the central cloud server is the responding end,
所述基于所述响应端,响应所述显示请求,包括:The responding to the display request based on the responding end includes:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
具体而言,当通过中心云服务器响应所述显示请求时,即目标电子标牌数量较少、所述中心云服务器的空闲处理资源较多、所述中心云服务器的处理速度较快等情况下,可以先根据所述显示请求获取所述目标电子标牌的标牌内容以及预设显示模板,并在预设显示模板中添加所述标牌内容,这样,可以基于添加标牌内容的预设显示模板生成显示文件。Specifically, when the central cloud server responds to the display request, that is, when the number of target electronic signs is small, the central cloud server has more idle processing resources, and the central cloud server has a faster processing speed, etc., The signage content and the preset display template of the target electronic signage can be obtained first according to the display request, and the signage content can be added to the preset display template, so that the display file can be generated based on the preset display template for adding the signage content .
然后,向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。Then, send the display instruction and the display file to the preset gateway, so as to send the display file to the target electronic signage through the preset gateway, and instruct the target electronic signage to display the display file through the preset display template. The content of the label.
作为示例,下面结合图3来介绍实际场景中,由中心云服务器作为响应端的处理流程。As an example, in combination with FIG. 3 , the following describes the processing flow of the central cloud server as the responder in an actual scenario.
步骤1:用户可以通过万维网(World Wide Web,WEB),访问中心云服务器的业务平台,注册账号并登录。Step 1: The user can access the business platform of the central cloud server through the World Wide Web (WEB), register an account and log in.
步骤2:网关(即本申请实施例中的预设网关)联网;用户可以访问网关自带的WEB页面,配置中心云服务器地址。Step 2: The gateway (that is, the preset gateway in the embodiment of the present application) is connected to the Internet; the user can access the WEB page provided by the gateway to configure the address of the central cloud server.
步骤3:用户可以在中心云服务器的业务平台添加网关,并对网关进行配置,例如,配置通信信道、搜索时间、接口地址等。Step 3: The user can add a gateway to the service platform of the central cloud server, and configure the gateway, for example, configure communication channels, search time, interface addresses, etc.
步骤4:网关上线后,网关自动连接中心云服务器,通过中心云服务器的验证后,网关从中心云服务器获取已配置的数据(配置通信信道、搜索时间、接口地址)。Step 4: After the gateway goes online, the gateway automatically connects to the central cloud server. After passing the verification of the central cloud server, the gateway obtains the configured data (communication channel configuration, search time, interface address) from the central cloud server.
步骤5:用户可以添加电子标牌,并开启网关的自动搜索功能,网关搜索到搜索范围内的电子标牌后,绑定电子标牌,然后向中心云服务器上报电子标牌信息。Step 5: Users can add electronic signs and enable the automatic search function of the gateway. After the gateway searches for electronic signs within the search range, it binds the electronic signs and then reports the information of the electronic signs to the central cloud server.
步骤6:用户创建电子标牌的显示模板(即本申请实施例中的预设显示模板),并配置显示模板。Step 6: The user creates a display template of the electronic signage (that is, the preset display template in this embodiment of the application), and configures the display template.
步骤7:用户选择需要使用的目标电子标牌,并绑定显示模板。Step 7: The user selects the target electronic signage to be used, and binds the display template.
步骤8:满足电子标牌的刷新条件时,中心云服务器根据电子标牌绑定的模板和标牌内容,生成显示文件及显示指令,并将显示文件及显示指令发送到网关,通过网关将显示文件发送到目标电子标牌,通过目标电子标牌显示标牌内容。Step 8: When the refresh conditions of the electronic signage are satisfied, the central cloud server generates display files and display instructions according to the templates bound to the electronic signage and signage content, and sends the display files and display instructions to the gateway, and then sends the display files to The target electronic signage displays the content of the signage through the target electronic signage.
在本申请的一个实施例中,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端的情况下,In an embodiment of the present application, when it is determined that the central cloud server and at least one edge cloud server are the responding end,
所述基于所述响应端,响应所述显示请求,包括:The responding to the display request based on the responding end includes:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
与目标边缘云服务器建立通信连接;向所述目标边缘云服务器发送所述显示文件,以通过所述目标边缘云服务器向预设网关发送显示指令以及所述显示文件,通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。Establish a communication connection with the target edge cloud server; send the display file to the target edge cloud server, so as to send a display instruction and the display file to the preset gateway through the target edge cloud server, and send the display file to the default gateway through the target edge cloud server The display file is sent to the target electronic signage, instructing the target electronic signage to display the signage content through the preset display template.
当通过中心云服务器及至少一个所述边缘云服务器响应所述显示请求时,一方面,中心云服务器可以先根据所述显示请求获取所述目标电子标牌的标牌内容以及预设显示模板,并在预设显示模板中添加所述标牌内容,这样,可以基于添加标牌内容的预设显示模板生成显示文件。When the central cloud server and at least one of the edge cloud servers respond to the display request, on the one hand, the central cloud server can first obtain the signage content and the preset display template of the target electronic signage according to the display request, and then The signage content is added to the preset display template, so that the display file can be generated based on the preset display template to which the signage content is added.
另一方面,中心云服务器可以与边缘云服务器进行通信连接,向边缘云服务器发送上述显示文件,以通过边缘云服务器向预设网关发送显示指令以及所述显示文件,然后通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。On the other hand, the central cloud server can communicate with the edge cloud server, and send the above-mentioned display file to the edge cloud server, so as to send display instructions and the display file to the preset gateway through the edge cloud server, and then pass the preset gateway sending the display file to the target electronic signage, instructing the target electronic signage to display the signage content through the preset display template.
作为示例,下面结合图4来介绍实际场景中,由中心云服务器及边缘云服务器作为响应端的处理流程。As an example, the following describes the processing flow in an actual scenario with the central cloud server and the edge cloud server as the responding end in conjunction with FIG. 4 .
步骤1:用户可以通过WEB,访问边缘云服务器的业务平台,使用默认账号登录。Step 1: The user can access the service platform of the edge cloud server through the WEB, and log in with the default account.
步骤2:用户在边缘云服务器的业务平台配置中心云服务器地址和安全证书,同时记录边缘云服务器的系统编号。Step 2: The user configures the central cloud server address and security certificate on the business platform of the edge cloud server, and records the system number of the edge cloud server at the same time.
步骤3:边缘云服务器根据配置的中心云服务器地址和安全证书,自动连接中心云服务器。Step 3: The edge cloud server automatically connects to the central cloud server according to the configured central cloud server address and security certificate.
步骤4:用户通过WEB访问中心云服务器的业务平台,注册账号并登录。Step 4: The user accesses the service platform of the central cloud server through WEB, registers an account and logs in.
步骤5:用户在中心云服务器的业务平台添加边缘云服务器(步骤2中记录系统编号的边缘云服务器)。Step 5: The user adds an edge cloud server (the edge cloud server whose system number was recorded in step 2) on the business platform of the central cloud server.
步骤6:中心云服务器向边缘云端点发送电子标牌用户的变更命令;边缘云服务器接收到变更命令后,清除历史数据。Step 6: The central cloud server sends the change command of the electronic signage user to the edge cloud point; the edge cloud server clears the historical data after receiving the change command.
步骤7:网关(即本申请实施例中的预设网关)联网;用户可以访问网关自带的WEB页面,配置中心云服务器地址。Step 7: The gateway (that is, the preset gateway in the embodiment of the present application) is connected to the Internet; the user can access the WEB page of the gateway to configure the address of the central cloud server.
步骤8:用户可以在中心云服务器的业务平台添加网关,并对网关进行配置,例如,配置通信信道、搜索时间、接口地址等。中心云服务器向边缘云服务器写入网关数据,以及向网关写入边缘云服务器地址。Step 8: The user can add a gateway to the service platform of the central cloud server, and configure the gateway, for example, configure the communication channel, search time, interface address, etc. The central cloud server writes gateway data to the edge cloud server, and writes the edge cloud server address to the gateway.
步骤9:网关上线后,自动连接边缘云服务器,通过边缘云服务器,的验证后,网关从边缘云服务器获取已配置的数据(配置通信信道、搜索时间、接口地址)。Step 9: After the gateway goes online, it automatically connects to the edge cloud server. After passing the verification of the edge cloud server, the gateway obtains the configured data (communication channel configuration, search time, interface address) from the edge cloud server.
步骤10:在中心云服务器的业务平台上添加电子标牌。Step 10: Add electronic signage on the business platform of the central cloud server.
步骤11:在边缘云服务器的业务平台上开启网关的自动搜索,网关搜索到搜索范围内的电子标牌后,绑定电子标牌,然后向边缘云服务器上报电子标牌标识信息。Step 11: Enable the automatic search of the gateway on the service platform of the edge cloud server. After the gateway searches for electronic signs within the search range, bind the electronic signs, and then report the identification information of the electronic signs to the edge cloud server.
步骤12:用户在中心云服务器的业务平台上,创建电子标牌的显示模板(即本申请实施例中的预设显示模板),并配置显示模板。用户选择需要使用的目标电子标牌,并绑定显示模板。Step 12: On the service platform of the central cloud server, the user creates a display template of the electronic signage (that is, the preset display template in this embodiment of the application), and configures the display template. The user selects the target electronic signage to be used and binds the display template.
步骤13:中心云服务器根据电子标牌绑定的模板和标牌内容,生成显示文件,并将显示文件发送到边缘云服务器。Step 13: The central cloud server generates a display file according to the template bound to the electronic signage and the content of the signage, and sends the display file to the edge cloud server.
步骤14:满足电子标牌的刷新条件时,边缘云服务器将显示文件及显示指令发送到网关,通过网关将显示文件发送到目标电子标牌,通过目标电子标牌显示标牌内容。Step 14: When the refresh conditions of the electronic signage are satisfied, the edge cloud server sends the display file and display command to the gateway, and then sends the display file to the target electronic signage through the gateway, and displays the content of the signage through the target electronic signage.
上述过程,数据下沉至边缘云服务器,这样,当中心云服务器异常、宕机,或者网络异常时,能够实现边缘云服务器离线自治,业务正常运行,即提高了电子标牌的使用效率又降低了中心云服务器的系统压力。In the above process, the data sinks to the edge cloud server. In this way, when the central cloud server is abnormal, down, or the network is abnormal, the edge cloud server can realize offline autonomy and normal business operation, which improves the use efficiency of electronic signs and reduces The system pressure of the central cloud server.
在本申请的一个实施例中,在所述边缘云服务器包括多个服务器的情况下,所述生成显示文件之后,所述方法还包括:In one embodiment of the present application, when the edge cloud server includes multiple servers, after the display file is generated, the method further includes:
根据每个所述边缘云服务器对应的随机超时时长,确定所述边缘云服务器中的目标边缘云服务器;Determine a target edge cloud server in the edge cloud servers according to the random timeout period corresponding to each edge cloud server;
与所述目标边缘云服务器建立通信连接。Establish a communication connection with the target edge cloud server.
具体而言,目标电子标牌的数量极多,或者客户端设置的最大响应时长很短,也即对响应所述显示请求的实时性要求极高时,可以确定中心云服务器及多个所述边缘云服务器作为所述响应端。Specifically, when the number of target electronic signs is extremely large, or the maximum response time set by the client is very short, that is, when the real-time requirement for responding to the display request is extremely high, the central cloud server and multiple edge The cloud server acts as the responding end.
在多个边缘云服务器中,需要根据每个所述边缘云服务器对应的随机超时时长,确定出一个目标边缘云服务器作为管理节点,通过所述管理节点来接收中心云服务器发送的显示文件,并将所述显示文件下发至其他边缘云服务器,并分配相应的响应显示目标电子标牌的任务至其他边缘云节点。例如,当响应显示请求时,由管理节点决定由各边缘云服务器所响应显示的电子标牌等。Among the multiple edge cloud servers, it is necessary to determine a target edge cloud server as a management node according to the random timeout period corresponding to each edge cloud server, and receive the display file sent by the central cloud server through the management node, and The display file is sent to other edge cloud servers, and the corresponding task of responding and displaying the target electronic signage is assigned to other edge cloud nodes. For example, when responding to a display request, the management node determines the electronic signage to be displayed by each edge cloud server.
可选的,本申请实施例中确定目标边缘云服务器可以通过选举流程实现,以下,结合图5对选举流程进行说明:Optionally, the determination of the target edge cloud server in this embodiment of the application can be implemented through an election process. The election process will be described below in conjunction with FIG. 5:
例如,存在三个边缘云服务器,三个边缘云服务器分别记为节点A、节点B、节点C。For example, there are three edge cloud servers, and the three edge cloud servers are respectively marked as node A, node B, and node C.
选举前即任期编号为0,每个节点都是Follower(跟随者),每个节点具有一个随机超时。其中,节点A的随机超时时长为100ms(毫秒)、节点B的随机超时时长为120ms、节点C的随机超时时长为150ms。Before the election, the term number is 0, each node is a Follower (follower), and each node has a random timeout. Wherein, the random timeout period of node A is 100ms (milliseconds), the random timeout period of node B is 120ms, and the random timeout period of node C is 150ms.
选举时,A节点的随机超时最小,所以,A节点最先唤醒,成功晋级为Candidate(候选人),任期编号变为为1,A节点自投一票,再向其他Follower发起请求投票。During the election, the random timeout of node A is the smallest. Therefore, node A wakes up first and is successfully promoted to Candidate (candidate). The term number becomes 1. Node A self-votes, and then initiates a request to vote to other Followers.
节点B和节点C收到节点A的投票请求后,判断在任期编号为1的选举中是否有投过票,如果没有,会把选票投给A,并把自己的任期编号设置为1,并重置自己的随机超时。After node B and node C receive the voting request from node A, they will judge whether they have voted in the election with the term number 1. If not, they will vote for A, and set their term number as 1, and Resets own random timeout.
节点A在任期编号为1的选举内赢得大多数选票,成为本任期的Leader(管理节点)。为保持该管理节点身份,节点A会不间断给节点B和节点C发送心跳(心跳可以理解为指令),指示节点B和节点C重置随机超时,防止B和C重新发起投票。Node A wins the majority of votes in the election with term number 1 and becomes the Leader (management node) of this term. In order to maintain the identity of the management node, node A will continuously send heartbeats to node B and node C (heartbeats can be understood as instructions), instructing node B and node C to reset the random timeout to prevent B and C from re-initiating voting.
需要说明的是,如果各节点的随机超时时间相同,则最先获得大多数选票的节点成为Leader,其他Candidate恢复成Follower。如果选票数相同,所有节点恢复成Follower,重新设置随机超时时间,准备下一轮选举。It should be noted that if the random timeout time of each node is the same, the node that first obtains the majority of votes will become the Leader, and the other Candidates will return to Follower. If the number of votes is the same, all nodes will return to Follower, reset the random timeout time, and prepare for the next round of elections.
当Leader宕机时,所有节点会重新选举产生新的Leader,新Leader会按照原注册信息,继续与中心云服务器通信。When the Leader goes down, all nodes will re-elect a new Leader, and the new Leader will continue to communicate with the central cloud server according to the original registration information.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
具体的,图6示出了本申请实施例提供的一种请求处理方法的流程图。该方法应用于第一边缘云服务器,该服务器可以提供云服务、云数据库、云计算、云函数、云存储、网络服务、云通信、中间件服务、域名服务、安全服务、CDN(Content Delivery Network,内容分发网络)、以及大数据和人工智能平台等基础云计算服务的云服务器或服务器集群。Specifically, FIG. 6 shows a flow chart of a request processing method provided by an embodiment of the present application. The method is applied to the first edge cloud server, which can provide cloud service, cloud database, cloud computing, cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, CDN (Content Delivery Network) , content distribution network), and cloud servers or server clusters for basic cloud computing services such as big data and artificial intelligence platforms.
本领域技术人员应能理解上述服务器仅为举例,其他现有的或今后可能出现的服务器如可适用于本申请,也应包含在本申请保护范围以内,并在此以引用方式包含于此。Those skilled in the art should understand that the above servers are only examples, and other existing or future servers that are applicable to this application should also be included in the scope of protection of this application, and are included here by reference.
如图6所示,该方法包括以下步骤:As shown in Figure 6, the method includes the following steps:
步骤S601:响应于客户端发送的请求显示目标电子标牌的显示请求,与中心云服务器建立通信连接。Step S601: Establish a communication connection with the central cloud server in response to the display request sent by the client for requesting display of the target electronic signage.
其中,所述目标电子标牌的数量大于第一预设阈值,和/或所述中心云服务器响应所述显示请求的预计响应时长大于第二预设阈值;Wherein, the number of the target electronic signs is greater than a first preset threshold, and/or the estimated response time of the central cloud server in response to the display request is greater than a second preset threshold;
本申请实施例可以应用于计算机技术领域,具体可以应用于接收到请求显示目标电子标牌的显示请求,响应所述显示请求,控制所述目标电子标牌显示相应的标牌内容的应用场景。The embodiments of the present application can be applied to the field of computer technology, and specifically can be applied to an application scenario where a display request for displaying a target electronic sign is received, and the target electronic sign is controlled to display corresponding sign content in response to the display request.
具体而言,目标电子标牌可以是应用场景中欲显示标牌内容的电子标牌。Specifically, the target electronic signage may be an electronic signage to display signage content in an application scenario.
显示请求可以通过终端上安装的客户端发出,例如,当需要在目标电子标牌上显示标牌内容时,可以通过所述客户端发出所述显示请求。The display request can be sent through the client installed on the terminal, for example, when the signage content needs to be displayed on the target electronic signage, the display request can be sent through the client.
可选的,所述显示请求中可以包括目标电子标牌的数量、目标电子标牌的编码(Identity document,ID)、目标电子标牌将显示的标牌内容、显示标牌内容的预设显示模板、目标电子标牌显示所述标牌内容的显示时间、更新标牌内容的更新时间等等。Optionally, the display request may include the quantity of the target electronic signage, the code (Identity document, ID) of the target electronic signage, the signage content to be displayed by the target electronic signage, the preset display template for displaying the content of the signage, and the target electronic signage The display time of the content of the signage, the update time of updating the content of the signage, etc. are displayed.
其中,预设显示模板为预先确定的显示标牌内容的模板,预设显示模板中可以包括显示标牌内容的字体、字号、颜色、排版格式等。Wherein, the preset display template is a predetermined template for displaying signage content, and the preset display template may include the font, font size, color, typesetting format, etc. of the display signage content.
当所述目标电子标牌的数量大于第一预设阈值,和/或所述预计响应时长大于第二预设阈值的情况下,可以确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端。When the number of the target electronic signs is greater than a first preset threshold, and/or the expected response time is greater than a second preset threshold, it may be determined that the central cloud server and at least one edge cloud server are all The above-mentioned response terminal.
响应于客户端发送的请求显示目标电子标牌的显示请求,边缘云服务器可以与中心云服务器建立通信连接。可选的,边缘云服务器可以通过LwM2M、UDP、TCP、HTTP、MQTT等通讯协议连接中心云服务器。In response to the display request sent by the client to request display of the target electronic signage, the edge cloud server can establish a communication connection with the central cloud server. Optionally, the edge cloud server can connect to the central cloud server through communication protocols such as LwM2M, UDP, TCP, HTTP, and MQTT.
步骤S602:响应所述显示请求。Step S602: Respond to the display request.
可选的,边缘云服务器接收并存储所述中心云服务器发送的显示文件;其中,所述显示文件是基于在示模板中添加所述目标电子标牌的标牌内容生成的;Optionally, the edge cloud server receives and stores the display file sent by the central cloud server; wherein, the display file is generated based on the sign content of the target electronic sign added to the display template;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
具体而言,当通过中心云服务器及至少一个所述边缘云服务器响应所述显示请求时,一方面,中心云服务器可以先根据所述显示请求获取所述目标电子标牌的标牌内容以及预设显示模板,并在预设显示模板中添加所述标牌内容,这样,可以基于添加标牌内容的预设显示模板生成显示文件。Specifically, when the central cloud server and at least one of the edge cloud servers respond to the display request, on the one hand, the central cloud server can first obtain the signage content and preset display of the target electronic signage according to the display request template, and add the signage content in the preset display template, so that the display file can be generated based on the preset display template with the added signage content.
另一方面,中心云服务器可以与边缘云服务器进行通信连接,向边缘云服务器发送上述显示文件,以通过边缘云服务器向预设网关发送显示指令以及所述显示文件,然后通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。On the other hand, the central cloud server can communicate with the edge cloud server, and send the above-mentioned display file to the edge cloud server, so as to send display instructions and the display file to the preset gateway through the edge cloud server, and then pass the preset gateway sending the display file to the target electronic signage, instructing the target electronic signage to display the signage content through the preset display template.
在本申请的一个实施例中,还包括第二边缘云服务器,In one embodiment of the present application, it also includes a second edge cloud server,
所述接收所述中心云服务器发送的显示文件之后,所述方法还包括:After receiving the display file sent by the central cloud server, the method further includes:
向所述第二边缘云服务器发送所述显示文件,以通过所述第二边缘云服务器向预设网关发送显示指令以及所述显示文件。Sending the display file to the second edge cloud server, so as to send a display instruction and the display file to a preset gateway through the second edge cloud server.
具体而言,目标电子标牌的数量极多,或者客户端设置的最大响应时长很短,也即对响应所述显示请求的实时性要求极高时,可以确定中心云服务器及多个所述边缘云服务器作为所述响应端。其中,第二边缘云服务器即为所述多个边缘云服务器中第一边缘云服务器以外的边缘云服务器,结合上述实施例,第一边缘云服务器即为所述多个边缘云服务器中的管理节点。Specifically, when the number of target electronic signs is extremely large, or the maximum response time set by the client is very short, that is, when the real-time requirement for responding to the display request is extremely high, the central cloud server and multiple edge The cloud server acts as the responding end. Wherein, the second edge cloud server is an edge cloud server other than the first edge cloud server among the plurality of edge cloud servers. node.
实际场景中,由多个边缘云服务器作为响应端时,需要根据每个所述边缘云服务器对应的随机超时时长,确定出一个边缘云服务器(即第一边缘云服务器)作为管理节点,通过所述管理节点来接收中心云服务器发送的显示文件,并将所述显示文件下发至其他边缘云服务器(第二边缘云服务器),并分配相应的响应显示目标电子标牌的任务至其他边缘云节点。例如,当响应显示请求时,由管理节点决定由各第二边缘云服务器所响应显示的电子标牌等。In an actual scenario, when multiple edge cloud servers are used as the responding end, it is necessary to determine an edge cloud server (that is, the first edge cloud server) as the management node according to the random timeout period corresponding to each edge cloud server, and pass the The above management node receives the display file sent by the central cloud server, and sends the display file to other edge cloud servers (second edge cloud server), and assigns the corresponding response task of displaying the target electronic signage to other edge cloud nodes . For example, when responding to a display request, the management node determines the electronic signage to be displayed by each second edge cloud server in response.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
本申请实施例提供了一种请求处理装置,如图7所示,该请求处理装置70可以包括:接收模块701、确定模块702以及响应模块703,其中,The embodiment of the present application provides a request processing device. As shown in FIG. 7, the
接收模块701,用于接收客户端发送的请求显示目标电子标牌的显示请求;The receiving
确定模块702,用于根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端;The
其中,所述响应端包括所述中心云服务器和/或与所述中心云服务器具有通信连接的边缘云服务器;Wherein, the responder includes the central cloud server and/or an edge cloud server having a communication connection with the central cloud server;
响应模块703,用于基于所述响应端,响应所述显示请求。The
在本申请的一个实施例中,所述装置还包括时长确定模块,用于在所述接收客户端发送的请求显示目标电子标牌的显示请求之后,根据所述中心云服务器的空闲处理资源和/或处理速度,确定显示所述目标电子标牌的预计响应时长。In an embodiment of the present application, the device further includes a duration determination module, configured to, after receiving the display request sent by the client requesting to display the target electronic signage, according to the idle processing resources of the central cloud server and/or or processing speed to determine the expected response time for displaying the target electronic signage.
在本申请的一个实施例中,所述确定模块具体用于:In one embodiment of the present application, the determination module is specifically used for:
确定所述目标电子标牌的数量小于第一预设阈值,和/或所述预计响应时长小于第二预设阈值的情况下,确定所述中心云服务器为所述响应端;When it is determined that the number of the target electronic signs is less than a first preset threshold, and/or the expected response time is less than a second preset threshold, determine that the central cloud server is the responding end;
确定所述目标电子标牌的数量大于第一预设阈值,和/或所述预计响应时长大于第二预设阈值的情况下,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端。When it is determined that the number of the target electronic signs is greater than a first preset threshold, and/or the expected response time is greater than a second preset threshold, it is determined that the central cloud server and at least one edge cloud server are the Response end.
在本申请的一个实施例中,确定所述中心云服务器为所述响应端的情况下,In one embodiment of the present application, when it is determined that the central cloud server is the responding end,
所述响应模块具体用于:The response module is specifically used for:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
在本申请的一个实施例中,确定所述中心云服务器及至少一个所述边缘云服务器为所述响应端的情况下,In one embodiment of the present application, when it is determined that the central cloud server and at least one edge cloud server are the responding end,
所述响应模块具体用于:The response module is specifically used for:
获取所述目标电子标牌的标牌内容,并在预设显示模板中添加所述标牌内容,生成显示文件;Obtaining the signage content of the target electronic signage, and adding the signage content to a preset display template to generate a display file;
与目标边缘云服务器建立通信连接;向所述目标边缘云服务器发送所述显示文件,以通过所述目标边缘云服务器向预设网关发送显示指令以及所述显示文件,通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。Establish a communication connection with the target edge cloud server; send the display file to the target edge cloud server, so as to send a display instruction and the display file to the preset gateway through the target edge cloud server, and send the display file to the default gateway through the target edge cloud server The display file is sent to the target electronic signage, instructing the target electronic signage to display the signage content through the preset display template.
在本申请的一个实施例中,在所述边缘云服务器包括多个服务器的情况下,所述装置还包括目标确定模块,用于在所述生成显示文件之后,In one embodiment of the present application, when the edge cloud server includes multiple servers, the device further includes a target determination module, configured to, after the display file is generated,
根据每个所述边缘云服务器对应的随机超时时长,确定所述边缘云服务器中的目标边缘云服务器;Determine a target edge cloud server in the edge cloud servers according to the random timeout period corresponding to each edge cloud server;
与所述目标边缘云服务器建立通信连接。Establish a communication connection with the target edge cloud server.
本申请实施例的装置可执行本申请实施例所提供的方法,其实现原理相类似,本申请各实施例的装置中的各模块所执行的动作是与本申请各实施例的方法中的步骤相对应的,对于装置的各模块的详细功能描述具体可以参见前文中所示的对应方法中的描述,此处不再赘述。The device in the embodiment of the present application can execute the method provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by the modules in the device in the embodiments of the present application are the same as the steps in the methods of the embodiments of the present application Correspondingly, for the detailed functional description of each module of the device, reference may be made to the description in the corresponding method shown above, which will not be repeated here.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
本申请实施例提供了一种请求处理装置,如图8所示,该请求处理装置80可以包括:连接模块801、响应模块802,其中,The embodiment of the present application provides a request processing device. As shown in FIG. 8, the
连接模块801,用于响应于客户端发送的请求显示目标电子标牌的显示请求,与中心云服务器建立通信连接;The
其中,所述目标电子标牌的数量大于第一预设阈值,和/或所述中心云服务器响应所述显示请求的预计响应时长大于第二预设阈值;Wherein, the number of the target electronic signs is greater than a first preset threshold, and/or the estimated response time of the central cloud server in response to the display request is greater than a second preset threshold;
响应模块802,用于响应所述显示请求。A
在本申请的一个实施例中,所述响应模块具体用于:In one embodiment of the present application, the response module is specifically used for:
接收并存储所述中心云服务器发送的显示文件;其中,所述显示文件是基于在示模板中添加所述目标电子标牌的标牌内容生成的;receiving and storing the display file sent by the central cloud server; wherein, the display file is generated based on the sign content of the target electronic sign added to the display template;
向预设网关发送显示指令以及所述显示文件,以通过所述预设网关将所述显示文件发送至所述目标电子标牌,指示所述目标电子标牌通过所述预设显示模板显示所述标牌内容。sending a display instruction and the display file to a preset gateway, so as to send the display file to the target electronic signage through the preset gateway, instructing the target electronic signage to display the sign through the preset display template content.
在本申请的一个实施例中,还包括第二边缘云服务器,In one embodiment of the present application, it also includes a second edge cloud server,
所述装置还包括发送模块,用于在所述接收所述中心云服务器发送的显示文件之后,向所述第二边缘云服务器发送所述显示文件,以通过所述第二边缘云服务器向预设网关发送显示指令以及所述显示文件。The device further includes a sending module, configured to send the display file to the second edge cloud server after receiving the display file sent by the central cloud server, so as to send the display file to the pre-set cloud server through the second edge cloud server. It is assumed that the gateway sends the display instruction and the display file.
本申请实施例的装置可执行本申请实施例所提供的方法,其实现原理相类似,本申请各实施例的装置中的各模块所执行的动作是与本申请各实施例的方法中的步骤相对应的,对于装置的各模块的详细功能描述具体可以参见前文中所示的对应方法中的描述,此处不再赘述。The device in the embodiment of the present application can execute the method provided in the embodiment of the present application, and its implementation principle is similar. The actions performed by the modules in the device in the embodiments of the present application are the same as the steps in the methods of the embodiments of the present application Correspondingly, for the detailed functional description of each module of the device, reference may be made to the description in the corresponding method shown above, which will not be repeated here.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
本申请实施例中提供了一种电子设备,该电子设备包括:存储器和处理器;至少一个程序,存储于存储器中,用于被处理器执行时,与现有技术相比可实现:本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。An embodiment of the present application provides an electronic device, the electronic device includes: a memory and a processor; at least one program stored in the memory for execution by the processor, compared with the prior art, it can be realized: the present application In an embodiment, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request, based on The responding end responds to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server , relieve the processing pressure of the central cloud server, reduce the network bandwidth occupation, and reduce the calculation delay.
在一个可选实施例中提供了一种电子设备,如图9所示,图9所示的电子设备9000包括:处理器9001和存储器9003。其中,处理器9001和存储器9003相连,如通过总线9002相连。可选地,电子设备9000还可以包括收发器9004,收发器9004可以用于该电子设备与其他电子设备之间的数据交互,如数据的发送和/或数据的接收等。需要说明的是,实际应用中收发器9004不限于一个,该电子设备9000的结构并不构成对本申请实施例的限定。An optional embodiment provides an electronic device. As shown in FIG. 9 , the
处理器9001可以是CPU(Central Processing Unit,中央处理器),通用处理器,DSP(Digital Signal Processor,数据信号处理器),ASIC(Application SpecificIntegrated Circuit,专用集成电路),FPGA(Field Programmable Gate Array,现场可编程门阵列)或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合。其可以实现或执行结合本申请公开内容所描述的各种示例性的逻辑方框,模块和电路。处理器9001也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等。The processor 9001 can be a CPU (Central Processing Unit, central processing unit), a general-purpose processor, a DSP (Digital Signal Processor, a data signal processor), an ASIC (Application Specific Integrated Circuit, an application specific integrated circuit), an FPGA (Field Programmable Gate Array, field programmable gate array) or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute the various illustrative logical blocks, modules and circuits described in connection with the present disclosure. The processor 9001 may also be a combination that implements computing functions, for example, a combination of one or more microprocessors, a combination of DSP and a microprocessor, and the like.
总线9002可包括一通路,在上述组件之间传送信息。总线9002可以是PCI(Peripheral Component Interconnect,外设部件互连标准)总线或EISA(ExtendedIndustry Standard Architecture,扩展工业标准结构)总线等。总线9002可以分为地址总线、数据总线、控制总线等。为便于表示,图9中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。
存储器9003可以是ROM(Read Only Memory,只读存储器)或可存储静态信息和指令的其他类型的静态存储设备,RAM(Random Access Memory,随机存取存储器)或者可存储信息和指令的其他类型的动态存储设备,也可以是EEPROM(Electrically ErasableProgrammable Read Only Memory,电可擦可编程只读存储器)、CD-ROM(Compact DiscRead Only Memory,只读光盘)或其他光盘存储、光碟存储(包括压缩光碟、激光碟、光碟、数字通用光碟、蓝光光碟等)、磁盘存储介质或者其他磁存储设备、或者能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。The
存储器9003用于存储执行本申请方案的应用程序代码(计算机程序),并由处理器9001来控制执行。处理器9001用于执行存储器9003中存储的应用程序代码,以实现前述方法实施例所示的内容。The
其中,电子设备包括但不限于:移动电话、笔记本电脑、多媒体播放器、台式计算机等。Wherein, the electronic equipment includes but not limited to: mobile phone, notebook computer, multimedia player, desktop computer and so on.
本申请实施例提供了一种计算机可读存储介质,该计算机可读存储介质上存储有计算机程序,当其在计算机上运行时,使得计算机可以执行前述方法实施例中相应内容。An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when it is run on a computer, the computer can execute the corresponding content in the foregoing method embodiments.
本申请实施例中,根据所述显示请求中,所请求的所述目标电子标牌的数量和/或所述中心云服务器响应所述显示请求的预计响应时长,确定响应所述显示请求的响应端,基于所述响应端,响应所述显示请求;这样,可以根据实际场景中的电子标牌的显示需求以及中心云服务器的数据处理能力,灵活确定由中心云服务器和/或边缘云服务器响应所述显示请求,缓解了中心云服务器的处理压力以及减少网络带宽占用,并减小了计算延迟。In the embodiment of the present application, according to the display request, the number of the requested target electronic signs and/or the expected response time of the central cloud server to respond to the display request, determine the responder that responds to the display request , based on the responding end, responding to the display request; in this way, it can be flexibly determined that the central cloud server and/or the edge cloud server respond to the display request according to the display requirements of the electronic signage in the actual scene and the data processing capability of the central cloud server The display request relieves the processing pressure of the central cloud server, reduces the network bandwidth occupation, and reduces the calculation delay.
本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”、“第三”、“第四”、“1”、“2”等(如果存在)是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本申请的实施例能够以除图示或文字描述以外的顺序实施。The terms "first", "second", "third", "fourth", "1", "2", etc. (if any) in the description and claims of this application and the above drawings are used for Distinguishes between similar objects and does not necessarily describe a particular order or sequence. It is to be understood that the data so used are interchangeable under appropriate circumstances such that the embodiments of the application described herein can be practiced in sequences other than those illustrated or described in writing.
应该理解的是,虽然本申请实施例的流程图中通过箭头指示各个操作步骤,但是这些步骤的实施顺序并不受限于箭头所指示的顺序。除非本文中有明确的说明,否则在本申请实施例的一些实施场景中,各流程图中的实施步骤可以按照需求以其他的顺序执行。此外,各流程图中的部分或全部步骤基于实际的实施场景,可以包括多个子步骤或者多个阶段。这些子步骤或者阶段中的部分或全部可以在同一时刻被执行,这些子步骤或者阶段中的每个子步骤或者阶段也可以分别在不同的时刻被执行。在执行时刻不同的场景下,这些子步骤或者阶段的执行顺序可以根据需求灵活配置,本申请实施例对此不限制。It should be understood that although arrows indicate various operation steps in the flow chart of the embodiment of the present application, the execution order of these steps is not limited to the order indicated by the arrows. Unless otherwise specified herein, in some implementation scenarios of the embodiments of the present application, the implementation steps in each flowchart may be performed in other orders as required. In addition, part or all of the steps in each flow chart may include multiple sub-steps or multiple stages based on actual implementation scenarios. Some or all of these sub-steps or stages may be executed at the same time, and each of these sub-steps or stages may also be executed at different times. In scenarios where execution times are different, the execution order of these sub-steps or stages can be flexibly configured according to requirements, which is not limited in this embodiment of the present application.
以上所述仅是本申请部分实施场景的可选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本申请的方案技术构思的前提下,采用基于本申请技术思想的其他类似实施手段,同样属于本申请实施例的保护范畴。The above is only an optional implementation of some implementation scenarios of this application. It should be pointed out that for those of ordinary skill in the art, on the premise of not departing from the technical concept of the solution of this application, adopt the Other similar implementation means also belong to the protection category of the embodiment of the present application.
Claims (13)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202211485821.XA CN115866050A (en) | 2022-11-24 | 2022-11-24 | Request processing method, device, electronic device, and computer-readable storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202211485821.XA CN115866050A (en) | 2022-11-24 | 2022-11-24 | Request processing method, device, electronic device, and computer-readable storage medium |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN115866050A true CN115866050A (en) | 2023-03-28 |
Family
ID=85666077
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202211485821.XA Pending CN115866050A (en) | 2022-11-24 | 2022-11-24 | Request processing method, device, electronic device, and computer-readable storage medium |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN115866050A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN120126087A (en) * | 2025-05-14 | 2025-06-10 | 雄安国创中心科技有限公司 | End-cloud collaborative vehicle detection and tracking method, system, device and storage medium |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2020207264A1 (en) * | 2019-04-08 | 2020-10-15 | 阿里巴巴集团控股有限公司 | Network system, service provision and resource scheduling method, device, and storage medium |
| US20220007437A1 (en) * | 2020-07-06 | 2022-01-06 | Oath Inc. | Cloud hosted device instances method and apparatus |
| CN114338680A (en) * | 2020-09-25 | 2022-04-12 | 英特尔公司 | Method and apparatus for managing quality of service relative to service level agreements in computing devices |
| CN115378938A (en) * | 2022-08-12 | 2022-11-22 | 北京睿芯高通量科技有限公司 | Network resource scheduling method, gateway equipment, edge and cloud data center server |
-
2022
- 2022-11-24 CN CN202211485821.XA patent/CN115866050A/en active Pending
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2020207264A1 (en) * | 2019-04-08 | 2020-10-15 | 阿里巴巴集团控股有限公司 | Network system, service provision and resource scheduling method, device, and storage medium |
| US20220007437A1 (en) * | 2020-07-06 | 2022-01-06 | Oath Inc. | Cloud hosted device instances method and apparatus |
| CN114338680A (en) * | 2020-09-25 | 2022-04-12 | 英特尔公司 | Method and apparatus for managing quality of service relative to service level agreements in computing devices |
| CN115378938A (en) * | 2022-08-12 | 2022-11-22 | 北京睿芯高通量科技有限公司 | Network resource scheduling method, gateway equipment, edge and cloud data center server |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN120126087A (en) * | 2025-05-14 | 2025-06-10 | 雄安国创中心科技有限公司 | End-cloud collaborative vehicle detection and tracking method, system, device and storage medium |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US20240338303A1 (en) | Agentless distributed monitoring of microservices through a virtual switch | |
| US10949158B2 (en) | Screenshot method and apparatus | |
| CN105915633B (en) | Automatic operation and maintenance system and method | |
| CN112449750A (en) | Log data collection method, log data collection device, storage medium, and log data collection system | |
| CN108449418A (en) | A hybrid cloud platform management system and method | |
| CN106100880A (en) | A cloud data resource deployment and visual management method | |
| Shafabakhsh et al. | Evaluating the Impact of Inter Process Communication in Microservice Architectures. | |
| CN109697055B (en) | Method and system for generating mobile App page | |
| CN105183299A (en) | Human-computer interface service processing system and method | |
| CN102710793A (en) | Network printing system based on cloud computing and data storage method thereof | |
| CN104410699A (en) | Resource management method and system of open type cloud computing | |
| CN112817562B (en) | Service processing method and device | |
| CN113703973A (en) | Cloud task processing method, system, device, equipment and storage medium | |
| CN113495498B (en) | Simulation method, simulator, device and medium for hardware device | |
| US12363182B2 (en) | Systems and methods for collaborative editing an electronic resource using client device designations | |
| CN112486676B (en) | Data sharing and distributing device based on edge calculation | |
| CN115866050A (en) | Request processing method, device, electronic device, and computer-readable storage medium | |
| US10904025B2 (en) | Web meeting bookmarking system based on level of relevancy and importance | |
| CN112070452A (en) | Distributed workflow management system | |
| US20150095087A1 (en) | Calendar Integration In A Collaborative Environment | |
| CN110276593A (en) | Object recommendation method, device, server and storage medium | |
| CN109039670A (en) | The sharing method and device of team's configuration method, team's allocation plan | |
| CN104539658B (en) | One kind is based on enterprise's private clound big data processing method | |
| CN115086425B (en) | Message transmission method, device, program product, medium and electronic equipment | |
| CN116795492A (en) | Resource scheduling methods, devices, equipment and readable storage media of cloud platforms |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination |