WO2021031767A1 - Resource scheduling method, smart front-end device, smart gateway, and distributed system - Google Patents

Resource scheduling method, smart front-end device, smart gateway, and distributed system Download PDF

Info

Publication number
WO2021031767A1
WO2021031767A1 PCT/CN2020/103084 CN2020103084W WO2021031767A1 WO 2021031767 A1 WO2021031767 A1 WO 2021031767A1 CN 2020103084 W CN2020103084 W CN 2020103084W WO 2021031767 A1 WO2021031767 A1 WO 2021031767A1
Authority
WO
WIPO (PCT)
Prior art keywords
smart
end device
task
smart front
gateway
Prior art date
Application number
PCT/CN2020/103084
Other languages
French (fr)
Chinese (zh)
Inventor
周平
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2021031767A1 publication Critical patent/WO2021031767A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/1012Server selection for load balancing based on compliance of requirements or conditions with available server resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/1008Server selection for load balancing based on parameters of servers, e.g. available memory or workload
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1029Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers using data related to the state of servers by a load balancer
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context

Definitions

  • the embodiment of the present invention relates to the field of security technology, in particular to a resource scheduling method, an intelligent front-end device, an intelligent gateway, and a distributed system.
  • front-end monitoring equipment collected data and transmitted the data to the back-end server or cloud computing platform for intelligent analysis.
  • Intelligent front-end equipment can preprocess video images to remove image redundant information, so that part or all of the video analysis is migrated to front-end computing, reducing the computing, storage and network bandwidth requirements of the cloud center, and improving the response speed of the equipment.
  • the computing and storage capabilities of access devices are different and change over time.
  • the types of tasks undertaken by different access devices are not the same, such as the need for cross-border alarm analysis near the perimeter, face capture at entrances and exits, and license plate recognition on the road.
  • front-end computing Most of the data storage and computing tasks in front-end computing rely on smart front-end equipment. Unlike cloud computing centers that have stable infrastructure protection, many smart front-end devices are exposed to the natural environment for a long time and are easily damaged by natural or man-made damage. In the context of front-end intelligent computing, the reliability of the entire security system and the stability of computing face new problems.
  • the embodiment of the present invention provides a resource scheduling method, which includes: when a first smart front-end device is not capable of performing a task, a smart gateway determines a second smart front-end device capable of performing the task; The smart front-end device sends the task, and the task carries the service address of the second smart front-end device.
  • An embodiment of the present invention provides a resource scheduling method, including: when a first smart front-end device is not capable of performing a computing task, a smart gateway determines a second smart front-end device capable of performing the computing task; The second smart front-end device sends the calculation task.
  • the embodiment of the present invention provides a resource scheduling method, including: a smart front-end device receives a task sent by a smart gateway, and obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task; The service address transfers the task to the other intelligent front-end equipment.
  • An embodiment of the present invention provides an intelligent gateway, including: a memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler is executed by the processor When implementing the steps of the corresponding resource scheduling method described above.
  • the embodiment of the present invention provides an intelligent front-end device, including: a memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler is controlled by the processor.
  • An embodiment of the present invention provides a computer-readable storage medium that stores a resource scheduling program, where the resource scheduling program is executed by a processor to implement the steps of the above-mentioned resource scheduling method.
  • Fig. 1 is a flowchart of a resource scheduling method according to Embodiment 1 of the present invention (applied to an intelligent gateway);
  • Embodiment 2 is a flowchart of a resource scheduling method according to Embodiment 2 of the present invention (applied to an intelligent gateway);
  • Figure 3 is a flow chart of a resource scheduling method according to Embodiment 3 of the present invention (applied to smart front-end equipment);
  • FIG. 4 is a schematic diagram of an intelligent gateway according to Embodiment 4 of the present invention.
  • FIG. 5 is a schematic diagram of an intelligent gateway according to Embodiment 5 of the present invention.
  • FIG. 6 is a schematic diagram of an intelligent front-end device according to Embodiment 6 of the present invention.
  • Figure 7 is a schematic diagram of a distributed system of Example 1.
  • Fig. 8 is a flowchart of a resource scheduling method of Example 2.
  • Fig. 9 is a flowchart of a resource scheduling method of Example 3.
  • Example 10 is a flowchart of a resource scheduling method of Example 4.
  • Fig. 11 is a flowchart of a resource scheduling method of Example 5.
  • Fig. 12 is a flowchart of a resource scheduling method of Example 6.
  • FIG. 13 is a flowchart of a resource scheduling method of Example 7.
  • Figure 14 is a schematic diagram of a smart gateway according to an embodiment of the present invention.
  • Fig. 15 is a schematic diagram of a smart front-end device according to an embodiment of the present invention.
  • an embodiment of the present invention provides a resource scheduling method, including:
  • Step S110 when the first smart front-end device is not capable of performing a task, the smart gateway determines a second smart front-end device capable of performing the task;
  • Step S120 the smart gateway sends the task to the first smart front-end device, where the task carries the service address of the second smart front-end device;
  • the task includes: a calculation task, a storage task, or a data recovery task.
  • the first smart front-end device is not capable of performing tasks, including any of the following:
  • the resources of the first smart front-end device are insufficient to complete the task
  • the smart gateway receives the resource request of the first smart front-end device
  • the data of the first smart front-end device has been backed up or migrated to other smart front-end devices.
  • the smart gateway determines that the first smart front-end device is not capable of performing the task by querying the resource status of the first smart front-end device; or, the smart gateway receives all the tasks.
  • the resource request sent by the first smart front-end device determines that the first smart front-end device is not capable of performing the task.
  • the smart gateway queries the resource status of each smart front-end device in the smart front-end device cluster, searches for a second smart front-end device whose resource status meets the task requirements, and determines the second smart front-end device as capable of performing the task Smart front-end equipment.
  • the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
  • the method further includes:
  • the smart gateway receives the calculation task execution result returned by the second smart front-end device, and sends the calculation task execution result to the server;
  • the server includes: a cloud server and/or a local server;
  • the computing task is allocated by the server to the first intelligent front-end device
  • the execution result of the calculation task may be successful execution of the task or failure of the execution of the task, and the calculation result may be carried when the execution of the task is successful;
  • the storage task includes: a backup task or a data migration task;
  • the storage task is to back up the designated data of the smart front-end device A
  • the storage space of the smart front-end device A is insufficient
  • a copy of the designated data of the smart front-end device A is copied, and the copy is stored in other smart front-end devices ( For example, on smart front-end devices B and C), smart front-end devices B and C each store a part of the copy.
  • the storage task is to perform data migration on the designated data of smart front-end device A
  • the storage space of smart front-end device A is insufficient, transfer the designated data of smart front-end device A to other smart front-end devices (such as smart front-end device B and In C)
  • the intelligent front-end devices B and C each store a part of the specified data.
  • the method further includes:
  • the smart gateway receives the storage task execution result returned by the first smart front-end device, and sends the storage task execution result to the server;
  • the server includes: a cloud server and/or a local server;
  • the storage task is allocated by the server to the first smart front-end device
  • the storage task execution result refers to storage success or failure
  • the method further includes:
  • the smart gateway stores the data storage relationship between the first smart front-end device and the second smart front-end device;
  • the number of second smart front-end devices capable of performing storage tasks is one or more;
  • the smart gateway determines whether the data of the first smart front-end device has been backed up or migrated to the second smart front-end device, and if yes, the first smart The front-end device is not capable of performing the data recovery task and the second intelligent front-end device is capable of performing the data recovery task.
  • the method further includes:
  • execution result of the data recovery task refers to the success or failure of data recovery
  • the method further includes:
  • the smart gateway When the smart gateway fails to send a task to the first smart front-end device, it determines the second smart front-end device as a transit device;
  • the smart gateway receives the task execution result of the first smart front-end device returned by the second smart front-end device.
  • an embodiment of the present invention provides a resource scheduling method, including:
  • Step S210 When the first smart front-end device is not capable of performing a computing task, the smart gateway determines a second smart front-end device capable of performing the computing task;
  • Step S220 The smart gateway sends the computing task to the second smart front-end device.
  • the first smart front-end device is not capable of performing computing tasks, including any one of the following:
  • the resources of the first smart front-end device are insufficient to complete the computing task
  • the smart gateway receives the resource request of the first smart front-end device.
  • the smart gateway determines that the first smart front-end device is not capable of executing the computing task by querying the resource status of the first smart front-end device; or, the smart gateway receives a computing resource request sent by the first smart front-end device When determining that the first smart front-end device is not capable of performing the computing task;
  • the smart gateway queries the resource status of each smart front-end device in the smart front-end device cluster, searches for a second smart front-end device whose resource state meets the requirements of the computing task, and determines that the second smart front-end device is capable of executing the Intelligent front-end equipment for computing tasks.
  • the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
  • the method further includes:
  • the smart gateway When the smart gateway fails to send a calculation task to the first smart front-end device, it determines the second smart front-end device as a transit device;
  • the smart gateway receives the calculation task execution result of the first smart front-end device returned by the second smart front-end device.
  • an embodiment of the present invention provides a resource scheduling method, including:
  • Step S310 The smart front-end device receives the task sent by the smart gateway, and obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task;
  • step S320 the smart front-end device transfers the task to the other smart front-end device according to the service address.
  • the task includes: a calculation task, a storage task, or a data recovery task.
  • the method before the smart front-end device obtains the service addresses of other smart front-end devices that assist in executing the task from the smart gateway, the method further includes:
  • the smart front-end device determines that the device is not capable of performing the task, and sends a resource request to the smart gateway.
  • the smart front-end device determines that the device is not capable of performing computing tasks by querying the resource status of the device;
  • the smart front-end device when the task is a storage task, stores data that needs to be backed up or migrated to the other smart front-end device according to the service address.
  • the method further includes:
  • the smart front-end device returns the storage task execution result to the smart gateway
  • the smart front-end device when the task is a data recovery task, obtains the previously backed-up or migrated data from the other smart front-end device according to the service address.
  • the method further includes:
  • the smart front-end device receives a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service;
  • the smart front-end equipment establishes a communication connection with the smart front-end equipment that needs transit services;
  • the smart front-end equipment receives tasks from the smart gateway, and forwards the tasks to the smart front-end equipment that needs a transit service;
  • the smart front-end device receives the task execution result from the smart front-end device that needs the transfer service, and forwards the task execution result to the smart gateway.
  • an embodiment of the present invention provides an intelligent gateway, including:
  • the analysis module 401 is configured to determine a second smart front-end device capable of performing the task when the first smart front-end device is not capable of performing the task;
  • the task includes: a calculation task, a storage task, or a data recovery task.
  • the first smart front-end device is not capable of performing tasks, including any of the following:
  • the resources of the first smart front-end device are insufficient to complete the task
  • the smart gateway receives the resource request of the first smart front-end device
  • the data of the first smart front-end device has been backed up or migrated to other smart front-end devices.
  • the analysis module is configured to determine that the first smart front-end device is not capable of performing the task in the following manner: by querying the resource status of the first smart front-end device It is determined that the first smart front-end device is not capable of performing the task; or, when a resource request sent by the first smart front-end device is received, it is determined that the first smart front-end device is not capable of performing the task.
  • the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
  • the analysis module is configured to determine the second smart front-end device capable of executing the task in the following manner: query in the smart front-end device cluster The resource status of each smart front-end device is searched for a second smart front-end device whose resource status meets the task requirements, and the second smart front-end device is determined as the smart front-end device capable of executing the task.
  • the smart gateway further includes: a first receiving module 403, configured to receive the calculation task execution result returned by the second smart front-end device, and send the calculation task execution result to the server;
  • the server includes: a cloud server and/or a local server;
  • the computing task is allocated by the server to the first intelligent front-end device
  • the execution result of the calculation task may be successful execution of the task or failure of the execution of the task, and the calculation result may also be carried when the execution of the task is successful;
  • the storage task includes: a backup task or a data migration task;
  • the device further includes: a second receiving module 404, configured to receive the storage task execution result returned by the first smart front-end device, and send the storage task execution result to the server;
  • the server includes: a cloud server and/or a local server;
  • the storage task is allocated by the server to the first smart front-end device
  • the storage task execution result refers to storage success or failure
  • the second receiving module is further configured to store the data storage relationship between the first smart front-end device and the second smart front-end device after receiving the storage task execution result returned by the first smart front-end device ;
  • the number of second smart front-end devices capable of performing storage tasks is one or more;
  • the analysis module is used to determine whether the data of the first smart front-end device has been backed up or migrated to the second smart front-end device, and if yes, the first smart front-end device is determined The smart front-end device is not capable of performing data recovery tasks and the second smart front-end device is capable of performing the data recovery tasks.
  • the device further includes: a third receiving module 405, configured to receive the data recovery task returned by the first smart front-end device after sending the data recovery task to the first smart front-end device The results of the implementation;
  • execution result of the data recovery task refers to the success or failure of data recovery
  • the task sending module is further configured to determine a second smart front-end device as a transfer device when sending a task to the first smart front-end device fails; send a transfer request to the second smart front-end device, and The communication address of the first smart front-end device; receiving the task execution result of the first smart front-end device returned by the second smart front-end device.
  • an embodiment of the present invention provides an intelligent gateway, including:
  • the analysis module 501 is configured to determine a second smart front-end device capable of performing the computing task when the first smart front-end device is not capable of performing the computing task;
  • Task sending module 502 configured to send the computing task to the second smart front-end device
  • the first smart front-end device is not capable of performing computing tasks, including any one of the following:
  • the resources of the first smart front-end device are insufficient to complete the computing task
  • the smart gateway receives the resource request of the first smart front-end device.
  • the analysis module is configured to determine that the first smart front-end device is not capable of performing the computing task by querying the resource status of the first smart front-end device; or, receiving a transmission from the first smart front-end device Determining that the first intelligent front-end device is not capable of executing the computing task when the computing resource is requested;
  • each smart front-end device in the smart front-end device cluster search for a second smart front-end device whose resource status meets the requirements of the computing task, and determine the second smart front-end device as a smart capable of executing the computing task Front-end equipment.
  • the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
  • the task sending module is further configured to determine the second smart front-end device as a transfer device when sending a computing task to the first smart front-end device fails; send a transfer request and the transfer request to the second smart front-end device The communication address of the first smart front-end device; receiving the calculation task execution result of the first smart front-end device returned by the second smart front-end device.
  • an embodiment of the present invention provides an intelligent front-end device, including:
  • the task receiving module 601 is configured to receive tasks sent by the smart gateway, and obtain the service addresses of other smart front-end devices that assist in executing the tasks from the smart gateway;
  • the task processing module 602 is configured to transfer the task to the other intelligent front-end equipment according to the service address.
  • the task includes: a calculation task, a storage task, or a data recovery task.
  • the smart front-end device further includes: a request module 603, configured to determine from the smart gateway that the device is not capable of executing the service address of other smart front-end devices that assist in executing the task. Task, send a resource request to the smart gateway.
  • a request module 603 configured to determine from the smart gateway that the device is not capable of executing the service address of other smart front-end devices that assist in executing the task. Task, send a resource request to the smart gateway.
  • the request module is configured to determine that the device is not capable of performing computing tasks by querying the resource status of the device;
  • the task processing module is configured to store data that needs to be backed up or migrated to the other smart front-end device according to the service address.
  • the smart front-end device further includes: a feedback module 604, configured to store data that needs to be backed up or migrated on the other smart front-end device, and then return the storage task execution result to the smart gateway;
  • the task processing module is configured to obtain the previously backed up or migrated data from the other intelligent front-end device according to the service address.
  • the smart front-end device further includes a transfer module 605 for receiving a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service; and the smart front-end device that needs the transfer service Establish a communication connection; receive tasks from the smart gateway, and forward the tasks to the smart front-end equipment that needs transit services; receive the task execution results from the smart front-end devices that need transit services, and forward the task execution results to the smart Gateway.
  • a transfer module 605 for receiving a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service
  • the smart front-end device that needs the transfer service Establish a communication connection; receive tasks from the smart gateway, and forward the tasks to the smart front-end equipment that needs transit services; receive the task execution results from the smart front-end devices that need transit services, and forward the task execution results to the smart Gateway.
  • an embodiment of the present invention provides an intelligent gateway, including:
  • the resource scheduling program is executed by the processor 1402 to implement the above-mentioned embodiment 1 The steps of the resource scheduling method described.
  • an embodiment of the present invention provides an intelligent gateway, including:
  • the resource scheduling program is executed by the processor 1402 to implement the above-mentioned embodiment 2 The steps of the resource scheduling method described.
  • an embodiment of the present invention provides an intelligent front-end device, including:
  • the embodiment of the present invention provides a distributed system, including: the above-mentioned intelligent front-end equipment and an intelligent gateway.
  • the embodiment of the present invention provides a computer-readable storage medium, the computer-readable storage medium stores a resource scheduling program, and the resource scheduling program implements the foregoing embodiment 1 or embodiment 2 or Steps of the resource scheduling method described in embodiment 3.
  • this example provides a distributed computing and storage system, including: an intelligent gateway (GateWay) and an intelligent front-end device.
  • the distributed computing and storage system is highly scalable, and realizes a unified external service interface through the intelligent gateway service, which reduces the difficulty of equipment access.
  • the smart gateway is the hub that connects the smart front-end device and the back-end server (cloud server and/or local server), and provides various service functions through API (Application Programming Interface) interfaces.
  • the smart front-end device can call the interface to register
  • the back-end server can call the interface to view the device information of the currently connected smart front-end device
  • the smart front-end device initiates a request for computing resources.
  • the intelligent front-end equipment receives instructions from the back-end server and processes tasks, and can provide computing, storage and forwarding functions through API interfaces.
  • Smart front-end devices can be connected to the smart gateway in a wired or wireless manner, and the smart front-end devices mainly forward messages through the smart gateway, and can also achieve direct communication in a wireless manner.
  • the smart front-end equipment accesses the system through the registration service interface provided by the smart gateway.
  • the smart gateway can view the resource status of the current device (including CPU utilization, storage status, network utilization, etc.) by calling the status query interface provided by the smart front-end device, and it can also obtain services of various capabilities provided by the current device by calling the capability interface Address, the services include computing services, storage services, transit services, etc.
  • the smart front-end device can obtain information of all smart front-end devices in the cluster through the service provided by the smart gateway. The information includes the communication address of the smart front-end device and storage and computing capability information.
  • This example provides a resource scheduling method.
  • the smart front-end equipment When the smart front-end equipment is overloaded and unable to receive new tasks, it can request computing resources from the smart gateway.
  • the smart gateway searches for all smart front-end devices in the cluster and comprehensively considers the computing, storage, and communication capabilities of the equipment to select suitable ones. And then forward the computing service address of the appropriate smart front-end device to the smart front-end device requesting computing resources. Forwarding computing resources through the smart gateway can prevent a certain smart front-end device from being overloaded with tasks.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server delivers tasks to the smart front-end device A through the smart gateway.
  • Step S102 After receiving the task, the smart front-end device A judges whether the current load exceeds the threshold, and if it exceeds the threshold, it initiates a request for computing resources to the smart gateway;
  • Step S103 After receiving the request, the smart gateway searches for all smart front-end devices in the cluster and comprehensively considers the computing, storage, and communication capabilities of the devices to select a suitable smart front-end device B, and then forwards the computing service address of the smart front-end device B To smart front-end equipment A.
  • Step S104 After the smart front-end device A obtains the service address of the smart front-end device B, the task is transferred through the interface provided by the smart front-end device B, and the data required for the calculation task can be sent to the smart front-end device B when needed.
  • Step S105 The smart front-end device B performs calculation after obtaining the task, and then forwards the calculation result to the background server through the smart gateway.
  • This example provides a resource scheduling method.
  • the smart gateway receives the task sent by the back-end server, it can determine whether the current device is capable of computing by obtaining the current resource status of the smart front-end device. If the computing power is insufficient, it searches for all smart front-end devices in the cluster and comprehensively considers the device's Computing, storage and communication capabilities, etc., screen out the appropriate smart front-end equipment, and then send the task to the appropriate smart front-end equipment, and at the same time forward the relevant service address of the original smart front-end equipment to the new smart front-end equipment, the new smart front-end equipment Relevant data can be obtained from the original smart front-end equipment. Forwarding computing resources through the smart gateway can prevent a certain smart front-end device from being overloaded with tasks.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server delivers tasks to the smart front-end device A through the smart gateway.
  • Step S102 The smart gateway first judges whether device A has enough computing resources to perform the task. If the computing power is insufficient, it searches for a suitable smart front-end device B with computing power that meets the requirements; among them, the bandwidth of the device is considered when searching, and the calculation and Storage capacity.
  • Step S103 The smart gateway forwards the calculation task to the smart front-end device B, and sends the related service address of the smart front-end device A to the smart front-end device B.
  • Step S104 The smart front-end device B performs calculations after receiving the task and the related service address of the smart front-end device A.
  • the smart front-end device B obtains relevant data according to the relevant service address of the smart front-end device A;
  • the task sent by the back-end server is to perform image analysis on the video surveillance data of the smart front-end device A. Since each smart front-end device can only obtain the video data in its own monitoring area, the smart front-end device B needs to obtain the video data from the smart front-end device. A get the relevant data, and then calculate.
  • the smart gateway may not send the relevant service address of the smart front-end device A to the smart front-end device B; when the computing task requires When relying on the data in the smart front-end device A, the smart gateway sends the related service address of the smart front-end device A to the smart front-end device B, and the smart front-end device B obtains the related data according to the related service address of the smart front-end device A.
  • Step S105 After the calculation of the smart front-end device B is completed, the calculation result is forwarded to the back-end server through the smart gateway.
  • This example provides a resource scheduling method.
  • the smart gateway When the back-end server issues a backup or data migration instruction to the smart front-end device A, the smart gateway first determines whether the current smart front-end device A has enough storage space to store data. If the space is not enough, it searches for a suitable smart front-end through a certain strategy Devices B and C, and send the searched storage addresses and task instructions of smart front-end devices B and C to smart front-end device A together. When the smart front-end device A receives the instruction, the data to be stored is evenly sliced, and the data is transferred through the received storage addresses of the smart front-end devices B and C in turn. Forwarding storage resource backup requests through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve data reliability.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server issues a backup or data migration task to the smart front-end device A through the smart gateway.
  • Step S102 The smart gateway first determines whether the current smart front-end device A has enough storage space to store data, and if the space is not enough, it searches for suitable smart front-end devices (for example, smart front-end devices B and C) through a certain strategy.
  • suitable smart front-end devices for example, smart front-end devices B and C
  • Step S103 The smart gateway forwards the storage service address list (B, C) and storage instructions of the smart front-end device to the smart front-end device A.
  • Step S104 After the smart front-end device A obtains the storage instruction and the storage service address list, the data that needs to be backed up or migrated is evenly transferred to other smart front-end devices.
  • Step S105 The smart front-end device A sends the task execution result to the smart gateway.
  • task execution results include: backup success or backup failure
  • the task execution results include: data migration success or data migration failure;
  • Step S106 the smart gateway stores the data relationship
  • the data relationship stored by the smart gateway is: the data backup address of smart front-end device A is smart front-end device B and smart front-end device C;
  • the data relationship stored by the smart gateway is: the data migration address of smart front-end device A is smart front-end device B and smart front-end device C;
  • Step S107 The smart gateway sends the task execution result to the background server.
  • This example provides a resource scheduling method.
  • the smart front-end device A When the smart front-end device A has insufficient storage space and cannot receive new backup or data migration tasks, it can request storage resources from the smart gateway.
  • the smart gateway searches for suitable smart front-end devices B and C through a certain strategy, and then determines the appropriate
  • the storage service address of the smart front-end device is forwarded to the smart front-end device A that requests storage resources.
  • the smart front-end device A receives the instruction, the data to be stored is evenly sliced, and the data is transferred through the received storage addresses of the smart front-end devices B and C in turn. Forwarding storage resource backup requests through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve data reliability.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server issues a backup or data migration task to the smart front-end device A through the smart gateway.
  • Step S102 After receiving the task, the smart front-end device A judges whether there is enough storage space to store data, and if the space is not enough, it initiates a request for storage resources to the smart gateway;
  • Step S103 After receiving the request, the smart gateway searches for suitable smart front-end devices (for example, smart front-end devices B and C) through a certain strategy.
  • suitable smart front-end devices for example, smart front-end devices B and C
  • Step S104 The smart gateway forwards the storage service address list (B, C) and storage instructions of the smart front-end device to the smart front-end device A.
  • Step S105 After the smart front-end device A obtains the instruction and the storage service address list, it evenly transfers the data that needs to be backed up or migrated to other smart front-end devices.
  • Step S106 The smart front-end device A sends the task execution result to the smart gateway.
  • task execution results include: backup success or backup failure
  • the task execution results include: data migration success or data migration failure;
  • Step S107 the smart gateway stores the data relationship
  • the data relationship stored by the smart gateway is: the data backup address of smart front-end device A is smart front-end device B and smart front-end device C;
  • the data relationship stored by the smart gateway is: the data migration address of smart front-end device A is smart front-end device B and smart front-end device C;
  • Step S108 The smart gateway sends the task execution result to the background server.
  • This example provides a resource scheduling method.
  • the smart gateway sends the previously stored service storage address and task instructions to the smart front-end device A together.
  • the smart front-end device A receives the task instruction, it first determines whether the storage address of the backup data is stored locally, and if not, it restores the data through the storage address passed by the gateway. Forwarding the data recovery request through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve the reliability of the data.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server issues a data recovery task to the smart front-end device A through the smart gateway.
  • Step S102 The smart gateway forwards the data recovery instruction and the server address list (smart front-end device B, C) for data backup or migration to the smart front-end device A.
  • Step S103 After receiving the instruction, the smart front-end device A first searches whether the server address for data backup or migration is stored locally, and if not, it uses the address list passed by the smart gateway.
  • Step S104 The smart front-end device A restores the data through the address list.
  • smart front-end device A obtains data from smart front-end devices B and C respectively according to the server address of the data backup or migration;
  • Step S105 The smart front-end device A forwards the task execution result to the back-end server through the gateway.
  • the task execution result refers to: data recovery success or data recovery failure.
  • This example provides a resource scheduling method.
  • the smart gateway When the smart gateway loses connection with the smart front-end device, the smart gateway selects the appropriate one through a certain search strategy (considering the distance between other smart front-end devices and the smart front-end device that has lost contact, communication capabilities, and current resource utilization) Smart front-end device B then initiates a transfer request to smart front-end device B, smart front-end device B establishes a connection with smart front-end device A, and all subsequent messages sent by smart front-end device A to the smart gateway are forwarded by smart front-end device B.
  • a smart front-end device loses connection with the smart gateway, data can be transferred through other smart front-end devices in the cluster, thereby improving the reliability and stability of the system.
  • the resource scheduling method of this example may include the following steps:
  • Step S101 The background server issues a task instruction to a certain smart front-end device (smart front-end device A).
  • Step S102 The smart gateway tries to forward the task instruction to the smart front-end device A for multiple times.
  • Step S103 After the smart gateway fails to attempt to communicate with the smart front-end device A, it searches for the best transit device (the smart front-end device B) through a certain search strategy.
  • Step S104 The smart gateway initiates a transfer request to the smart front-end device B, and provides the wireless communication address of the smart front-end device A.
  • Step S105 After receiving the transfer request, the smart front-end device B actively establishes a communication connection with the smart front-end device A, and forwards the instruction to the smart front-end device A.
  • Step S106 The smart front-end device A performs calculations after receiving the instruction, and then returns the calculation result to the smart front-end device B;
  • Step S107 The smart front-end device B feeds back the calculation result to the back-end server through the smart gateway.
  • the smart gateway determines a second smart front-end device capable of performing the task
  • the smart gateway sends the task to the first smart front-end device, and the task carries the service address of the second smart front-end device.
  • the embodiment of the present invention can improve the reliability of the security system and the stability of calculation.
  • the embodiments of the present invention can improve the reliability of the security system and the stability of calculation and storage.
  • Such software may be distributed on a computer-readable medium
  • the computer-readable medium may include a computer storage medium (or non-transitory medium) and a communication medium (or transitory medium).
  • the term computer storage medium includes volatile and non-volatile memory implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data).
  • Computer storage media include but are not limited to RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cassette, tape, magnetic disk storage or other magnetic storage device, or Any other medium used to store desired information and that can be accessed by a computer.
  • communication media usually contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as carrier waves or other transmission mechanisms, and may include any information delivery media .

