WO2025124233A1 - 一种定时触发器类型的边缘函数实现方法 - Google Patents
一种定时触发器类型的边缘函数实现方法 Download PDFInfo
- Publication number
- WO2025124233A1 WO2025124233A1 PCT/CN2024/136522 CN2024136522W WO2025124233A1 WO 2025124233 A1 WO2025124233 A1 WO 2025124233A1 CN 2024136522 W CN2024136522 W CN 2024136522W WO 2025124233 A1 WO2025124233 A1 WO 2025124233A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- edge
- function
- trigger
- edge function
- script
- 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
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/28—Timers or timing mechanisms used in protocols
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
- G06F9/485—Task life-cycle, e.g. stopping, restarting, resuming execution
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/02—Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
Definitions
- the present application relates to the field of edge function calculation technology, and in particular to a method for realizing an edge function of a timing trigger type.
- edge function computing is a promising artificial intelligence technology that supports the application of edge computing technology to edge devices.
- This technology can provide various forms of business services such as authentication, encryption and decryption, data storage, and data cleaning.
- the purpose of this application is to provide an edge function that provides a consistent trigger frequency based on the particularity of the business scenario, so that the function on the edge device or edge node can be automatically triggered and executed according to a predetermined schedule.
- Edge function implementation method of the timed trigger type is to provide an edge function that provides a consistent trigger frequency based on the particularity of the business scenario, so that the function on the edge device or edge node can be automatically triggered and executed according to a predetermined schedule.
- A2 Send the product file to the global resource pool
- C2 Configure a special header to store the address of the wasm file generated after the function is compiled
- C3 Configure a special header for authentication to prevent external malicious attacks from imitating the function trigger
- the load balancing configuration in C4 is specifically to randomly obtain an IP corresponding to a special domain name for responding to script access, and perform load balancing through a random method.
- the collection and monitoring of logs requires the configuration of a special header to store the function id, and the subsequent function logs are bound to the id.
- the response, flow and other information of the function are bound to the user id and the script id, and reported to the monitoring system for data collection.
- the edge function in S1 is used to periodically trigger edge functions to check sensor status, execute device control operations or perform device status monitoring, and is used to periodically trigger edge functions to read data from sensors, and then perform real-time analysis and processing to promptly detect abnormal situations or optimize system performance. It is also used to periodically trigger edge functions to monitor device load conditions, and dynamically adjust task allocation and resource allocation according to load conditions to achieve optimal resource utilization.
- a trigger is a mechanism used to trigger an operation or event at a specific time point or time interval.
- An edge function of the timer trigger type refers to a function that is executed at the edge in an edge computing environment by a timer trigger. The following is an explanation of the relevant terms:
- C2 Configure a special header to store the address of the wasm file generated after the function is compiled
- C3 Configure a special header for authentication to prevent external malicious attacks from imitating the function trigger
- C4 Configure load balancing, randomly obtain the IP address corresponding to a special domain name to respond to script access, and perform load balancing through random methods;
- the function log After the function log is bound to the id, the function's response, traffic and other information are bound to the user id and script id, and reported to the monitoring system for data collection.
- Edge functions are used to regularly back up and synchronize data to edge devices or cloud storage, extract data from data sources and generate reports, and then send the reports to relevant users or systems.
- Edge functions are used to distribute computing tasks to edge devices or edge nodes for execution to reduce data transmission and latency.
- Edge functions are used to regularly trigger edge functions to check sensor status, perform device control operations, or perform device status monitoring.
- Edge functions are used to regularly trigger edge functions to read data from sensors and then perform real-time analysis and processing to promptly detect abnormal situations or optimize system performance.
- Edge functions are also used to periodically trigger edge functions to monitor device load conditions, dynamically adjust task allocation and resource allocation according to load conditions, and achieve optimal resource utilization.
- a trigger is a mechanism used to trigger an operation or event at a specific point in time or time interval.
- edge function computing is a promising artificial intelligence technology that supports the application of edge computing technology to edge devices. This technology can provide authentication, encryption and decryption, data storage, data cleaning and other business services.
- edge function computing triggered by http can no longer meet the data processing needs of some IoT devices.
- the demand for edge function computing triggered by different scenarios and at different frequencies is also increasing.
- the timed trigger type of edge function technology has emerged. In the edge computing environment, the timed trigger can trigger an operation or event at a predetermined time interval or a specific time point, such as data collection, processing, analysis or sending at a specific time point;
- the purpose of this application is to provide an edge function that can be triggered on a timer basis, and the trigger frequency of the timer can be modified in the center and take effect within a certain period of time. It is used to provide edge computing for various scenarios, and can provide edge functions with matching trigger frequencies according to the particularity of business scenarios, so that functions on edge devices or edge nodes can be automatically triggered and executed according to a predetermined schedule.
- This technology can be used in various edge computing application scenarios, such as data processing, real-time monitoring and analysis, edge artificial intelligence, etc. of IoT devices. Through timed triggers, edge computing can respond and process data more intelligently, providing more efficient computing power and faster response time.
- Trigger-type edge functions rely on CDN. Customers set the corresponding scripts and trigger frequencies, deploy and send the scripts to the edge environment, and the task center obtains the scripts that need to be executed on a scheduled basis within 10 minutes and generates scheduled tasks with the same frequency. Scheduled tasks trigger the script content in a specific way to meet customer needs. Trigger-type edge functions consist of the following five points:
- the edge function can be triggered regularly to monitor the equipment load, and the allocation of tasks and resources can be dynamically adjusted according to the load to achieve optimal utilization of resources;
- Timing triggering of scripts without domain names reduces the complexity of domain name configuration and the workload of deployment
- Scheduled triggers allow edge functions to be triggered at specific time intervals or specific points in time. This allows precise control of the execution time of functions, ensuring that tasks are executed within the scheduled time. This is very useful for scenarios where tasks need to be executed on schedule, such as scheduled data collection, scheduled report generation, etc.
- Timing triggers can avoid continuous consumption of computing resources.
- the computing resources of edge devices are usually limited. By timing the edge function, the function can be started when the task needs to be executed, and the resources can be released after the task is completed. This method can effectively save computing resources and improve the resource utilization of edge devices;
- Timing triggers can be used to periodically collect, process, and synchronize data.
- edge functions can be periodically triggered to collect sensor data and perform real-time processing and analysis, which helps ensure the timeliness and consistency of data so that subsequent decisions and operations can be based on the latest data;
- Scheduled task scheduling Scheduled triggers can be used to schedule edge functions to perform different tasks. Different tasks can be scheduled to execute at appropriate times through predetermined time intervals or time points, which helps optimize the execution order and timing of tasks to maximize the efficiency and performance of the overall system.
- Timing triggers enable the execution of edge functions to be automated without manual intervention.
- Edge functions can be automatically triggered and executed according to a predetermined schedule, which reduces the need for manual operation, improves the system's automation level, and reduces the risk of human error.
- Trigger without domain name The created scheduled edge function can be automatically triggered according to the predetermined schedule even without configuring a domain name, which simplifies the steps of domain name registration and DNS resolution, reduces the complexity of domain name configuration and the workload of deployment. For end users or other systems, they do not need to care about how the edge function is triggered, but only need to use the provided interfaces and services. This can improve the security and maintainability of the system, and simplify the integration of external systems and the adjustment of internal architecture.
- timing trigger type edge function makes task scheduling and data processing in the edge computing environment more efficient and reliable.
- any “device plus function” clause is intended to cover the structure described herein that performs the function, and is not only structurally equivalent but also equivalent structure.
- substitutions, modifications, changes and omissions may be made in the design, operation and arrangement of the exemplary embodiments. Therefore, the present application is not limited to a specific embodiment, but extends to a variety of modifications that still fall within the scope of the appended claims.
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computer Security & Cryptography (AREA)
- Debugging And Monitoring (AREA)
Abstract
本申请涉及一种定时触发器类型的边缘函数实现方法,其涉及边缘函数计算技术领域,旨在解决传统的由http触发边缘函数的方法已经不能满足一些物联网设备对于数据处理需求的问题,其技术方案要点是S1:设置边缘函数,将触发器类型的边缘函数依托于CDN,设定好对应的脚本以及触发频率,并将该脚本部署下发到边缘环境;S2:定时任务的触发及更新;S3:脚本未绑定域名的情况下,实现定时触发器类型函数的响应;S4:运行时对定时任务的响应,以及访问鉴权;S5:数据采集,在无域名的状态下对日志进行收集和监控,实现数据采集。达到了使得边缘计算环境中的任务调度和数据处理更加高效和可靠的效果。
Description
相关申请
本申请要求2023年12月13日申请的,申请号为2023117126843,名称为“一种定时触发器类型的边缘函数实现方法”的中国专利申请的优先权,在此将其全文引入作为参考。
本申请涉及边缘函数计算技术领域,尤其是涉及一种定时触发器类型的边缘函数实现方法。
由于移动计算和物联网的进步,数十亿的移动和物联网设备与因特网相连,在网络的边缘产生上亿个数据字节,受人工智能和物联网的驱动,将人工智能前沿推向网络边缘,充分发挥边缘大数据的潜力是当务之急。
要达到这一趋势,边缘函数计算是一种很有前景的支持边缘计算技术应用于边缘设备的人工智能技术,该技术可以提供鉴权、加解密、数据存储、数据清洗等多种形式的业务服务方式。
上述中的传统技术方案存在以下缺陷:传统的由http触发边缘函数的方法已经不能满足一些物联网设备对于数据的处理需求,针对不同场景、以不同频率触发的边缘函数计算的需求也越来越大,现在没有技术能够增加边缘函数计算效率,导致物联网设备对于数据的处理速度较差。
本申请的目的是提供一种针对业务场景的特殊性提供相洽触发频率的边缘函数,使得在边缘设备或边缘节点上的函数可以按照预定的时间表自动触发执行的定时触发器类型的边缘函数实现方法。
为实现上述目的,本申请提供了如下技术方案:
一种定时触发器类型的边缘函数实现方法,其方法如下:
S1:设置边缘函数,将触发器类型的边缘函数依托于CDN,设定好对应的脚本以及触发频率,并将该脚本部署下发到边缘环境;
创建定时任务脚本,部署下发具体为:
A1:编译脚本生成对应的制品文件;
A2:将制品文件下发到全局资源池中;
S2:定时任务的触发及更新,任务中心在十分钟内获取相关下发成功的需要定时执行的脚本,生成同频率的定时任务,定时任务通过特定的方式来触发脚本内容,实现客户的需求;
S3:脚本未绑定域名的情况下,实现定时触发器类型函数的响应;
S4:运行时对定时任务的响应,以及访问鉴权;
S5:数据采集,在无域名的状态下对日志进行收集和监控,实现数据采集。
进一步地,所述S2中定时任务的触发及更新具体为:
B1:每隔十分钟取出满足条件的任务脚本放入cronMap中;
B2:遍历cronMap,将每个定时任务开启;
B3:十分钟后取出新的数据和旧数据对比,将新增的内容打上标记加入定时任务,把需要删除的内容也打上标记后停止该定时任务。
进一步地,所述B3中准确识别变更的定时任务并在打完标记后更新定时任务。
进一步地,所述S3的具体步骤如下:
C1:设置特殊的域名专门用于处理定时触发器类型的函数;
C2:配置特殊头存放函数编译后生成的wasm文件地址;
C3:配置特殊头用于鉴权,防止外部模仿该函数触发进行恶意攻击;
C4:配置负载均衡。
进一步地,所述C4中配置负载均衡具体为随机获取一个特殊域名对应的ip用来做脚本访问的响应,并通过随机的方法做负载均衡。
进一步地,所述S4的具体步骤为:
D1:访问域名为特殊域名时,查看是否带有token;
D2:根据特殊头存放的wasm文件地址访问对应的制品;
D3:返回制品文件对应脚本的响应内容。
进一步地,所述S5中对日志进行收集和监控需先配置特殊头存放函数id,后续函数日志与id绑定。
进一步地,所述S5中函数日志与id绑定后,该函数的响应、流量等信息与用户id和脚本id绑定,上报到监控系统,进行数据的采集。
进一步地,所述S1中边缘函数用于定期备份和同步数据到边缘设备或云端存储,并从数据源中提取数据并生成报告,然后将报告发送给相关的用户或系统,且边缘函数用于将计算任务分发到边缘设备或边缘节点上执行,以减少数据传输和延迟。
进一步地,所述S1中边缘函数用于定期触发边缘函数来检查传感器状态、执行设备控制操作或进行设备状态监测,且用于定期触发边缘函数,从传感器中读取数据,然后进行实时分析和处理,以便及时发现异常情况或优化系统性能,同时用于定时触发边缘函数来监测设备负载情况,根据负载情况动态调整任务的分配和资源的分配,以实现资源的最优化利用,且触发器是一种机制,用于在特定的时间点或时间间隔触发某个操作或事件。
综上所述,本申请的有益技术效果为:
1、本申请监控定时任务的变化,及时更新定时任务,这包括定时任务的新增、删除、定时频率的变更、任务内容的变更等,且可以在无域名情况下对脚本进行定时触发,减少了域名配置的复杂性和部署的工作量,实施定时触发器类型的边缘函数时,避免未经授权的访问和操作,采用token校验的机制等安全措施来保护边缘函数的安全性,同时执行定时任务时带上脚本id、用户id等信息,获取日志和指标上报监控中心,帮助诊断问题、优化性能,并提供对边缘函数执行情况的可视化报告;
2、本申请定时触发器可以避免持续性的计算资源消耗。边缘设备的计算资源通常是有限的,通过定时触发边缘函数,可以在需要执行任务时启动函数,而在任务执行完毕后释放资源,这种方式可以有效节省计算资源,并提高边缘设备的资源利用率,且定时触发器可用于定期采集、处理和同步数据。例如,在物联网场景中,可以定期触发边缘函数来采集传感器数据并进行实时处理和分析,这有助于确保数据的及时性和一致性,以便后续的决策和操作可以基于最新的数据,定时触发器类型的边缘函数的这些优点,使得边缘计算环境中的任务调度和数据处理更加高效和可靠;
3、本申请定时触发器可以用于调度边缘函数执行不同的任务。通过预定的时间间隔或时间点,可以安排不同的任务在适当的时间执行,这有助于优化任务的执行顺序和时间安排,以最大程度地提高整体系统的效率和性能,定时触发器使得边缘函数的执行可以自动化,无需手动干预,边缘函数可以按照预定的时间表自动触发执行,这减少了人工操作的需求,提高了系统的自动化程度,减少了人为错误的风险,创建的定时边缘函数在没有配置域名的情况下,也可按照预定的时间表自动触发,简化了域名注册,DNS解析等步骤,减少了域名配置的复杂性和部署的工作量,对于终端用户或其他系统来说,他们不需要关心边缘函数是如何被触发的,只需要使用提供的接口和服务即可,这样可以提高系统的安全性和可维护性,同时简化了对外部系统的集成和对内部架构的调整。
为了更清楚地说明本申请实施例或传统技术中的技术方案,下面将对实施例或传统技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据公开的附图获得其他的附图。
图1为本申请整体流程结构示意图。
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
以下结合附图对本申请方法作进一步详细说明。
实施例一
参照图1,一种定时触发器类型的边缘函数实现方法,其方法如下:
S1:设置边缘函数,将触发器类型的边缘函数依托于CDN,设定好对应的脚本以及触发频率,并将该脚本部署下发到边缘环境;
创建定时任务脚本,部署下发具体为:
A1:编译脚本生成对应的制品文件;
A2:将制品文件下发到全局资源池中;
定时触发器类型的边缘函数是指在边缘计算环境中,通过定时触发器来触发在边缘执行的一种函数,以下是对相关术语的解释:
定时触发器:定时触发器是一种机制,用于在特定的时间点或时间间隔触发某个操作或事件,在边缘计算中,定时触发器可以用来定期执行边缘函数,例如每隔一段时间或在特定的时间点触发函数执行;
边缘函数:边缘函数是一种计算模型,它将计算任务分发到边缘设备或边缘节点上执行,以减少数据传输和延迟,边缘函数通常是轻量级的、短时运行的任务,可以根据需要快速启动和停止;
S2:定时任务的触发及更新,任务中心在十分钟内获取相关下发成功的需要定时执行的脚本,生成同频率的定时任务,定时任务通过特定的方式来触发脚本内容,实现客户的需求;
B1:每隔十分钟取出满足条件的任务脚本放入cronMap中;
B2:遍历cronMap,将每个定时任务开启;
B3:十分钟后取出新的数据和旧数据对比,将新增的内容打上标记加入定时任务,把需要删除的内容也打上标记后停止该定时任务,定时任务停止成功后删除cronMap中的该内容;
S3:脚本未绑定域名的情况下,实现定时触发器类型函数的响应;
C1:设置特殊的域名专门用于处理定时触发器类型的函数;
C2:配置特殊头存放函数编译后生成的wasm文件地址;
C3:配置特殊头用于鉴权,防止外部模仿该函数触发进行恶意攻击;
C4:配置负载均衡,随机获取一个特殊域名对应的ip用来做脚本访问的响应,并通过随机的方法做负载均衡;
S4:运行时对定时任务的响应,以及访问鉴权;
D1:访问域名为特殊域名时,查看是否带有token;
D2:根据特殊头存放的wasm文件地址访问对应的制品;
D3:返回制品文件对应脚本的响应内容;
S5:数据采集,在无域名的状态下对日志进行收集和监控,实现数据采集;
配置特殊头存放函数id,后续函数日志与id绑定;
函数日志与id绑定后,该函数的响应、流量等信息与用户id和脚本id绑定,上报到监控系统,进行数据的采集。
边缘函数用于定期备份和同步数据到边缘设备或云端存储,并从数据源中提取数据并生成报告,然后将报告发送给相关的用户或系统,且边缘函数用于将计算任务分发到边缘设备或边缘节点上执行,以减少数据传输和延迟,边缘函数用于定期触发边缘函数来检查传感器状态、执行设备控制操作或进行设备状态监测,且用于定期触发边缘函数,从传感器中读取数据,然后进行实时分析和处理,以便及时发现异常情况或优化系统性能,同时用于定时触发边缘函数来监测设备负载情况,根据负载情况动态调整任务的分配和资源的分配,以实现资源的最优化利用,且触发器是一种机制,用于在特定的时间点或时间间隔触发某个操作或事件。
实施例二
由于移动计算和物联网的进步,数十亿的移动和物联网设备与因特网相连,在网络的边缘产生上亿个数据字节。受人工智能和物联网的驱动,将人工智能前沿推向网络边缘,充分发挥边缘大数据的潜力是当务之急,要达到这一趋势,边缘函数计算是一种很有前景的支持边缘计算技术应用于边缘设备的人工智能技术,该技术可以提供鉴权、加解密、数据存储、数据清洗等多种形式的业务服务方式,但是传统的由http触发边缘函数的方法已经不能满足一些物联网设备对于数据的处理需求,针对不同场景、以不同频率触发的边缘函数计算的需求也越来越大,应运而生的就是定时触发器类型的边缘函数技术,在边缘计算环境中,定时触发器可以在预定的时间间隔或特定时间点触发某个操作或事件,例如在特定时间点进行数据采集、处理、分析或发送;
本申请的目的在于提供一种能够定时触发,且可以在中心修改定时器的触发频率,并在一定时长内生效的边缘函数,用于为各类场景提供边缘计算的同时,能够针对业务场景的特殊性提供相洽触发频率的边缘函数,使得在边缘设备或边缘节点上的函数可以按照预定的时间表自动触发执行,这种技术可以用于各种边缘计算应用场景,如物联网设备的数据处理、实时监控和分析、边缘人工智能等,通过定时触发器,边缘计算可以更加智能地响应和处理数据,提供更高效的计算能力和更快速的响应时间;
总体架构:触发器类型的边缘函数依托于CDN,客户设定好对应的脚本以及触发频率,将该脚本部署下发到边缘环境,任务中心在10分钟内获取相关下发成功的需要定时执行的脚本,生成同频率的定时任务,定时任务通过特定的方式来触发脚本内容,实现客户的需求。触发器类型的边缘函数由以下五点构成:
1、创建定时任务脚本,部署下发
a)编译脚本生成对应的制品文件;
b)将制品文件下发到全局资源池中;
2、定时任务的触发及更新;
a)每隔十分钟(可修改)取出满足条件的任务脚本放入cronMap中(防止带定时触发器的函数变化,十分钟刷新一次定时任务);
b)遍历cronMap,将每个定时任务开启(首次);
c)十分钟后取出新的数据和旧数据对比,将新增的内容打上标记加入定时任务,把需要删除的内容也打上标记后停止该定时任务,定时任务停止成功后删除cronMap中的该内容;
3、函数脚本未绑定域名的情况下,实现定时触发器类型函数的响应
a)设置特殊的域名专门用于处理定时触发器类型的函数;
b)配置特殊头存放函数编译后生成的wasm文件地址;
c)配置特殊头用于鉴权,防止外部模仿该函数触发进行恶意攻击;
d)随机获取一个特殊域名对应的ip用来做脚本访问的响应,通过随机的方法做负载均衡;
4、运行时对定时任务的响应
a)访问域名为特殊域名时,查看是否带有token;
b)根据特殊头存放的wasm文件地址访问对应的制品;
c)返回制品文件对应脚本的响应内容;
5、无域名情况下日志的收集及监控
a)配置特殊头存放函数id,后续函数日志与id绑定;
b)该函数的响应、流量等信息与用户id和脚本id绑定,上报到监控系统,进行数据的采集;
通过本申请提供的方法,借助CDN和传统边缘函数的部署下发方法,实现固定频率的函数响应,帮助客户实现自定义的函数需求和触发频率。
在函数计算领域应用如下:
1、定期备份和同步数据到边缘设备或云端存储;
2、从数据源中提取数据并生成报告,然后将报告发送给相关的用户或系统;
3、定期触发边缘函数来检查传感器状态、执行设备控制操作或进行设备状态监测;
4、定期触发边缘函数,从传感器中读取数据,然后进行实时分析和处理,以便及时发现异常情况或优化系统性能;
5、可以定时触发边缘函数来监测设备负载情况,根据负载情况动态调整任务的分配和资源的分配,以实现资源的最优化利用;
本设计的的应用
1、监控定时任务的变化,及时更新定时任务,这包括定时任务的新增、删除、定时频率的变更、任务内容的变更等;
2、无域名情况下对脚本的定时触发,减少了域名配置的复杂性和部署的工作量;
3、实施定时触发器类型的边缘函数时的安全性,避免未经授权的访问和操作,采用token校验的机制等安全措施来保护边缘函数的安全性;
4、执行定时任务时带上脚本id、用户id等信息,获取日志和指标上报监控中心,帮助诊断问题、优化性能,并提供对边缘函数执行情况的可视化和报告;
本申请相对传统方法而言,所具有的优点和效果:
精确控制:定时触发器允许在特定的时间间隔或特定时间点触发边缘函数的执行。这使得可以精确控制函数的执行时间,确保任务在预定的时间内得以执行。这对于需要按计划执行任务的场景非常有用,例如定时数据采集、定时报告生成等;
节省资源:定时触发器可以避免持续性的计算资源消耗。边缘设备的计算资源通常是有限的,通过定时触发边缘函数,可以在需要执行任务时启动函数,而在任务执行完毕后释放资源。这种方式可以有效节省计算资源,并提高边缘设备的资源利用率;
数据同步:定时触发器可用于定期采集、处理和同步数据。例如,在物联网场景中,可以定期触发边缘函数来采集传感器数据并进行实时处理和分析,这有助于确保数据的及时性和一致性,以便后续的决策和操作可以基于最新的数据;
定时任务调度:定时触发器可以用于调度边缘函数执行不同的任务,通过预定的时间间隔或时间点,可以安排不同的任务在适当的时间执行,这有助于优化任务的执行顺序和时间安排,以最大程度地提高整体系统的效率和性能;
自动化操作:定时触发器使得边缘函数的执行可以自动化,无需手动干预,边缘函数可以按照预定的时间表自动触发执行,这减少了人工操作的需求,提高了系统的自动化程度,减少了人为错误的风险;
无域名触发:创建的定时边缘函数在没有配置域名的情况下,也可按照预定的时间表自动触发,简化了域名注册,DNS解析等步骤,减少了域名配置的复杂性和部署的工作量,对于终端用户或其他系统来说,他们不需要关心边缘函数是如何被触发的,只需要使用提供的接口和服务即可,这样可以提高系统的安全性和可维护性,同时简化了对外部系统的集成和对内部架构的调整;
综上所述,定时触发器类型的边缘函数的这些优点,使得边缘计算环境中的任务调度和数据处理更加高效和可靠。
重要的是,应注意,在多个不同示例性实施方案中示出的本申请的构造和布置仅是例示性的。尽管在此公开内容中仅详细描述了几个实施方案,但参阅此公开内容的人员应容易理解,在实质上不偏离该申请中所描述的主题的新颖教导和优点的前提下,许多改型是可能的(例如,各种元件的尺寸、尺度、结构、形状和比例、以及参数值(例如,温度、压力等)、安装布置、材料的使用、颜色、定向的变化等),例如,示出为整体成形的元件可以由多个部分或元件构成,元件的位置可被倒置或以其它方式改变,并且分立元件的性质或数目或位置可被更改或改变,因此,所有这样的改型旨在被包含在本申请的范围内。可以根据替代的实施方案改变或重新排序任何过程或方法步骤的次序或顺序。在权利要求中,任何“装置加功能”的条款都旨在覆盖在本文中所描述的执行所述功能的结构,且不仅是结构等同而且还是等同结构。在不背离本申请的范围的前提下,可以在示例性实施方案的设计、运行状况和布置中做出其他替换、改型、改变和省略。因此,本申请不限制于特定的实施方案,而是扩展至仍落在所附的权利要求书的范围内的多种改型。
此外,为了提供示例性实施方案的简练描述,可以不描述实际实施方案的所有特征(即,与当前考虑的执行本申请的最佳模式不相关的那些特征,或与实现本申请不相关的那些特征)。
应理解的是,在任何实际实施方式的开发过程中,如在任何工程或设计项目中,可做出大量的具体实施方式决定。这样的开发努力可能是复杂的且耗时的,但对于那些得益于此公开内容的普通技术人员来说,不需要过多实验,所述开发努力将是一个设计、制造和生产的常规工作。
以上所述实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。
Claims (10)
- 一种定时触发器类型的边缘函数实现方法,其特征在于:其方法如下:S1:设置边缘函数,将触发器类型的边缘函数依托于CDN,设定好对应的脚本以及触发频率,并将该脚本部署下发到边缘环境;创建定时任务脚本,部署下发具体为:A1:编译脚本生成对应的制品文件;A2:将制品文件下发到全局资源池中;S2:定时任务的触发及更新,任务中心在十分钟内获取相关下发成功的需要定时执行的脚本,生成同频率的定时任务,定时任务通过特定的方式来触发脚本内容,实现客户的需求;S3:脚本未绑定域名的情况下,实现定时触发器类型函数的响应;S4:运行时对定时任务的响应,以及访问鉴权;S5:数据采集,在无域名的状态下对日志进行收集和监控,实现数据采集。
- 根据权利要求1所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S2中定时任务的触发及更新具体为:B1:每隔十分钟取出满足条件的任务脚本放入cronMap中;B2:遍历cronMap,将每个定时任务开启;B3:十分钟后取出新的数据和旧数据对比,将新增的内容打上标记加入定时任务,把需要删除的内容也打上标记后停止该定时任务。
- 根据权利要求2所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述B3中准确识别变更的定时任务并在打完标记后更新定时任务。
- 根据权利要求3所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S3的具体步骤如下:C1:设置特殊的域名专门用于处理定时触发器类型的函数;C2:配置特殊头存放函数编译后生成的wasm文件地址;C3:配置特殊头用于鉴权,防止外部模仿该函数触发进行恶意攻击;C4:配置负载均衡。
- 根据权利要求4所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述C4中配置负载均衡具体为随机获取一个特殊域名对应的ip用来做脚本访问的响应,并通过随机的方法做负载均衡。
- 根据权利要求5所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S4的具体步骤为:D1:访问域名为特殊域名时,查看是否带有token;D2:根据特殊头存放的wasm文件地址访问对应的制品;D3:返回制品文件对应脚本的响应内容。
- 根据权利要求6所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S5中对日志进行收集和监控需先配置特殊头存放函数id,后续函数日志与id绑定。
- 根据权利要求7所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S5中函数日志与id绑定后,该函数的响应、流量等信息与用户id和脚本id绑定,上报到监控系统,进行数据的采集。
- 根据权利要求8所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S1中边缘函数用于定期备份和同步数据到边缘设备或云端存储,并从数据源中提取数据并生成报告,然后将报告发送给相关的用户或系统,且边缘函数用于将计算任务分发到边缘设备或边缘节点上执行,以减少数据传输和延迟。
- 根据权利要求9所述的一种定时触发器类型的边缘函数实现方法,其特征在于:所述S1中边缘函数用于定期触发边缘函数来检查传感器状态、执行设备控制操作或进行设备状态监测,且用于定期触发边缘函数,从传感器中读取数据,然后进行实时分析和处理,以便及时发现异常情况或优化系统性能,同时用于定时触发边缘函数来监测设备负载情况,根据负载情况动态调整任务的分配和资源的分配,以实现资源的最优化利用,且触发器是一种机制,用于在特定的时间点或时间间隔触发某个操作或事件。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202311712684.3A CN117873660B (zh) | 2023-12-13 | 2023-12-13 | 一种定时触发器类型的边缘函数实现方法 |
| CN202311712684.3 | 2023-12-13 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2025124233A1 true WO2025124233A1 (zh) | 2025-06-19 |
Family
ID=90593680
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2024/136522 Pending WO2025124233A1 (zh) | 2023-12-13 | 2024-12-03 | 一种定时触发器类型的边缘函数实现方法 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN117873660B (zh) |
| WO (1) | WO2025124233A1 (zh) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN117873660B (zh) * | 2023-12-13 | 2025-09-05 | 天翼云科技有限公司 | 一种定时触发器类型的边缘函数实现方法 |
| CN119829159B (zh) * | 2024-11-30 | 2026-01-13 | 天翼云科技有限公司 | 边缘函数触发方法、装置、电子设备及存储介质 |
Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN110543282A (zh) * | 2019-07-24 | 2019-12-06 | 南京智能制造研究院有限公司 | 一种应用于边缘计算网关的触发快照存储方法及系统 |
| US11089136B1 (en) * | 2020-09-30 | 2021-08-10 | Amazon Technologies, Inc. | Low latency datastore access for event-triggered functions at the edge |
| CN114077485A (zh) * | 2021-11-09 | 2022-02-22 | 深圳供电局有限公司 | 一种物联网边缘计算节点资源的业务调度部署方法 |
| CN114116157A (zh) * | 2021-10-21 | 2022-03-01 | 山东如意毛纺服装集团股份有限公司 | 一种边缘环境下多边缘集群云结构及负载均衡调度方法 |
| CN114691299A (zh) * | 2022-03-22 | 2022-07-01 | 浪潮云信息技术股份公司 | 一种基于Serverless的边缘计算资源管理系统 |
| CN117873660A (zh) * | 2023-12-13 | 2024-04-12 | 天翼云科技有限公司 | 一种定时触发器类型的边缘函数实现方法 |
Family Cites Families (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111901573A (zh) * | 2020-08-17 | 2020-11-06 | 泽达易盛(天津)科技股份有限公司 | 一种基于边缘计算的细颗粒度实时监管系统 |
| CN114501374B (zh) * | 2021-12-13 | 2025-07-01 | 天翼物联科技有限公司 | 车联网的动态服务部署方法、系统、装置及存储介质 |
| CN114500067A (zh) * | 2022-02-09 | 2022-05-13 | 厦门元屿安科技有限公司 | 基于cdn边缘计算网络的异步打击防盗链方法及系统 |
| CN117216152A (zh) * | 2023-01-10 | 2023-12-12 | 深圳市腾讯信息技术有限公司 | 区块链网络的数据处理方法、装置、设备、介质及产品 |
| CN117112075B (zh) * | 2023-06-19 | 2024-02-20 | 领悦数字信息技术有限公司 | 将定时任务应用自动转换成无服务器函数的方法和系统 |
-
2023
- 2023-12-13 CN CN202311712684.3A patent/CN117873660B/zh active Active
-
2024
- 2024-12-03 WO PCT/CN2024/136522 patent/WO2025124233A1/zh active Pending
Patent Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN110543282A (zh) * | 2019-07-24 | 2019-12-06 | 南京智能制造研究院有限公司 | 一种应用于边缘计算网关的触发快照存储方法及系统 |
| US11089136B1 (en) * | 2020-09-30 | 2021-08-10 | Amazon Technologies, Inc. | Low latency datastore access for event-triggered functions at the edge |
| CN114116157A (zh) * | 2021-10-21 | 2022-03-01 | 山东如意毛纺服装集团股份有限公司 | 一种边缘环境下多边缘集群云结构及负载均衡调度方法 |
| CN114077485A (zh) * | 2021-11-09 | 2022-02-22 | 深圳供电局有限公司 | 一种物联网边缘计算节点资源的业务调度部署方法 |
| CN114691299A (zh) * | 2022-03-22 | 2022-07-01 | 浪潮云信息技术股份公司 | 一种基于Serverless的边缘计算资源管理系统 |
| CN117873660A (zh) * | 2023-12-13 | 2024-04-12 | 天翼云科技有限公司 | 一种定时触发器类型的边缘函数实现方法 |
Non-Patent Citations (1)
| Title |
|---|
| YU, KAI: "Research on Edge Function Calculation Technology and Application", TIANYI CLOUD DEVELOPER COMMUNITY, 7 June 2023 (2023-06-07), XP009564461, Retrieved from the Internet <URL:https://www.ctyun.cn/developer/article/423118398603333> * |
Also Published As
| Publication number | Publication date |
|---|---|
| CN117873660B (zh) | 2025-09-05 |
| CN117873660A (zh) | 2024-04-12 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| Cardellini et al. | Optimal operator deployment and replication for elastic distributed data stream processing | |
| Cardellini et al. | Optimal operator replication and placement for distributed stream processing systems | |
| Battula et al. | An efficient resource monitoring service for fog computing environments | |
| Ward et al. | Observing the clouds: a survey and taxonomy of cloud monitoring | |
| Smit et al. | Distributed, application-level monitoring for heterogeneous clouds using stream processing | |
| CN117873660A (zh) | 一种定时触发器类型的边缘函数实现方法 | |
| US12009997B2 (en) | Cell-based architecture for an extensibility platform | |
| CN116089027B (zh) | 一种基于jvm的非阻塞分布式计划任务调度方法 | |
| Clemm et al. | DNA: An SDN framework for distributed network analytics | |
| Caron et al. | Definition, modelling and simulation of a grid computing scheduling system for high throughput computing | |
| Bedini et al. | Modeling performance of a parallel streaming engine: bridging theory and costs | |
| Amoretti et al. | Efficient autonomic cloud computing using online discrete event simulation | |
| Marco et al. | The glite workload management system | |
| US20230315514A1 (en) | Configuration-driven data processing pipeline for an extensibility platform | |
| Iuhasz et al. | Architecture of a scalable platform for monitoring multiple big data frameworks | |
| Theeten et al. | Towards the optimization of a parallel streaming engine for telco applications | |
| Bellavista et al. | GAMESH: A grid architecture for scalable monitoring and enhanced dependable job scheduling | |
| CN112463312B (zh) | 一种定时任务的动态维护系统和方法、介质、计算设备 | |
| Pham | A big data analytics framework for iot applications in the cloud | |
| CN110162312A (zh) | 一种基于IML的BeeGFS配置方法与装置 | |
| Vijayakumar et al. | Calder query grid service: Insights and experimental evaluation | |
| Concas et al. | Plancton: an opportunistic distributed computing project based on Docker containers | |
| CN115208891A (zh) | 一种混合云弹性伸缩方法、装置、设备、存储介质 | |
| CN106502795A (zh) | 分布式集群上实现科学计算应用部署的方法及系统 | |
| Kakkad et al. | Curracurrong cloud: Stream processing in the cloud |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 24902654 Country of ref document: EP Kind code of ref document: A1 |