Abstract

A resource scheduling method, a smart front-end device, a smart gateway, and a distributed system. The resource scheduling method comprises: when a first smart front-end device is unable to execute a task, a smart gateway determining a second smart front-end device capable of executing the task (S110); and the smart gateway sending the task to the first smart front-end device, wherein the task carries a service address of the second smart front-end device (S120).

Description

资源调度方法、智能前端设备、智能网关及分布式系统Resource scheduling method, intelligent front-end equipment, intelligent gateway and distributed system
相关申请的交叉引用Cross references to related applications
本申请基于申请号为201910778773.5、申请日为2019年08月22日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。This application is filed based on the Chinese patent application with the application number 201910778773.5 and the filing date on August 22, 2019, and claims the priority of the Chinese patent application. The entire content of the Chinese patent application is hereby incorporated into this application by reference.
技术领域Technical field
本发明实施例涉及安防技术领域,尤其涉及的是一种资源调度方法、智能前端设备、智能网关及分布式系统。The embodiment of the present invention relates to the field of security technology, in particular to a resource scheduling method, an intelligent front-end device, an intelligent gateway, and a distributed system.
背景技术Background technique
在智能安防发展的早期阶段,受到前端监控设备的平台性能限制,不足以支撑处理大量的智能分析计算,主要通过前端监控设备采集数据,将数据传输到后台服务器或云计算平台进行智能分析。In the early stage of the development of smart security, the platform performance of front-end monitoring equipment was limited, and it was not enough to support processing a large number of intelligent analysis calculations. The front-end monitoring equipment collected data and transmitted the data to the back-end server or cloud computing platform for intelligent analysis.
随着超高清及4K高清显示技术的发展及海量设备的接入,智能安防系统面临带宽不够、延迟增大以及服务器数量增加等问题。与此同时,随着视频监控前端计算能力的增强,以及专用芯片的出现,让智能前置成为可能。智能前端设备可以通过对视频图像进行预处理去除图像冗余信息,使得部分或全部视频分析迁移到前端计算,降低对云中心的计算、存储和网络带宽需求,提高设备响应速度。With the development of ultra-high-definition and 4K high-definition display technology and the access of a large number of devices, intelligent security systems are facing problems such as insufficient bandwidth, increased latency, and increased number of servers. At the same time, with the enhancement of the computing power of the video surveillance front-end and the emergence of dedicated chips, intelligent front-end is possible. Intelligent front-end equipment can preprocess video images to remove image redundant information, so that part or all of the video analysis is migrated to front-end computing, reducing the computing, storage and network bandwidth requirements of the cloud center, and improving the response speed of the equipment.
在智能计算前端化的情景下,接入设备(智能前端设备)的计算与存储能力存在差异并且随着时间的变化而变化。另外,不同接入设备承担的任务类型也不尽相同,如周界附近需要越界报警分析、出入口需要人脸抓拍、路面上需要车牌识别等。In the context of smart computing front-end, the computing and storage capabilities of access devices (smart front-end devices) are different and change over time. In addition, the types of tasks undertaken by different access devices are not the same, such as the need for cross-border alarm analysis near the perimeter, face capture at entrances and exits, and license plate recognition on the road.
前端计算中的数据存储和计算任务大多数都依赖智能前端设备,不像云计算中心有稳定的基础设施保护,许多智能前端设备长期暴露在自然环境下,容易受到自然或人为损害,因此,在智能计算前端化的情景下,整个安防系统的可靠性以及计算的稳定性面临新的问题。Most of the data storage and computing tasks in front-end computing rely on smart front-end equipment. Unlike cloud computing centers that have stable infrastructure protection, many smart front-end devices are exposed to the natural environment for a long time and are easily damaged by natural or man-made damage. In the context of front-end intelligent computing, the reliability of the entire security system and the stability of computing face new problems.
发明内容Summary of the invention
本发明实施例提供一种资源调度方法,包括:在第一智能前端设备没有能力执行任务时,智能网关确定有能力执行所述任务的第二智能前端设备;所述智能网关向所述第一智能前端设备发送所述任务,所述任务携带所述第二智能前端设备的服务地址。The embodiment of the present invention provides a resource scheduling method, which includes: when a first smart front-end device is not capable of performing a task, a smart gateway determines a second smart front-end device capable of performing the task; The smart front-end device sends the task, and the task carries the service address of the second smart front-end device.
本发明实施例提供一种资源调度方法,包括:在第一智能前端设备没有能力执行计算任务时,智能网关确定有能力执行所述计算任务的第二智能前端设备;所述智能网关向所述第二智能前端设备发送所述计算任务。An embodiment of the present invention provides a resource scheduling method, including: when a first smart front-end device is not capable of performing a computing task, a smart gateway determines a second smart front-end device capable of performing the computing task; The second smart front-end device sends the calculation task.
本发明实施例提供一种资源调度方法,包括:智能前端设备接收智能网关发送的任务,并从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址;智能前端设备根据所述服务地址将所述 任务转移至所述其他智能前端设备上。The embodiment of the present invention provides a resource scheduling method, including: a smart front-end device receives a task sent by a smart gateway, and obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task; The service address transfers the task to the other intelligent front-end equipment.
本发明实施例提供一种智能网关,包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的资源调度程序,其中,所述资源调度程序被所述处理器执行时实现上述对应的资源调度方法的步骤。An embodiment of the present invention provides an intelligent gateway, including: a memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler is executed by the processor When implementing the steps of the corresponding resource scheduling method described above.
本发明实施例提供一种智能前端设备,包括:存储器、处理器及存储在所述存储器上并可在所述处理器上运行的资源调度程序,其中,所述资源调度程序被所述处理器执行时实现上述对应的资源调度方法的步骤。The embodiment of the present invention provides an intelligent front-end device, including: a memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler is controlled by the processor The steps of the corresponding resource scheduling method mentioned above are realized during execution.
本发明实施例提供一种计算机可读存储介质,存储有资源调度程序,其中,所述资源调度程序被处理器执行时实现上述的资源调度方法的步骤。An embodiment of the present invention provides a computer-readable storage medium that stores a resource scheduling program, where the resource scheduling program is executed by a processor to implement the steps of the above-mentioned resource scheduling method.
附图说明Description of the drawings
图1为本发明实施例1的一种资源调度方法流程图(应用于智能网关);Fig. 1 is a flowchart of a resource scheduling method according to Embodiment 1 of the present invention (applied to an intelligent gateway);
图2为本发明实施例2的一种资源调度方法流程图(应用于智能网关);2 is a flowchart of a resource scheduling method according to Embodiment 2 of the present invention (applied to an intelligent gateway);
图3为本发明实施例3的一种资源调度方法流程图(应用于智能前端设备);Figure 3 is a flow chart of a resource scheduling method according to Embodiment 3 of the present invention (applied to smart front-end equipment);
图4为本发明实施例4的一种智能网关示意图;4 is a schematic diagram of an intelligent gateway according to Embodiment 4 of the present invention;
图5为本发明实施例5的一种智能网关示意图;FIG. 5 is a schematic diagram of an intelligent gateway according to Embodiment 5 of the present invention;
图6为本发明实施例6的一种智能前端设备示意图;FIG. 6 is a schematic diagram of an intelligent front-end device according to Embodiment 6 of the present invention;
图7为示例1的一种分布式系统示意图;Figure 7 is a schematic diagram of a distributed system of Example 1;
图8为示例2的一种资源调度方法流程图;Fig. 8 is a flowchart of a resource scheduling method of Example 2;
图9为示例3的一种资源调度方法流程图;Fig. 9 is a flowchart of a resource scheduling method of Example 3;
图10为示例4的一种资源调度方法流程图;10 is a flowchart of a resource scheduling method of Example 4;
图11为示例5的一种资源调度方法流程图;Fig. 11 is a flowchart of a resource scheduling method of Example 5;
图12为示例6的一种资源调度方法流程图;Fig. 12 is a flowchart of a resource scheduling method of Example 6;
图13为示例7的一种资源调度方法流程图;FIG. 13 is a flowchart of a resource scheduling method of Example 7;
图14为本发明实施例的智能网关的示意图;Figure 14 is a schematic diagram of a smart gateway according to an embodiment of the present invention;
图15为本发明实施例的智能前端设备的示意图。Fig. 15 is a schematic diagram of a smart front-end device according to an embodiment of the present invention.
具体实施方式detailed description
为使本发明的目的、技术方案和优点更加清楚明白,下文中将结合附图对本发明的实施例进行详细说明。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互任意组合。In order to make the objectives, technical solutions, and advantages of the present invention clearer, the embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be noted that the embodiments in this application and the features in the embodiments can be combined with each other arbitrarily if there is no conflict.
实施例1Example 1
如图1所示,本发明实施例提供了一种资源调度方法,包括:As shown in Figure 1, an embodiment of the present invention provides a resource scheduling method, including:
步骤S110,在第一智能前端设备没有能力执行任务时,智能网关确定有能力执行所述任务的第二智能前端设备;Step S110, when the first smart front-end device is not capable of performing a task, the smart gateway determines a second smart front-end device capable of performing the task;
步骤S120,所述智能网关向所述第一智能前端设备发送所述任务,所述任务携带所述第二智能前端设备的服务地址;Step S120, the smart gateway sends the task to the first smart front-end device, where the task carries the service address of the second smart front-end device;
在一种实施方式中,所述任务包括:计算任务、存储任务或数据恢复任务。In an embodiment, the task includes: a calculation task, a storage task, or a data recovery task.
在一种实施方式中,所述第一智能前端设备没有能力执行任务,包括以下任意一种:In an implementation manner, the first smart front-end device is not capable of performing tasks, including any of the following:
所述第一智能前端设备的资源不足,无法完成所述任务;The resources of the first smart front-end device are insufficient to complete the task;
智能网关接收到所述第一智能前端设备的资源请求;The smart gateway receives the resource request of the first smart front-end device;
所述第一智能前端设备的数据已经备份或迁移到其他智能前端设备上。The data of the first smart front-end device has been backed up or migrated to other smart front-end devices.
当所述任务为计算任务或存储任务时,所述智能网关通过查询第一智能前端设备的资源状态确定所述第一智能前端设备没有能力执行所述任务;或者,所述智能网关接收到所述第一智能前端设备发送的资源请求时确定所述第一智能前端设备没有能力执行所述任务。所述智能网关在智能前端设备集群中查询各个智能前端设备的资源状态,搜索资源状态满足所述任务要求的第二智能前端设备,将所述第二智能前端设备确定为有能力执行所述任务的智能前端设备。When the task is a computing task or a storage task, the smart gateway determines that the first smart front-end device is not capable of performing the task by querying the resource status of the first smart front-end device; or, the smart gateway receives all the tasks. The resource request sent by the first smart front-end device determines that the first smart front-end device is not capable of performing the task. The smart gateway queries the resource status of each smart front-end device in the smart front-end device cluster, searches for a second smart front-end device whose resource status meets the task requirements, and determines the second smart front-end device as capable of performing the task Smart front-end equipment.
其中,所述资源状态包括以下至少一种:计算能力、存储能力和带宽;Wherein, the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
在一种实施方式中,所述方法还包括:In one embodiment, the method further includes:
所述智能网关接收所述第二智能前端设备返回的计算任务执行结果,将所述计算任务执行结果发送给服务器;The smart gateway receives the calculation task execution result returned by the second smart front-end device, and sends the calculation task execution result to the server;
其中,所述服务器包括:云端服务器和/或本地服务器;Wherein, the server includes: a cloud server and/or a local server;
其中,所述计算任务是服务器分配给第一智能前端设备的;Wherein, the computing task is allocated by the server to the first intelligent front-end device;
其中,所述计算任务执行结果可以是任务执行成功或任务执行失败,在任务执行成功时还可以携带计算结果;Wherein, the execution result of the calculation task may be successful execution of the task or failure of the execution of the task, and the calculation result may be carried when the execution of the task is successful;
在一种实施方式中,所述存储任务包括:备份任务或数据迁移任务;In an embodiment, the storage task includes: a backup task or a data migration task;
其中,如果存储任务是备份智能前端设备A的指定数据,当智能前端设备A的存储空间不足时,将智能前端设备A的指定数据拷贝一份副本,将所述副本存储到其他智能前端设备(比如智能前端设备B和C)上,智能前端设备B和C上各存储所述副本的一部分。Among them, if the storage task is to back up the designated data of the smart front-end device A, when the storage space of the smart front-end device A is insufficient, a copy of the designated data of the smart front-end device A is copied, and the copy is stored in other smart front-end devices ( For example, on smart front-end devices B and C), smart front-end devices B and C each store a part of the copy.
其中,如果存储任务是对智能前端设备A的指定数据进行数据迁移,当智能前端设备A的存储空间不足时,将智能前端设备A的指定数据转移到其他智能前端设备(比如智能前端设备B和C)上,智能前端设备B和C上各存储所述指定数据的一部分。Among them, if the storage task is to perform data migration on the designated data of smart front-end device A, when the storage space of smart front-end device A is insufficient, transfer the designated data of smart front-end device A to other smart front-end devices (such as smart front-end device B and In C), the intelligent front-end devices B and C each store a part of the specified data.
在一种实施方式中,所述方法还包括:In one embodiment, the method further includes:
所述智能网关接收所述第一智能前端设备返回的存储任务执行结果,将所述存储任务执行结果发送给服务器;The smart gateway receives the storage task execution result returned by the first smart front-end device, and sends the storage task execution result to the server;
其中,所述服务器包括:云端服务器和/或本地服务器;Wherein, the server includes: a cloud server and/or a local server;
其中,所述存储任务是服务器分配给第一智能前端设备的;Wherein, the storage task is allocated by the server to the first smart front-end device;
其中,所述存储任务执行结果是指存储成功或失败;Wherein, the storage task execution result refers to storage success or failure;
在一种实施方式中,所述智能网关接收到所述第一智能前端设备返回的存储任务执行结果后,所述方法还包括:In an embodiment, after the smart gateway receives the storage task execution result returned by the first smart front-end device, the method further includes:
所述智能网关存储第一智能前端设备与第二智能前端设备的数据存储关系;The smart gateway stores the data storage relationship between the first smart front-end device and the second smart front-end device;
在一种实施方式中,有能力执行存储任务的第二智能前端设备的数量为一个或多个;In one embodiment, the number of second smart front-end devices capable of performing storage tasks is one or more;
在一种实施方式中,当所述任务为数据恢复任务时,所述智能网关判断所述第一智能前端设备的数据是否已经备份或迁移到第二智能前端设备上,是则确定第一智能前端设备没有能力执行数据恢复任务且第二智能前端设备有能力执行所述数据恢复任务。In one embodiment, when the task is a data recovery task, the smart gateway determines whether the data of the first smart front-end device has been backed up or migrated to the second smart front-end device, and if yes, the first smart The front-end device is not capable of performing the data recovery task and the second intelligent front-end device is capable of performing the data recovery task.
在一种实施方式中,所述智能网关向所述第一智能前端设备发送所述数据恢复任务后,所述方法还包括:In an embodiment, after the smart gateway sends the data recovery task to the first smart front-end device, the method further includes:
所述智能网关接收所述第一智能前端设备返回的数据恢复任务的执行结果;Receiving, by the smart gateway, the execution result of the data recovery task returned by the first smart front-end device;
其中,所述数据恢复任务的执行结果是指数据恢复成功或失败;Wherein, the execution result of the data recovery task refers to the success or failure of data recovery;
在一种实施方式中,所述方法还包括:In one embodiment, the method further includes:
智能网关向第一智能前端设备发送任务失败时,确定作为中转设备的第二智能前端设备;When the smart gateway fails to send a task to the first smart front-end device, it determines the second smart front-end device as a transit device;
所述智能网关向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;Sending, by the smart gateway, a transfer request and the communication address of the first smart front-end device to the second smart front-end device;
所述智能网关接收所述第二智能前端设备返回的所述第一智能前端设备的任务执行结果。The smart gateway receives the task execution result of the first smart front-end device returned by the second smart front-end device.
实施例2Example 2
如图2所示,本发明实施例提供了一种资源调度方法,包括:As shown in Figure 2, an embodiment of the present invention provides a resource scheduling method, including:
步骤S210,在第一智能前端设备没有能力执行计算任务时,智能网关确定有能力执行所述计算任务的第二智能前端设备;Step S210: When the first smart front-end device is not capable of performing a computing task, the smart gateway determines a second smart front-end device capable of performing the computing task;
步骤S220,所述智能网关向所述第二智能前端设备发送所述计算任务。Step S220: The smart gateway sends the computing task to the second smart front-end device.
在一种实施方式中,所述第一智能前端设备没有能力执行计算任务,包括以下任意一种:In an implementation manner, the first smart front-end device is not capable of performing computing tasks, including any one of the following:
所述第一智能前端设备的资源不足,无法完成所述计算任务;The resources of the first smart front-end device are insufficient to complete the computing task;
智能网关接收到所述第一智能前端设备的资源请求。The smart gateway receives the resource request of the first smart front-end device.
所述智能网关通过查询第一智能前端设备的资源状态确定所述第一智能前端设备没有能力执行所述计算任务;或者,所述智能网关接收到所述第一智能前端设备发送的计算资源请求时确定所述第一智能前端设备没有能力执行所述计算任务;The smart gateway determines that the first smart front-end device is not capable of executing the computing task by querying the resource status of the first smart front-end device; or, the smart gateway receives a computing resource request sent by the first smart front-end device When determining that the first smart front-end device is not capable of performing the computing task;
所述智能网关在智能前端设备集群中查询各个智能前端设备的资源状态,搜索资源状态满足所述计算任务要求的第二智能前端设备,将所述第二智能前端设备确定为有能力执行所述计算任务的智能前端设备。The smart gateway queries the resource status of each smart front-end device in the smart front-end device cluster, searches for a second smart front-end device whose resource state meets the requirements of the computing task, and determines that the second smart front-end device is capable of executing the Intelligent front-end equipment for computing tasks.
其中,所述资源状态包括以下至少一种:计算能力、存储能力和带宽;Wherein, the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
在一种实施方式中,所述方法还包括:In one embodiment, the method further includes:
智能网关向第一智能前端设备发送计算任务失败时,确定作为中转设备的第二智能前端设备;When the smart gateway fails to send a calculation task to the first smart front-end device, it determines the second smart front-end device as a transit device;
所述智能网关向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;Sending, by the smart gateway, a transfer request and the communication address of the first smart front-end device to the second smart front-end device;
所述智能网关接收所述第二智能前端设备返回的所述第一智能前端设备的计算任务执行结果。The smart gateway receives the calculation task execution result of the first smart front-end device returned by the second smart front-end device.
实施例3Example 3
如图3所示,本发明实施例提供了一种资源调度方法,包括:As shown in Figure 3, an embodiment of the present invention provides a resource scheduling method, including:
步骤S310,智能前端设备接收智能网关发送的任务,并从所述智能网关获取协助执行所述任务的 其他智能前端设备的服务地址;Step S310: The smart front-end device receives the task sent by the smart gateway, and obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task;
步骤S320,智能前端设备根据所述服务地址将所述任务转移至所述其他智能前端设备上。In step S320, the smart front-end device transfers the task to the other smart front-end device according to the service address.
在一种实施方式中,所述任务包括:计算任务、存储任务或数据恢复任务。In an embodiment, the task includes: a calculation task, a storage task, or a data recovery task.
在一种实施方式中,智能前端设备从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址之前,所述方法还包括:In an embodiment, before the smart front-end device obtains the service addresses of other smart front-end devices that assist in executing the task from the smart gateway, the method further includes:
智能前端设备确定本设备没有能力执行所述任务,向智能网关发送资源请求。The smart front-end device determines that the device is not capable of performing the task, and sends a resource request to the smart gateway.
在一种实施方式中,所述智能前端设备通过查询本设备的资源状态确定本设备没有能力执行计算任务;In one embodiment, the smart front-end device determines that the device is not capable of performing computing tasks by querying the resource status of the device;
在一种实施方式中,当所述任务为存储任务时,所述智能前端设备根据所述服务地址将需要备份或迁移的数据存储到所述其他智能前端设备上。In an embodiment, when the task is a storage task, the smart front-end device stores data that needs to be backed up or migrated to the other smart front-end device according to the service address.
在一种实施方式中,所述智能前端设备将需要备份或迁移的数据存储到所述其他智能前端设备上后,所述方法还包括:In an embodiment, after the smart front-end device stores the data that needs to be backed up or migrated on the other smart front-end devices, the method further includes:
所述智能前端设备向智能网关返回存储任务执行结果;The smart front-end device returns the storage task execution result to the smart gateway;
在一种实施方式中,当所述任务为数据恢复任务时,智能前端设备根据所述服务地址从所述其他智能前端设备获取之前备份或迁移的数据。In one embodiment, when the task is a data recovery task, the smart front-end device obtains the previously backed-up or migrated data from the other smart front-end device according to the service address.
在一种实施方式中,所述方法还包括:In one embodiment, the method further includes:
智能前端设备接收中转请求,所述中转请求中携带需要中转服务的智能前端设备的通信地址;The smart front-end device receives a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service;
智能前端设备与需要中转服务的智能前端设备建立通信连接;The smart front-end equipment establishes a communication connection with the smart front-end equipment that needs transit services;
智能前端设备从智能网关接收任务,将所述任务转发给所述需要中转服务的智能前端设备;The smart front-end equipment receives tasks from the smart gateway, and forwards the tasks to the smart front-end equipment that needs a transit service;
智能前端设备从需要中转服务的智能前端设备接收任务执行结果,将所述任务执行结果转发给所述智能网关。The smart front-end device receives the task execution result from the smart front-end device that needs the transfer service, and forwards the task execution result to the smart gateway.
实施例4Example 4
如图4所示,本发明实施例提供了一种智能网关,包括:As shown in Figure 4, an embodiment of the present invention provides an intelligent gateway, including:
分析模块401,用于在第一智能前端设备没有能力执行任务时,确定有能力执行所述任务的第二智能前端设备;The analysis module 401 is configured to determine a second smart front-end device capable of performing the task when the first smart front-end device is not capable of performing the task;
任务发送模块402,用于向所述第一智能前端设备发送所述任务,所述任务携带所述第二智能前端设备的服务地址;A task sending module 402, configured to send the task to the first smart front-end device, the task carrying the service address of the second smart front-end device;
在一种实施方式中,所述任务包括:计算任务、存储任务或数据恢复任务。In an embodiment, the task includes: a calculation task, a storage task, or a data recovery task.
在一种实施方式中,所述第一智能前端设备没有能力执行任务,包括以下任意一种:In an implementation manner, the first smart front-end device is not capable of performing tasks, including any of the following:
所述第一智能前端设备的资源不足,无法完成所述任务;The resources of the first smart front-end device are insufficient to complete the task;
智能网关接收到所述第一智能前端设备的资源请求;The smart gateway receives the resource request of the first smart front-end device;
所述第一智能前端设备的数据已经备份或迁移到其他智能前端设备上。The data of the first smart front-end device has been backed up or migrated to other smart front-end devices.
在一种实施方式中,当所述任务为计算任务或存储任务时,所述分析模块,用于采用以下方式确定第一智能前端设备没有能力执行任务:通过查询第一智能前端设备的资源状态确定所述第一智能前端设备没有能力执行所述任务;或者,接收到所述第一智能前端设备发送的资源请求时确定所述第一智能前 端设备没有能力执行所述任务。In one embodiment, when the task is a computing task or a storage task, the analysis module is configured to determine that the first smart front-end device is not capable of performing the task in the following manner: by querying the resource status of the first smart front-end device It is determined that the first smart front-end device is not capable of performing the task; or, when a resource request sent by the first smart front-end device is received, it is determined that the first smart front-end device is not capable of performing the task.
其中,所述资源状态包括以下至少一种:计算能力、存储能力和带宽;Wherein, the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
在一种实施方式中,当所述任务为计算任务或存储任务时,所述分析模块,用于采用以下方式确定有能力执行所述任务的第二智能前端设备:在智能前端设备集群中查询各个智能前端设备的资源状态,搜索资源状态满足所述任务要求的第二智能前端设备,将所述第二智能前端设备确定为有能力执行所述任务的智能前端设备。In one embodiment, when the task is a computing task or a storage task, the analysis module is configured to determine the second smart front-end device capable of executing the task in the following manner: query in the smart front-end device cluster The resource status of each smart front-end device is searched for a second smart front-end device whose resource status meets the task requirements, and the second smart front-end device is determined as the smart front-end device capable of executing the task.
在一种实施方式中,所述智能网关还包括:第一接收模块403,用于接收所述第二智能前端设备返回的计算任务执行结果,将所述计算任务执行结果发送给服务器;In an embodiment, the smart gateway further includes: a first receiving module 403, configured to receive the calculation task execution result returned by the second smart front-end device, and send the calculation task execution result to the server;
其中,所述服务器包括:云端服务器和/或本地服务器;Wherein, the server includes: a cloud server and/or a local server;
其中,所述计算任务是服务器分配给第一智能前端设备的;Wherein, the computing task is allocated by the server to the first intelligent front-end device;
其中,所述计算任务执行结果可以是任务执行成功或任务执行失败,在任务执行成功时还可以携带计算结果;Wherein, the execution result of the calculation task may be successful execution of the task or failure of the execution of the task, and the calculation result may also be carried when the execution of the task is successful;
在一种实施方式中,所述存储任务包括:备份任务或数据迁移任务;In an embodiment, the storage task includes: a backup task or a data migration task;
在一种实施方式中,所述装置还包括:第二接收模块404,用于接收所述第一智能前端设备返回的存储任务执行结果,将所述存储任务执行结果发送给服务器;In one embodiment, the device further includes: a second receiving module 404, configured to receive the storage task execution result returned by the first smart front-end device, and send the storage task execution result to the server;
其中,所述服务器包括:云端服务器和/或本地服务器;Wherein, the server includes: a cloud server and/or a local server;
其中,所述存储任务是服务器分配给第一智能前端设备的;Wherein, the storage task is allocated by the server to the first smart front-end device;
其中,所述存储任务执行结果是指存储成功或失败;Wherein, the storage task execution result refers to storage success or failure;
在一种实施方式中,所述第二接收模块,还用于接收到所述第一智能前端设备返回的存储任务执行结果后,存储第一智能前端设备与第二智能前端设备的数据存储关系;In an embodiment, the second receiving module is further configured to store the data storage relationship between the first smart front-end device and the second smart front-end device after receiving the storage task execution result returned by the first smart front-end device ;
在一种实施方式中,有能力执行存储任务的第二智能前端设备的数量为一个或多个;In one embodiment, the number of second smart front-end devices capable of performing storage tasks is one or more;
在一种实施方式中,当所述任务为数据恢复任务时,分析模块,用于判断所述第一智能前端设备的数据是否已经备份或迁移到第二智能前端设备上,是则确定第一智能前端设备没有能力执行数据恢复任务且第二智能前端设备有能力执行所述数据恢复任务。In one embodiment, when the task is a data recovery task, the analysis module is used to determine whether the data of the first smart front-end device has been backed up or migrated to the second smart front-end device, and if yes, the first smart front-end device is determined The smart front-end device is not capable of performing data recovery tasks and the second smart front-end device is capable of performing the data recovery tasks.
在一种实施方式中,所述装置还包括:第三接收模块405,用于向所述第一智能前端设备发送所述数据恢复任务后,接收所述第一智能前端设备返回的数据恢复任务的执行结果;In an implementation manner, the device further includes: a third receiving module 405, configured to receive the data recovery task returned by the first smart front-end device after sending the data recovery task to the first smart front-end device The results of the implementation;
其中,所述数据恢复任务的执行结果是指数据恢复成功或失败;Wherein, the execution result of the data recovery task refers to the success or failure of data recovery;
在一种实施方式中,所述任务发送模块,还用于向第一智能前端设备发送任务失败时,确定作为中转设备的第二智能前端设备;向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;接收所述第二智能前端设备返回的所述第一智能前端设备的任务执行结果。In one embodiment, the task sending module is further configured to determine a second smart front-end device as a transfer device when sending a task to the first smart front-end device fails; send a transfer request to the second smart front-end device, and The communication address of the first smart front-end device; receiving the task execution result of the first smart front-end device returned by the second smart front-end device.
实施例5Example 5
如图5所示,本发明实施例提供了一种智能网关,包括:As shown in Figure 5, an embodiment of the present invention provides an intelligent gateway, including:
分析模块501,用于在第一智能前端设备没有能力执行计算任务时,智能网关确定有能力执行所述计算任务的第二智能前端设备;The analysis module 501 is configured to determine a second smart front-end device capable of performing the computing task when the first smart front-end device is not capable of performing the computing task;
任务发送模块502,用于向所述第二智能前端设备发送所述计算任务; Task sending module 502, configured to send the computing task to the second smart front-end device;
在一种实施方式中,所述第一智能前端设备没有能力执行计算任务,包括以下任意一种:In an implementation manner, the first smart front-end device is not capable of performing computing tasks, including any one of the following:
所述第一智能前端设备的资源不足,无法完成所述计算任务;The resources of the first smart front-end device are insufficient to complete the computing task;
智能网关接收到所述第一智能前端设备的资源请求。The smart gateway receives the resource request of the first smart front-end device.
在一种实施方式中,分析模块,用于通过查询第一智能前端设备的资源状态确定所述第一智能前端设备没有能力执行所述计算任务;或者,接收到所述第一智能前端设备发送的计算资源请求时确定所述第一智能前端设备没有能力执行所述计算任务;In one embodiment, the analysis module is configured to determine that the first smart front-end device is not capable of performing the computing task by querying the resource status of the first smart front-end device; or, receiving a transmission from the first smart front-end device Determining that the first intelligent front-end device is not capable of executing the computing task when the computing resource is requested;
在智能前端设备集群中查询各个智能前端设备的资源状态,搜索资源状态满足所述计算任务要求的第二智能前端设备,将所述第二智能前端设备确定为有能力执行所述计算任务的智能前端设备。Query the resource status of each smart front-end device in the smart front-end device cluster, search for a second smart front-end device whose resource status meets the requirements of the computing task, and determine the second smart front-end device as a smart capable of executing the computing task Front-end equipment.
其中,所述资源状态包括以下至少一种:计算能力、存储能力和带宽;Wherein, the resource status includes at least one of the following: computing capacity, storage capacity and bandwidth;
在一种实施方式中,任务发送模块,还用于向第一智能前端设备发送计算任务失败时,确定作为中转设备的第二智能前端设备;向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;接收所述第二智能前端设备返回的所述第一智能前端设备的计算任务执行结果。In one embodiment, the task sending module is further configured to determine the second smart front-end device as a transfer device when sending a computing task to the first smart front-end device fails; send a transfer request and the transfer request to the second smart front-end device The communication address of the first smart front-end device; receiving the calculation task execution result of the first smart front-end device returned by the second smart front-end device.
实施例6Example 6
如图6所示,本发明实施例提供了一种智能前端设备,包括:As shown in Figure 6, an embodiment of the present invention provides an intelligent front-end device, including:
任务接收模块601,用于接收智能网关发送的任务,并从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址;The task receiving module 601 is configured to receive tasks sent by the smart gateway, and obtain the service addresses of other smart front-end devices that assist in executing the tasks from the smart gateway;
任务处理模块602,用于根据所述服务地址将所述任务转移至所述其他智能前端设备上。The task processing module 602 is configured to transfer the task to the other intelligent front-end equipment according to the service address.
在一种实施方式中,所述任务包括:计算任务、存储任务或数据恢复任务。In an embodiment, the task includes: a calculation task, a storage task, or a data recovery task.
在一种实施方式中,所述智能前端设备还包括:请求模块603,用于从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址之前,确定本设备没有能力执行所述任务,向智能网关发送资源请求。In an implementation manner, the smart front-end device further includes: a request module 603, configured to determine from the smart gateway that the device is not capable of executing the service address of other smart front-end devices that assist in executing the task. Task, send a resource request to the smart gateway.
在一种实施方式中,请求模块,用于通过查询本设备的资源状态确定本设备没有能力执行计算任务;In one embodiment, the request module is configured to determine that the device is not capable of performing computing tasks by querying the resource status of the device;
在一种实施方式中,当所述任务为存储任务时,任务处理模块,用于根据所述服务地址将需要备份或迁移的数据存储到所述其他智能前端设备上。In one embodiment, when the task is a storage task, the task processing module is configured to store data that needs to be backed up or migrated to the other smart front-end device according to the service address.
在一种实施方式中,所述智能前端设备还包括:反馈模块604,用于将需要备份或迁移的数据存储到所述其他智能前端设备上后,向智能网关返回存储任务执行结果;In an embodiment, the smart front-end device further includes: a feedback module 604, configured to store data that needs to be backed up or migrated on the other smart front-end device, and then return the storage task execution result to the smart gateway;
在一种实施方式中,当所述任务为数据恢复任务时,任务处理模块,用于根据所述服务地址从所述其他智能前端设备获取之前备份或迁移的数据。In one embodiment, when the task is a data recovery task, the task processing module is configured to obtain the previously backed up or migrated data from the other intelligent front-end device according to the service address.
在一种实施方式中,所述智能前端设备,还包括中转模块605,用于接收中转请求,所述中转请求中携带需要中转服务的智能前端设备的通信地址;与需要中转服务的智能前端设备建立通信连接;从智能网关接收任务,将所述任务转发给所述需要中转服务的智能前端设备;从需要中转服务的智能前端设备接收任务执行结果,将所述任务执行结果转发给所述智能网关。In one embodiment, the smart front-end device further includes a transfer module 605 for receiving a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service; and the smart front-end device that needs the transfer service Establish a communication connection; receive tasks from the smart gateway, and forward the tasks to the smart front-end equipment that needs transit services; receive the task execution results from the smart front-end devices that need transit services, and forward the task execution results to the smart Gateway.
实施例7Example 7
如图14所示,本发明实施例提供了一种智能网关,包括:As shown in Figure 14, an embodiment of the present invention provides an intelligent gateway, including:
存储器1401、处理器1402及存储在所述存储器1401上并可在所述处理器1402上运行的资源调度 的程序,所述资源调度的程序被所述处理器1402执行时实现上述实施例1所述的资源调度的方法的步骤。The memory 1401, the processor 1402, and a resource scheduling program that is stored on the memory 1401 and can run on the processor 1402. The resource scheduling program is executed by the processor 1402 to implement the above-mentioned embodiment 1 The steps of the resource scheduling method described.
实施例8Example 8
如图14所示,本发明实施例提供了一种智能网关,包括:As shown in Figure 14, an embodiment of the present invention provides an intelligent gateway, including:
存储器1401、处理器1402及存储在所述存储器1401上并可在所述处理器1402上运行的资源调度的程序,所述资源调度的程序被所述处理器1402执行时实现上述实施例2所述的资源调度的方法的步骤。The memory 1401, the processor 1402, and a resource scheduling program that is stored on the memory 1401 and can run on the processor 1402. The resource scheduling program is executed by the processor 1402 to implement the above-mentioned embodiment 2 The steps of the resource scheduling method described.
实施例9Example 9
如图15所示,本发明实施例提供了一种智能前端设备,包括:As shown in Figure 15, an embodiment of the present invention provides an intelligent front-end device, including:
存储器1501、处理器1502及存储在所述存储器1501上并可在所述处理器1502上运行的资源调度的程序,所述资源调度的程序被所述处理器1502执行时实现上述实施例3所述的资源调度的方法的步骤。The memory 1501, the processor 1502, and a resource scheduling program stored on the memory 1501 and running on the processor 1502, and the resource scheduling program is executed by the processor 1502 to implement the above-mentioned embodiment 3 The steps of the resource scheduling method described.
实施例10Example 10
本发明实施例提供了一种分布式系统,包括:上述智能前端设备和智能网关。The embodiment of the present invention provides a distributed system, including: the above-mentioned intelligent front-end equipment and an intelligent gateway.
实施例11Example 11
本发明实施例提供了一种计算机可读存储介质,所述计算机可读存储介质上存储有资源调度的程序,所述资源调度的程序被处理器执行时实现上述实施例1或实施例2或实施例3所述的资源调度的方法的步骤。The embodiment of the present invention provides a computer-readable storage medium, the computer-readable storage medium stores a resource scheduling program, and the resource scheduling program implements the foregoing embodiment 1 or embodiment 2 or Steps of the resource scheduling method described in embodiment 3.
下面通过一些示例说明本申请的资源调度方法和分布式系统。The following examples illustrate the resource scheduling method and distributed system of this application.
示例1Example 1
如图7所示,本示例提供一种分布式计算与存储系统,包括:智能网关(GateWay)和智能前端设备。分布式计算与存储系统可扩展性强,通过智能网关服务实现统一对外的服务接口,降低了设备的接入难度。As shown in Figure 7, this example provides a distributed computing and storage system, including: an intelligent gateway (GateWay) and an intelligent front-end device. The distributed computing and storage system is highly scalable, and realizes a unified external service interface through the intelligent gateway service, which reduces the difficulty of equipment access.
智能网关是连接智能前端设备与后台服务器(云端服务器和/或本地服务器)的枢纽,通过API(Application Programming Interface,应用程序编程接口)接口提供各种服务功能。比如:智能前端设备可以调用接口进行注册,后台服务器可以调用接口查看当前接入的智能前端设备的设备信息,智能前端设备发起计算资源的请求等。The smart gateway is the hub that connects the smart front-end device and the back-end server (cloud server and/or local server), and provides various service functions through API (Application Programming Interface) interfaces. For example, the smart front-end device can call the interface to register, the back-end server can call the interface to view the device information of the currently connected smart front-end device, and the smart front-end device initiates a request for computing resources.
智能前端设备接收来自后台服务器的指令并处理任务,并且能够通过API接口提供计算、存储与转发功能。智能前端设备可以通过有线或者无线的方式接入智能网关,智能前端设备之间主要通过智能网关进行转发消息,也可以通过无线的方式实现直连通信。The intelligent front-end equipment receives instructions from the back-end server and processes tasks, and can provide computing, storage and forwarding functions through API interfaces. Smart front-end devices can be connected to the smart gateway in a wired or wireless manner, and the smart front-end devices mainly forward messages through the smart gateway, and can also achieve direct communication in a wireless manner.
智能前端设备通过智能网关提供的注册服务接口接入系统。智能网关可以通过调用智能前端设备提供的状态查询接口查看当前设备的资源状态(包括CPU利用率,存储状态,网络利用率等),还可以通过调用能力接口获取当前设备提供的各种能力的服务地址,所述服务包括计算服务,存储服务,中转服务等。智能前端设备可以通过智能网关提供的服务获取集群内所有智能前端设备的信息,所述信息包括智能前端设备的通信地址,存储与计算能力信息。The smart front-end equipment accesses the system through the registration service interface provided by the smart gateway. The smart gateway can view the resource status of the current device (including CPU utilization, storage status, network utilization, etc.) by calling the status query interface provided by the smart front-end device, and it can also obtain services of various capabilities provided by the current device by calling the capability interface Address, the services include computing services, storage services, transit services, etc. The smart front-end device can obtain information of all smart front-end devices in the cluster through the service provided by the smart gateway. The information includes the communication address of the smart front-end device and storage and computing capability information.
示例2Example 2
本示例提供一种资源调度方法。当智能前端设备出现负荷过重,无法接收新的任务时,可以向智能网关请求计算资源,智能网关通过搜索集群内的所有智能前端设备并综合考虑设备的计算、存储与通信能力等筛选出合适的智能前端设备,然后将所述合适的智能前端设备的计算服务地址转发给请求计算资源的智能前端设备。通过智能网关转发计算资源可以防止某个智能前端设备出现任务过载的情况。This example provides a resource scheduling method. When the smart front-end equipment is overloaded and unable to receive new tasks, it can request computing resources from the smart gateway. The smart gateway searches for all smart front-end devices in the cluster and comprehensively considers the computing, storage, and communication capabilities of the equipment to select suitable ones. And then forward the computing service address of the appropriate smart front-end device to the smart front-end device requesting computing resources. Forwarding computing resources through the smart gateway can prevent a certain smart front-end device from being overloaded with tasks.
如图8所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 8, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器通过智能网关向智能前端设备A下发任务。Step S101: The background server delivers tasks to the smart front-end device A through the smart gateway.
步骤S102:智能前端设备A接收到任务后判断当前的负载是否超过阈值,超过了就向智能网关发起请求计算资源的请求;Step S102: After receiving the task, the smart front-end device A judges whether the current load exceeds the threshold, and if it exceeds the threshold, it initiates a request for computing resources to the smart gateway;
步骤S103:智能网关接收到请求后,搜索集群内的所有智能前端设备并综合考虑设备的计算、存储与通信能力等筛选出合适的智能前端设备B,然后将智能前端设备B的计算服务地址转发给智能前端设备A。Step S103: After receiving the request, the smart gateway searches for all smart front-end devices in the cluster and comprehensively considers the computing, storage, and communication capabilities of the devices to select a suitable smart front-end device B, and then forwards the computing service address of the smart front-end device B To smart front-end equipment A.
步骤S104:智能前端设备A获取到智能前端设备B的服务地址后,通过智能前端设备B提供的接口转移任务,需要时还可以将计算任务需要的数据发送给智能前端设备B。Step S104: After the smart front-end device A obtains the service address of the smart front-end device B, the task is transferred through the interface provided by the smart front-end device B, and the data required for the calculation task can be sent to the smart front-end device B when needed.
步骤S105:智能前端设备B获取到任务后进行计算,然后将计算结果通过智能网关转发给后台服务器。Step S105: The smart front-end device B performs calculation after obtaining the task, and then forwards the calculation result to the background server through the smart gateway.
示例3Example 3
本示例提供一种资源调度方法。当智能网关接收到后台服务器发送的任务时可以通过获取智能前端设备当前的资源状态判断当前设备是否有能力进行计算,如果计算能力不足时,通过搜索集群内的所有智能前端设备并综合考虑设备的计算、存储与通信能力等筛选出合适的智能前端设备,然后将任务下发给合适的智能前端设备,同时将原始智能前端设备的相关服务地址转发给新的智能前端设备,新的智能前端设备可以从原始智能前端设备获取相关数据。通过智能网关转发计算资源可以防止某个智能前端设备出现任务过载的情况。This example provides a resource scheduling method. When the smart gateway receives the task sent by the back-end server, it can determine whether the current device is capable of computing by obtaining the current resource status of the smart front-end device. If the computing power is insufficient, it searches for all smart front-end devices in the cluster and comprehensively considers the device's Computing, storage and communication capabilities, etc., screen out the appropriate smart front-end equipment, and then send the task to the appropriate smart front-end equipment, and at the same time forward the relevant service address of the original smart front-end equipment to the new smart front-end equipment, the new smart front-end equipment Relevant data can be obtained from the original smart front-end equipment. Forwarding computing resources through the smart gateway can prevent a certain smart front-end device from being overloaded with tasks.
如图9所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 9, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器通过智能网关向智能前端设备A下发任务。Step S101: The background server delivers tasks to the smart front-end device A through the smart gateway.
步骤S102:智能网关先判断设备A是否有足够的计算资源来执行任务,如果计算能力不足,则搜索计算能力满足要求的合适的智能前端设备B;其中,搜索时考虑了设备的带宽,计算以及存储能力。Step S102: The smart gateway first judges whether device A has enough computing resources to perform the task. If the computing power is insufficient, it searches for a suitable smart front-end device B with computing power that meets the requirements; among them, the bandwidth of the device is considered when searching, and the calculation and Storage capacity.
步骤S103:智能网关转发计算任务给智能前端设备B,并将智能前端设备A的相关服务地址发送给智能前端设备B。Step S103: The smart gateway forwards the calculation task to the smart front-end device B, and sends the related service address of the smart front-end device A to the smart front-end device B.
步骤S104:智能前端设备B接收到任务以及智能前端设备A的相关服务地址后进行计算。Step S104: The smart front-end device B performs calculations after receiving the task and the related service address of the smart front-end device A.
其中,智能前端设备B根据智能前端设备A的相关服务地址获得相关数据;Among them, the smart front-end device B obtains relevant data according to the relevant service address of the smart front-end device A;
比如,后台服务器发送的任务是对智能前端设备A的视频监控数据进行图像分析,由于每个智能前端设备只能获取自己监控区域内的视频数据,这时智能前端设备B就需要从智能前端设备A获取相关数据,然后再计算。For example, the task sent by the back-end server is to perform image analysis on the video surveillance data of the smart front-end device A. Since each smart front-end device can only obtain the video data in its own monitoring area, the smart front-end device B needs to obtain the video data from the smart front-end device. A get the relevant data, and then calculate.
另外,由于计算任务是多种类型的,当计算任务不需要依赖智能前端设备A中的数据时,智能网 关可以不将智能前端设备A的相关服务地址发送给智能前端设备B;当计算任务需要依赖智能前端设备A中的数据时,智能网关将智能前端设备A的相关服务地址发送给智能前端设备B,由智能前端设备B根据所述智能前端设备A的相关服务地址获取相关数据。In addition, since the computing tasks are of multiple types, when the computing task does not need to rely on the data in the smart front-end device A, the smart gateway may not send the relevant service address of the smart front-end device A to the smart front-end device B; when the computing task requires When relying on the data in the smart front-end device A, the smart gateway sends the related service address of the smart front-end device A to the smart front-end device B, and the smart front-end device B obtains the related data according to the related service address of the smart front-end device A.
步骤S105:智能前端设备B计算结束后通过智能网关转发计算结果给后台服务器。Step S105: After the calculation of the smart front-end device B is completed, the calculation result is forwarded to the back-end server through the smart gateway.
示例4Example 4
本示例提供一种资源调度方法。当后台服务器下发备份或数据迁移指令给智能前端设备A时,智能网关先判断当前智能前端设备A是否有足够的存储空间来存储数据,如果空间不够时,通过一定策略搜索出合适的智能前端设备B和C,并将搜索到的智能前端设备B和C的存储地址以及任务指令一起下发到智能前端设备A。当智能前端设备A接收到指令后将需要存储的数据均匀切片,依次通过接收到的智能前端设备B和C的存储地址转移数据。通过智能网关服务转发存储资源备份请求可以防止某个智能前端设备由于某些因素导致数据的丢失,提高了数据的可靠性。This example provides a resource scheduling method. When the back-end server issues a backup or data migration instruction to the smart front-end device A, the smart gateway first determines whether the current smart front-end device A has enough storage space to store data. If the space is not enough, it searches for a suitable smart front-end through a certain strategy Devices B and C, and send the searched storage addresses and task instructions of smart front-end devices B and C to smart front-end device A together. When the smart front-end device A receives the instruction, the data to be stored is evenly sliced, and the data is transferred through the received storage addresses of the smart front-end devices B and C in turn. Forwarding storage resource backup requests through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve data reliability.
如图10所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 10, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器通过智能网关向智能前端设备A下发备份或数据迁移任务。Step S101: The background server issues a backup or data migration task to the smart front-end device A through the smart gateway.
步骤S102:智能网关先判断当前智能前端设备A是否有足够的存储空间来存储数据,如果空间不够时,通过一定策略搜索出合适的智能前端设备(比如,智能前端设备B和C)。Step S102: The smart gateway first determines whether the current smart front-end device A has enough storage space to store data, and if the space is not enough, it searches for suitable smart front-end devices (for example, smart front-end devices B and C) through a certain strategy.
步骤S103:智能网关将智能前端设备的存储服务地址列表(B、C)以及存储指令转发给智能前端设备A。Step S103: The smart gateway forwards the storage service address list (B, C) and storage instructions of the smart front-end device to the smart front-end device A.
步骤S104:智能前端设备A获取到存储指令以及存储服务地址列表后,将需要备份或迁移的数据均匀地转移到其他智能前端设备上。Step S104: After the smart front-end device A obtains the storage instruction and the storage service address list, the data that needs to be backed up or migrated is evenly transferred to other smart front-end devices.
步骤S105:智能前端设备A将任务执行结果发送给智能网关。Step S105: The smart front-end device A sends the task execution result to the smart gateway.
其中,对于备份任务,任务执行结果包括:备份成功或备份失败;Among them, for backup tasks, task execution results include: backup success or backup failure;
对于数据迁移任务,任务执行结果包括:数据迁移成功或数据迁移失败;For data migration tasks, the task execution results include: data migration success or data migration failure;
步骤S106:智能网关存储数据关系;Step S106: the smart gateway stores the data relationship;
其中,对于备份任务,智能网关存储的数据关系是:智能前端设备A的数据备份地址为智能前端设备B和智能前端设备C;Among them, for the backup task, the data relationship stored by the smart gateway is: the data backup address of smart front-end device A is smart front-end device B and smart front-end device C;
对于数据迁移任务,智能网关存储的数据关系是:智能前端设备A的数据迁移地址为智能前端设备B和智能前端设备C;For data migration tasks, the data relationship stored by the smart gateway is: the data migration address of smart front-end device A is smart front-end device B and smart front-end device C;
步骤S107:智能网关将任务执行结果发送给后台服务器。Step S107: The smart gateway sends the task execution result to the background server.
示例5Example 5
本示例提供一种资源调度方法。当智能前端设备A出现存储空间不足,无法接收新的备份或数据迁移任务时,可以向智能网关请求存储资源,智能网关通过一定策略搜索出合适的智能前端设备B和C,然后将所述合适的智能前端设备的存储服务地址转发给请求存储资源的智能前端设备A。当智能前端设备A接收到指令后将需要存储的数据均匀切片,依次通过接收到的智能前端设备B和C的存储地址转移数据。通过智能网关服务转发存储资源备份请求可以防止某个智能前端设备由于某些因素导致数据的丢失,提高了数据的可靠性。This example provides a resource scheduling method. When the smart front-end device A has insufficient storage space and cannot receive new backup or data migration tasks, it can request storage resources from the smart gateway. The smart gateway searches for suitable smart front-end devices B and C through a certain strategy, and then determines the appropriate The storage service address of the smart front-end device is forwarded to the smart front-end device A that requests storage resources. When the smart front-end device A receives the instruction, the data to be stored is evenly sliced, and the data is transferred through the received storage addresses of the smart front-end devices B and C in turn. Forwarding storage resource backup requests through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve data reliability.
如图11所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 11, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器通过智能网关向智能前端设备A下发备份或数据迁移任务。Step S101: The background server issues a backup or data migration task to the smart front-end device A through the smart gateway.
步骤S102:智能前端设备A接收到任务后判断当前是否有足够的存储空间来存储数据,如果空间不够时向智能网关发起请求存储资源的请求;Step S102: After receiving the task, the smart front-end device A judges whether there is enough storage space to store data, and if the space is not enough, it initiates a request for storage resources to the smart gateway;
步骤S103:智能网关接收到请求后,通过一定策略搜索出合适的智能前端设备(比如,智能前端设备B和C)。Step S103: After receiving the request, the smart gateway searches for suitable smart front-end devices (for example, smart front-end devices B and C) through a certain strategy.
步骤S104:智能网关将智能前端设备的存储服务地址列表(B、C)以及存储指令转发给智能前端设备A。Step S104: The smart gateway forwards the storage service address list (B, C) and storage instructions of the smart front-end device to the smart front-end device A.
步骤S105:智能前端设备A获取到指令以及存储服务地址列表后,将需要备份或迁移的数据均匀地转移到其他智能前端设备上。Step S105: After the smart front-end device A obtains the instruction and the storage service address list, it evenly transfers the data that needs to be backed up or migrated to other smart front-end devices.
步骤S106:智能前端设备A将任务执行结果发送给智能网关。Step S106: The smart front-end device A sends the task execution result to the smart gateway.
其中,对于备份任务,任务执行结果包括:备份成功或备份失败;Among them, for backup tasks, task execution results include: backup success or backup failure;
对于数据迁移任务,任务执行结果包括:数据迁移成功或数据迁移失败;For data migration tasks, the task execution results include: data migration success or data migration failure;
步骤S107:智能网关存储数据关系;Step S107: the smart gateway stores the data relationship;
其中,对于备份任务,智能网关存储的数据关系是:智能前端设备A的数据备份地址为智能前端设备B和智能前端设备C;Among them, for the backup task, the data relationship stored by the smart gateway is: the data backup address of smart front-end device A is smart front-end device B and smart front-end device C;
对于数据迁移任务,智能网关存储的数据关系是:智能前端设备A的数据迁移地址为智能前端设备B和智能前端设备C;For data migration tasks, the data relationship stored by the smart gateway is: the data migration address of smart front-end device A is smart front-end device B and smart front-end device C;
步骤S108:智能网关将任务执行结果发送给后台服务器。Step S108: The smart gateway sends the task execution result to the background server.
示例6Example 6
本示例提供一种资源调度方法。当后台服务器下发数据恢复指令给智能前端设备A时,智能网关将之前存储的服务存储地址以及任务指令一起下发到智能前端设备A。当智能前端设备A接收到任务指令后,先判断本地是否存储有备份数据的存储地址,如果没有的话就通过网关传递的存储地址恢复数据。通过智能网关服务转发数据恢复请求可以防止某个智能前端设备由于某些因素导致数据的丢失,提高了数据的可靠性。This example provides a resource scheduling method. When the back-end server issues a data recovery instruction to the smart front-end device A, the smart gateway sends the previously stored service storage address and task instructions to the smart front-end device A together. When the smart front-end device A receives the task instruction, it first determines whether the storage address of the backup data is stored locally, and if not, it restores the data through the storage address passed by the gateway. Forwarding the data recovery request through the intelligent gateway service can prevent a certain intelligent front-end device from causing data loss due to certain factors, and improve the reliability of the data.
如图12所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 12, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器通过智能网关向智能前端设备A下发数据恢复任务。Step S101: The background server issues a data recovery task to the smart front-end device A through the smart gateway.
步骤S102:智能网关将数据恢复指令以及数据备份或迁移的服务器地址列表(智能前端设备B、C)转发给智能前端设备A。Step S102: The smart gateway forwards the data recovery instruction and the server address list (smart front-end device B, C) for data backup or migration to the smart front-end device A.
步骤S103:智能前端设备A接收到指令后先查找本地是否还存储有数据备份或迁移的服务器地址,如果没有的话就使用智能网关传递过来的地址列表。Step S103: After receiving the instruction, the smart front-end device A first searches whether the server address for data backup or migration is stored locally, and if not, it uses the address list passed by the smart gateway.
步骤S104:智能前端设备A通过地址列表恢复数据。Step S104: The smart front-end device A restores the data through the address list.
其中,智能前端设备A根据数据备份或迁移的服务器地址分别从智能前端设备B和C获取数据;Among them, smart front-end device A obtains data from smart front-end devices B and C respectively according to the server address of the data backup or migration;
步骤S105:智能前端设备A将任务执行结果通过网关转发给后台服务器。Step S105: The smart front-end device A forwards the task execution result to the back-end server through the gateway.
其中,任务执行结果是指:数据恢复成功或数据恢复失败。Among them, the task execution result refers to: data recovery success or data recovery failure.
示例7Example 7
本示例提供一种资源调度方法。当智能网关与智能前端设备失去连接时,智能网关通过一定的搜索策略(考虑其他智能前端设备与失去联系的智能前端设备之间的距离,通信能力,以及当前的资源利用率)筛选出合适的智能前端设备B,然后向智能前端设备B发起中转请求,智能前端设备B与智能前端设备A建立连接,后续所有智能前端设备A发往智能网关的消息都由智能前端设备B进行转发。当某个智能前端设备与智能网关失去连接时,可以通过集群内的其他智能前端设备中转数据,从而提高了系统的可靠性和稳定性。This example provides a resource scheduling method. When the smart gateway loses connection with the smart front-end device, the smart gateway selects the appropriate one through a certain search strategy (considering the distance between other smart front-end devices and the smart front-end device that has lost contact, communication capabilities, and current resource utilization) Smart front-end device B then initiates a transfer request to smart front-end device B, smart front-end device B establishes a connection with smart front-end device A, and all subsequent messages sent by smart front-end device A to the smart gateway are forwarded by smart front-end device B. When a smart front-end device loses connection with the smart gateway, data can be transferred through other smart front-end devices in the cluster, thereby improving the reliability and stability of the system.
如图13所示,本示例的资源调度方法,可以包括以下步骤:As shown in Figure 13, the resource scheduling method of this example may include the following steps:
步骤S101:后台服务器向某个智能前端设备(智能前端设备A)下发任务指令。Step S101: The background server issues a task instruction to a certain smart front-end device (smart front-end device A).
步骤S102:智能网关多次尝试将任务指令转发给智能前端设备A。Step S102: The smart gateway tries to forward the task instruction to the smart front-end device A for multiple times.
步骤S103:智能网关尝试与智能前端设备A通信失败后,通过一定的搜索策略搜索出最佳的中转设备(智能前端设备B)。Step S103: After the smart gateway fails to attempt to communicate with the smart front-end device A, it searches for the best transit device (the smart front-end device B) through a certain search strategy.
步骤S104:智能网关向智能前端设备B发起中转请求,并提供智能前端设备A的无线通信地址。Step S104: The smart gateway initiates a transfer request to the smart front-end device B, and provides the wireless communication address of the smart front-end device A.
步骤S105:智能前端设备B接收到中转请求后与智能前端设备A主动建立通信连接,并转发指令给智能前端设备A。Step S105: After receiving the transfer request, the smart front-end device B actively establishes a communication connection with the smart front-end device A, and forwards the instruction to the smart front-end device A.
步骤S106:智能前端设备A接收到指令后进行计算,然后将计算结果返回给智能前端设备B;Step S106: The smart front-end device A performs calculations after receiving the instruction, and then returns the calculation result to the smart front-end device B;
步骤S107:智能前端设备B通过智能网关将计算结果反馈给后台服务器。Step S107: The smart front-end device B feeds back the calculation result to the back-end server through the smart gateway.
本发明实施例提供的一种资源调度方法、智能前端设备、智能网关及分布式系统,在第一智能前端设备没有能力执行任务时,智能网关确定有能力执行所述任务的第二智能前端设备;所述智能网关向所述第一智能前端设备发送所述任务,所述任务携带所述第二智能前端设备的服务地址。本发明实施例能够提高安防系统的可靠性以及计算的稳定性。本发明实施例能够提高安防系统的可靠性以及计算、存储的稳定性。In the resource scheduling method, smart front-end equipment, smart gateway, and distributed system provided by embodiments of the present invention, when the first smart front-end device is not capable of performing a task, the smart gateway determines a second smart front-end device capable of performing the task The smart gateway sends the task to the first smart front-end device, and the task carries the service address of the second smart front-end device. The embodiment of the present invention can improve the reliability of the security system and the stability of calculation. The embodiments of the present invention can improve the reliability of the security system and the stability of calculation and storage.
本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统、装置中的功能模块/单元可以被实施为软件、固件、硬件及其适当的组合。在硬件实施方式中,在以上描述中提及的功能模块/单元之间的划分不一定对应于物理组件的划分;例如,一个物理组件可以具有多个功能,或者一个功能或步骤可以由若干物理组件合作执行。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分布在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。A person of ordinary skill in the art can understand that all or some of the steps, functional modules/units in the system, and apparatus in the methods disclosed above can be implemented as software, firmware, hardware, and appropriate combinations thereof. In hardware implementations, the division between functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may consist of several physical components. The components are executed cooperatively. Some physical components or all physical components can be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit . Such software may be distributed on a computer-readable medium, and the computer-readable medium may include a computer storage medium (or non-transitory medium) and a communication medium (or transitory medium). As is well known to those of ordinary skill in the art, the term computer storage medium includes volatile and non-volatile memory implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Flexible, removable and non-removable media. Computer storage media include but are not limited to RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cassette, tape, magnetic disk storage or other magnetic storage device, or Any other medium used to store desired information and that can be accessed by a computer. In addition, as is well known to those of ordinary skill in the art, communication media usually contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as carrier waves or other transmission mechanisms, and may include any information delivery media .
需要说明的是,本发明还可有其他多种实施例,在不背离本发明精神及其实质的情况下,熟悉本领域的技术人员可根据本发明作出各种相应的改变和变形,但这些相应的改变和变形都应属于本发明所附的权利要求的保护范围。It should be noted that the present invention can also have various other embodiments. Without departing from the spirit and essence of the present invention, those skilled in the art can make various corresponding changes and modifications according to the present invention, but these Corresponding changes and modifications should fall within the protection scope of the appended claims of the present invention.

Claims (14)

  1. 一种资源调度方法,包括:A resource scheduling method, including:
    在第一智能前端设备没有能力执行任务时,智能网关确定有能力执行所述任务的第二智能前端设备;When the first smart front-end device is not capable of performing a task, the smart gateway determines a second smart front-end device capable of performing the task;
    所述智能网关向所述第一智能前端设备发送所述任务,所述任务携带所述第二智能前端设备的服务地址。The smart gateway sends the task to the first smart front-end device, and the task carries the service address of the second smart front-end device.
  2. 如权利要求1所述的方法,其中,The method of claim 1, wherein:
    所述任务包括:计算任务、存储任务或数据恢复任务。The tasks include: computing tasks, storage tasks, or data recovery tasks.
  3. 如权利要求2所述的方法,其中,The method of claim 2, wherein:
    所述第一智能前端设备没有能力执行任务,包括以下任意一种:The first intelligent front-end device is not capable of performing tasks, including any of the following:
    所述第一智能前端设备的资源不足,无法完成所述任务;The resources of the first smart front-end device are insufficient to complete the task;
    智能网关接收到所述第一智能前端设备的资源请求;The smart gateway receives the resource request of the first smart front-end device;
    所述第一智能前端设备的数据已经备份或迁移到其他智能前端设备上。The data of the first smart front-end device has been backed up or migrated to other smart front-end devices.
  4. 如权利要求1所述的方法,还包括:The method of claim 1, further comprising:
    智能网关向第一智能前端设备发送任务失败时,确定作为中转设备的第二智能前端设备;When the smart gateway fails to send a task to the first smart front-end device, it determines the second smart front-end device as a transit device;
    所述智能网关向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;Sending, by the smart gateway, a transfer request and the communication address of the first smart front-end device to the second smart front-end device;
    所述智能网关接收所述第二智能前端设备返回的所述第一智能前端设备的任务执行结果。The smart gateway receives the task execution result of the first smart front-end device returned by the second smart front-end device.
  5. 一种资源调度方法,包括:A resource scheduling method, including:
    在第一智能前端设备没有能力执行计算任务时,智能网关确定有能力执行所述计算任务的第二智能前端设备;When the first smart front-end device is not capable of performing a computing task, the smart gateway determines a second smart front-end device capable of performing the computing task;
    所述智能网关向所述第二智能前端设备发送所述计算任务。The smart gateway sends the computing task to the second smart front-end device.
  6. 如权利要求5所述的方法,其中,The method of claim 5, wherein:
    所述第一智能前端设备没有能力执行计算任务,包括以下任意一种:The first intelligent front-end device is not capable of performing computing tasks, including any of the following:
    所述第一智能前端设备的资源不足,无法完成所述计算任务;The resources of the first smart front-end device are insufficient to complete the computing task;
    智能网关接收到所述第一智能前端设备的资源请求。The smart gateway receives the resource request of the first smart front-end device.
  7. 如权利要求5所述的方法,还包括:The method of claim 5, further comprising:
    智能网关向第一智能前端设备发送计算任务失败时,确定作为中转设备的第二智能前端设备;When the smart gateway fails to send a calculation task to the first smart front-end device, it determines the second smart front-end device as a transit device;
    所述智能网关向所述第二智能前端设备发送中转请求以及所述第一智能前端设备的通信地址;Sending, by the smart gateway, a transfer request and the communication address of the first smart front-end device to the second smart front-end device;
    所述智能网关接收所述第二智能前端设备返回的所述第一智能前端设备的计算任务执行结果。The smart gateway receives the calculation task execution result of the first smart front-end device returned by the second smart front-end device.
  8. 一种资源调度方法,包括:A resource scheduling method, including:
    智能前端设备接收智能网关发送的任务,并从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址;The smart front-end device receives the task sent by the smart gateway, and obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task;
    智能前端设备根据所述服务地址将所述任务转移至所述其他智能前端设备上。The smart front-end device transfers the task to the other smart front-end device according to the service address.
  9. 如权利要求8所述的方法,其中,The method of claim 8, wherein:
    所述任务包括:计算任务、存储任务或数据恢复任务。The tasks include: computing tasks, storage tasks, or data recovery tasks.
  10. 如权利要求8所述的方法,智能前端设备从所述智能网关获取协助执行所述任务的其他智能前端设备的服务地址之前,还包括:8. The method according to claim 8, before the smart front-end device obtains from the smart gateway the service addresses of other smart front-end devices that assist in executing the task, the method further comprises:
    智能前端设备确定本设备没有能力执行所述任务,向智能网关发送资源请求。The smart front-end device determines that the device is not capable of performing the task, and sends a resource request to the smart gateway.
  11. 如权利要求8所述的方法,还包括:The method of claim 8, further comprising:
    智能前端设备接收中转请求,所述中转请求中携带需要中转服务的智能前端设备的通信地址;The smart front-end device receives a transfer request, and the transfer request carries the communication address of the smart front-end device that needs the transfer service;
    智能前端设备与需要中转服务的智能前端设备建立通信连接;The smart front-end equipment establishes a communication connection with the smart front-end equipment that needs transit services;
    智能前端设备从智能网关接收任务,将所述任务转发给所述需要中转服务的智能前端设备;The smart front-end equipment receives tasks from the smart gateway, and forwards the tasks to the smart front-end equipment that needs a transit service;
    智能前端设备从需要中转服务的智能前端设备接收任务执行结果,将所述任务执行结果转发给所述智能网关。The smart front-end device receives the task execution result from the smart front-end device that needs the transfer service, and forwards the task execution result to the smart gateway.
  12. 一种智能网关,包括:An intelligent gateway, including:
    存储器、处理器及存储在所述存储器上并可在所述处理器上运行的资源调度程序,其中,所述资源调度程序被所述处理器执行时实现上述权利要求1-4中任一项所述的资源调度方法的步骤或者实现上述权利要求5-7中任一项所述的资源调度方法的步骤。A memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler, when executed by the processor, implements any one of the foregoing claims 1-4 The steps of the resource scheduling method or the steps of implementing the resource scheduling method of any one of claims 5-7.
  13. 一种智能前端设备,包括:An intelligent front-end equipment, including:
    存储器、处理器及存储在所述存储器上并可在所述处理器上运行的资源调度程序,其中,所述资源调度程序被所述处理器执行时实现上述权利要求8-11中任一项所述的资源调度方法的步骤。A memory, a processor, and a resource scheduler stored on the memory and capable of running on the processor, wherein the resource scheduler, when executed by the processor, implements any one of the foregoing claims 8-11 The steps of the resource scheduling method.
  14. 一种计算机可读存储介质,存储有资源调度程序,其中,所述资源调度程序被处理器执行时实现上述权利要求1-11中任一项所述的资源调度方法的步骤。A computer-readable storage medium storing a resource scheduling program, wherein when the resource scheduling program is executed by a processor, the steps of the resource scheduling method according to any one of claims 1-11 are implemented.
PCT/CN2020/103084 2019-08-22 2020-07-20 Resource scheduling method, smart front-end device, smart gateway, and distributed system WO2021031767A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910778773.5 2019-08-22
CN201910778773.5A CN112422598A (en) 2019-08-22 2019-08-22 Resource scheduling method, intelligent front-end equipment, intelligent gateway and distributed system

Publications (1)

Publication Number Publication Date
WO2021031767A1 true WO2021031767A1 (en) 2021-02-25

Family

ID=74660125

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/103084 WO2021031767A1 (en) 2019-08-22 2020-07-20 Resource scheduling method, smart front-end device, smart gateway, and distributed system

Country Status (2)

Country Link
CN (1) CN112422598A (en)
WO (1) WO2021031767A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113760303A (en) * 2021-11-10 2021-12-07 杭州安恒信息技术股份有限公司 Processing method, device and equipment of micro front-end application resource and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090248835A1 (en) * 2008-03-31 2009-10-01 Subhankar Panda Offloading data transfers between a local and remote network
CN104363300A (en) * 2014-11-26 2015-02-18 浙江宇视科技有限公司 Compute task distributed dispatching device in server cluster
US20170164237A1 (en) * 2015-12-03 2017-06-08 The Trustees Of The Stevens Institute Of Technology System Apparatus And Methods For Cognitive Cloud Offloading In A Multi-Rat Enabled Wireless Device
CN109600419A (en) * 2018-11-12 2019-04-09 南京信息工程大学 The computation migration method of car networking application is supported under a kind of mobile edge calculations environment
CN109819037A (en) * 2019-01-29 2019-05-28 武汉鸿瑞达信息技术有限公司 A kind of method and system of adaptive polo placement and communication
CN109862592A (en) * 2018-12-06 2019-06-07 北京邮电大学 Resource management and dispatching method under a kind of mobile edge calculations environment based on multi-base station cooperative

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1299482C (en) * 2003-11-13 2007-02-07 上海交通大学 Cooperating terminals for networked monitoring of industrial equipments and method for implementing coordinate access among terminals
CN104158581B (en) * 2013-05-13 2018-03-02 电信科学技术研究院 A kind of discovery method and device of via node
CN105182828B (en) * 2015-09-18 2018-09-07 深圳前海达闼科技有限公司 Method and equipment for requesting assistance by equipment and responding to request for assistance by equipment
CN106341860B (en) * 2016-08-26 2020-01-21 宇龙计算机通信科技(深圳)有限公司 Relay network connection method and related equipment
CN108234537A (en) * 2016-12-13 2018-06-29 杭州海康威视数字技术股份有限公司 A kind of data transmission method, device and distributed system
CN106843031A (en) * 2016-12-15 2017-06-13 北京光年无限科技有限公司 For the cooperative processing method and system of intelligent robot
CN109547531B (en) * 2018-10-19 2021-04-09 华为技术有限公司 Data processing method and device and computing equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090248835A1 (en) * 2008-03-31 2009-10-01 Subhankar Panda Offloading data transfers between a local and remote network
CN104363300A (en) * 2014-11-26 2015-02-18 浙江宇视科技有限公司 Compute task distributed dispatching device in server cluster
US20170164237A1 (en) * 2015-12-03 2017-06-08 The Trustees Of The Stevens Institute Of Technology System Apparatus And Methods For Cognitive Cloud Offloading In A Multi-Rat Enabled Wireless Device
CN109600419A (en) * 2018-11-12 2019-04-09 南京信息工程大学 The computation migration method of car networking application is supported under a kind of mobile edge calculations environment
CN109862592A (en) * 2018-12-06 2019-06-07 北京邮电大学 Resource management and dispatching method under a kind of mobile edge calculations environment based on multi-base station cooperative
CN109819037A (en) * 2019-01-29 2019-05-28 武汉鸿瑞达信息技术有限公司 A kind of method and system of adaptive polo placement and communication

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113760303A (en) * 2021-11-10 2021-12-07 杭州安恒信息技术股份有限公司 Processing method, device and equipment of micro front-end application resource and storage medium

Also Published As

Publication number Publication date
CN112422598A (en) 2021-02-26

Similar Documents

Publication Publication Date Title
US11159411B2 (en) Distributed testing service
WO2020147331A1 (en) Micro-service monitoring method and system
US7756888B2 (en) Method and apparatus for providing heterogeneous resources for client systems
US8484510B2 (en) Enhanced cluster failover management
US8583773B2 (en) Autonomous primary node election within a virtual input/output server cluster
US6138251A (en) Method and system for reliable remote object reference management
WO2022001173A1 (en) Satellite-ground cooperative paging method and device for satellite communication system
CN109213571B (en) Memory sharing method, container management platform and computer readable storage medium
CN113965560A (en) Data transmission method, proxy server, storage medium, and electronic device
CN106713378B (en) Method and system for providing service by multiple application servers
CN106991008B (en) Resource lock management method, related equipment and system
US10783045B2 (en) Active-active architecture for distributed ISCSI target in hyper-converged storage
US11922059B2 (en) Method and device for distributed data storage
CN112463290A (en) Method, system, apparatus and storage medium for dynamically adjusting the number of computing containers
US20080115127A1 (en) Apparatus and method for carrying out information processing by virtualization
WO2021031767A1 (en) Resource scheduling method, smart front-end device, smart gateway, and distributed system
CN114416470A (en) Cloud monitoring method, system, equipment and computer storage medium
US9547590B2 (en) Managing memory
CN112468310B (en) Streaming media cluster node management method and device and storage medium
US11153173B1 (en) Dynamically updating compute node location information in a distributed computing environment
CN109981779B (en) Service providing method, server and computer storage medium
WO2023109062A1 (en) Cloud disaster recovery system and method, electronic device, and storage medium
US8074109B1 (en) Third-party voting to select a master processor within a multi-processor computer
CN111382132A (en) Medical image data cloud storage system
CN113391759B (en) Communication method and equipment

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: 20855669

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20855669

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 20855669

Country of ref document: EP

Kind code of ref document: A1