Online scheduling method, device and equipment for balancing security and fairness

By obtaining the edge device credit rate and request rate from the cloud gateway, combined with fog device calculation characteristic data, fuzzy logic reasoning is performed to determine the target fog device, which solves the problem of low scheduling efficiency under the SDN structure and achieves a balance between security and efficiency. Enhanced system stability and resource utilization.

CN118540323APending Publication Date: 2024-08-23UNIV OF SCI & TECH OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410513870.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-26
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

Under the SDN structure, although the fog gateway can improve network security by intercepting resource requests from edge devices, the method of first detecting and then scheduling will reduce the efficiency of resource request processing. A method that ensures security while improving scheduling efficiency is urgently needed.

Method used

By obtaining the credit rate and request rate of the edge device to the fog device from the cloud gateway, fuzzy logic reasoning is performed, and the target fog device is determined by combining the computing characteristic data of the fog device and the attributes of the pending job to achieve efficient scheduling of the pending jobs.

Benefits of technology

It improves the response efficiency of the network under the fog computing structure to pending jobs, balances the security and fairness of fog devices when processing pending jobs, enhances the stability and reliability of the system, and reduces resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118540323A
    Figure CN118540323A
Patent Text Reader

Abstract

The invention provides an online scheduling method, device and equipment for balancing security and fairness, which can be applied to the field of online scheduling and the field of network security under a fog computing architecture. The method comprises the following steps: obtaining a credit rate and a request rate of an edge device corresponding to each fog node from a cloud gateway in response to a to-be-processed job received from the edge device; based on the credit rate and the request rate of each fog node, performing fuzzy logic reasoning on the security of the edge device to obtain a first reasoning result; under the condition that the first reasoning result is greater than a preset safety threshold value, performing fuzzy logic reasoning on the execution efficiency of the to-be-processed job at the fog node based on the calculation feature data of the fog node and the job attribute of the to-be-processed job to obtain a second reasoning result; determining one or more target fog nodes from the plurality of fog nodes based on the first reasoning result and the second reasoning result; and scheduling the to-be-processed job to one or more target fog nodes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of online scheduling and network security under a fog computing architecture, and in particular to an online scheduling method, device, and equipment that balances security and fairness. Background Art

[0002] In traditional networks, the control planes of network devices are distributed in various devices, and the control over the entire network is weak. Software Defined Network (SDN) uses a centralized controller to manage and control all devices in the network, thereby improving network security.

[0003] In fog computing, the network paradigm of SDN can be implemented through fog devices and gateways to improve network security. However, in the process of realizing the concept of the present disclosure, the inventors found that there are at least the following problems in the related technology: although the fog gateway under SDN has the ability to intercept resource requests from abnormal edge devices to improve network security, the method of first detecting the intercepted request and then scheduling the requested resources will reduce the processing efficiency of resource requests. Now there is an urgent need for a scheduling method under the SDN structure to improve scheduling efficiency while ensuring network security. Summary of the invention

[0004] In view of the above problems, the present disclosure provides an online scheduling method, apparatus, and device that balances security and fairness.

[0005] According to a first aspect of the present disclosure, a scheduling method is provided, comprising:

[0006] In response to receiving a pending job from an edge device, obtaining a credit rate and a request rate of the edge device corresponding to each fog device from a cloud gateway;

[0007] Based on the credit rate and request rate of the edge device corresponding to each fog device, fuzzy logic reasoning is performed on the security of the edge device to obtain a first reasoning result;

[0008] When the first inference result is greater than the preset safety threshold, based on the calculation feature data of the fog device and the job attributes of the job to be processed, fuzzy logic inference is performed on the execution efficiency of the job to be processed in the fog device to obtain a second inference result;

[0009] Based on the first and second inference results, determining one or more target fog devices from a plurality of fog devices; and

[0010] The above-mentioned pending jobs are dispatched to the above-mentioned one or more target fog devices.

[0011] According to an embodiment of the present disclosure, based on the computing feature data of the edge device corresponding to the fog device and the job attributes of the job to be processed, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed in the fog device to obtain a second reasoning result, including:

[0012] Decomposing the above-mentioned to-be-processed job into one or more to-be-processed tasks according to the dependency relationship between the multiple tasks included in the above-mentioned to-be-processed job, wherein the above-mentioned multiple to-be-processed tasks are independent of each other;

[0013] Determine the task length of each task to be processed according to the job attributes, wherein the job attributes include the task lengths of each of the multiple tasks included in the job to be processed;

[0014] Based on the above-mentioned calculation feature data and the task length of each of the above-mentioned tasks to be processed, fuzzy logic reasoning is performed on the execution efficiency of each task to be processed in the fog device to obtain a second reasoning result, wherein the above-mentioned calculation feature data includes the processor operation speed, remaining storage capacity and bandwidth of the fog device; the above-mentioned second reasoning result includes multiple efficiency reasoning results of each of the above-mentioned one or more tasks to be processed, and the above-mentioned efficiency reasoning results characterize the execution efficiency of each task to be processed in each fog device.

[0015] According to an embodiment of the present disclosure, the method of determining one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result includes:

[0016] For each task to be processed, weighted calculation is performed on the first reasoning result and multiple efficiency reasoning results corresponding to each task to be processed to obtain multiple scheduling reference values ​​corresponding to each of the multiple fog devices;

[0017] Based on the above multiple scheduling reference values, a target fog device corresponding to each task to be processed is determined from multiple fog devices.

[0018] According to an embodiment of the present disclosure, the target fog device corresponding to each task to be processed is determined from multiple fog devices based on the multiple scheduling reference values, including:

[0019] Initializing particle positions and particle velocities of a plurality of randomly generated particles, wherein the plurality of particles represent the plurality of tasks to be processed;

[0020] Initializing individual extreme values ​​of the plurality of particles based on a plurality of scheduling reference values ​​corresponding to the plurality of fog devices;

[0021] Based on the particle positions, particle velocities and individual extrema of the above-mentioned multiple particles, the initial group extrema are iteratively optimized to obtain the target group extrema; and

[0022] Based on the target group extreme value, the target fog device is determined from the multiple fog devices.

[0023] According to an embodiment of the present disclosure, the initial group extreme value is iteratively optimized based on the particle positions, particle velocities and individual extreme values ​​of the above-mentioned multiple particles to obtain the target group extreme value, including:

[0024] The following operations are performed cyclically until a preset number of iterations is reached: based on the individual extreme value of the current state and the particle positions of the plurality of particles, and the group extreme value of the current state, the particle speeds of the plurality of particles in the current state are updated to obtain the particle speeds of the plurality of particles in the next state;

[0025] Based on the respective particle velocities of the plurality of particles in the next state and the respective particle positions of the plurality of particles in the current state, the respective particle positions of the plurality of particles in the current state are updated to obtain the respective particle positions of the plurality of particles in the next state; and

[0026] When the individual extreme values ​​of each of the multiple particles in the next state are smaller than the group extreme value of the current state, the group extreme value of the next state is updated based on the individual extreme values ​​of each of the multiple particles in the next state to obtain the group extreme value of the next state, wherein, when the number of iterations represented by the current state is the preset number of iterations, the group extreme value of the next state is represented as the target group extreme value.

[0027] According to an embodiment of the present disclosure, the above-mentioned scheduling of the above-mentioned to-be-processed job to the above-mentioned one or more target fog devices includes:

[0028] Determine, based on the identifier of the task to be processed and the control flow table, a scheduling path corresponding to one or more tasks to be processed included in the job to be processed, wherein the control flow table is obtained through the cloud gateway;

[0029] According to the scheduling path corresponding to the one or more tasks to be processed, the one or more tasks to be processed included in the job to be processed are scheduled to the target fog devices corresponding to the one or more tasks to be processed.

[0030] According to an embodiment of the present disclosure, the above method further includes:

[0031] Based on the three-way handshake between the edge device and each fog device, determine the credit rate of the edge device corresponding to each fog device;

[0032] Determine the request rate of each fog device corresponding to the edge device based on the number of connection requests and the maximum request amount of the edge device in a preset time period; and

[0033] The credit rate and request rate of the edge device corresponding to each fog device are sent to the cloud gateway.

[0034] According to an embodiment of the present disclosure, the credit rate of each fog device is determined based on the three-way handshake between the edge device and each fog device, including:

[0035] The credit rate of the edge device and the fog device is determined based on the number of successful three-way handshakes between the edge device and the fog device and the number of failed three-way handshakes between the edge device and the fog device.

[0036] Another aspect of the present disclosure provides a scheduling device, characterized in that the device comprises:

[0037] A response module, configured to obtain, from the cloud gateway, a credit rate and a request rate of the edge device corresponding to each fog device in response to receiving a pending job from the edge device;

[0038] A first reasoning module is used to perform fuzzy logic reasoning on the security of the edge device based on the credit rate and request rate of the edge device corresponding to each fog device, and obtain a first reasoning result;

[0039] The second reasoning module is used to perform fuzzy logic reasoning on the execution efficiency of the job to be processed on the fog device based on the calculation feature data of the fog device and the job attributes of the job to be processed, so as to obtain a second reasoning result when the first reasoning result is greater than a preset safety threshold;

[0040] A determination module, configured to determine one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result; and

[0041] The scheduling module is used to schedule the above-mentioned pending jobs to the above-mentioned one or more target fog devices.

[0042] Another aspect of the present disclosure provides an electronic device, comprising: one or more processors; and a memory for storing one or more computer programs, wherein the one or more processors execute the one or more computer programs to implement the steps of the above method.

[0043] According to the disclosure, by obtaining the credit rate and request rate of the edge device for each fog device from the cloud gateway, the time for calculating the credit rate and request rate is saved, and the response efficiency of the network to the processing job under the fog computing structure is improved. By performing fuzzy reasoning on the credit rate and request rate, a first reasoning result is obtained. When the first reasoning result is greater than a preset security threshold, based on the calculation feature data of the fog device and the job attributes of the job to be processed, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed on the fog device to obtain a second reasoning result. Based on the first reasoning result and the second reasoning result, one or more target fog devices are determined from multiple fog devices. Since the first reasoning result characterizes the security of the job to be processed and the second reasoning result characterizes the processing efficiency of the fog device, therefore, the target fog device is determined in combination with the first reasoning result and the second reasoning result, and the task to be processed is scheduled to one or more target fog devices for processing, which can balance the security and fairness of fog devices in processing the job to be processed under fog computing, enhance the stability and reliability of the entire system, thereby reducing the waste of resources caused by security vulnerabilities or unfair resource allocation, and indirectly improve the processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] The above contents and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:

[0045] Figure 1 The application scenario diagram of the scheduling method according to the embodiment of the present disclosure is schematically shown;

[0046] Figure 2 A flowchart of a scheduling method according to an embodiment of the present disclosure is schematically shown;

[0047] Figure 3 A schematic diagram of a membership function corresponding to a first reasoning result according to an embodiment of the present disclosure is schematically shown;

[0048] Figure 4 An interaction diagram of a scheduling method according to an embodiment of the present disclosure is schematically shown;

[0049] Figure 5 A schematic diagram of a scheduling device according to an embodiment of the present disclosure is shown; and

[0050] Figure 6 A block diagram of an electronic device suitable for implementing a scheduling method according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION

[0051] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.

[0052] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "comprise", "include", etc. used herein indicate the existence of the features, steps, operations and / or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.

[0053] All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification, and should not be interpreted in an idealized or overly rigid manner.

[0054] When using expressions such as "at least one of A, B, and C, etc.", they should generally be interpreted according to the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B, and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and / or A, B, C, etc.).

[0055] In the technical solution of the present disclosure, the data involved (including but not limited to data used for analysis, stored data, displayed data, etc.) are all information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of the relevant data comply with the relevant laws, regulations and standards of the relevant countries and regions, take necessary confidentiality measures, and do not violate public order and good morals.

[0056] With the rise of the Internet of Things and the explosive growth in the number of terminal devices, traditional centralized big data processing methods can no longer meet the requirements of real-time, privacy protection, and low energy consumption. In order to solve this problem, fog computing was proposed, which uses fog devices close to users instead of remote cloud data centers to provide computing services for IoT applications. It provides tools to alleviate cloud service quality (QoS) and processes part of the computing functions at edge devices close to users. However, the computing resources on edge devices close to users are limited. Therefore, in a fog computing environment, resource management becomes particularly important, and task scheduling, as a core component of resource management, plays a vital role in fog computing. Task scheduling is used to assign tasks to fog devices to maximize resource utilization, reduce latency, and improve overall system efficiency.

[0057] The fog computing approach establishes a low-latency network interface between IoT devices, reducing response time and speeding up communication. The fog computing framework is also known as an autonomous management framework because it independently manages the network, storage, computing, and data management on different IoT nodes in the vicinity. The fog computing framework provides monitoring, analysis, processing, analysis, maintenance, distribution, distribution, and control for computing near IoT nodes, and provides storage, communication, and decision-making capabilities for end users. Many companies are often adopting the fog computing paradigm in production applications to quickly process data generated by applications such as manufacturing, transportation, smart grids, smart cities, agriculture, and healthcare.

[0058] In addition, IoT and related fog infrastructure are prone to security and privacy issues. These issues may stem from low-cost hardware and software design choices of IoT devices, such as insecure update mechanisms, outdated components, etc., or from the lack of adequate security protection of IoT devices. Currently, the main goal of malicious users has shifted from daily malware releases to exploiting the diversity and major weaknesses of the IoT environment to infect IoT services and make IoT devices and fog devices unavailable.

[0059] Infected IoT devices or fog devices may be incorporated into botnets and passively participate in attacks, for example, participating in distributed denial of service attacks to destroy target servers / services by flooding the target with a large amount of malicious Internet traffic. Because SDN provides flexible network programmability and logical centralized control functions, it can effectively detect and contain servers / services with security issues. However, the method provided by SDN, which first detects intercepted requests and then schedules the requests, will reduce the processing efficiency of resource requests. Now there is an urgent need for a scheduling method under the SDN structure to improve scheduling efficiency while ensuring network security.

[0060] An embodiment of the present disclosure provides a scheduling method, comprising: in response to receiving a pending job from an edge device, obtaining a credit rate and a request rate of the edge device corresponding to each fog device from a cloud gateway; performing fuzzy logic reasoning on the security of the edge device based on the credit rate and the request rate of the edge device corresponding to each fog device to obtain a first reasoning result; when the first reasoning result is greater than a preset security threshold, performing fuzzy logic reasoning on the execution efficiency of the pending job on the fog device based on the calculation feature data of the fog device and the job attributes of the pending job to obtain a second reasoning result; determining one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result; and scheduling the pending job to be processed to the one or more target fog devices.

[0061] Figure 1 The application scenario diagram of the scheduling method according to an embodiment of the present disclosure is schematically shown.

[0062] like Figure 1 As shown in Figure 1, the fog computing network architecture is mainly divided into three layers: cloud layer, fog layer, and device layer. The device layer includes multiple Internet of Things (IoT) devices, such as IoT sensors, IoT cars, IoT homes, IoT medical emergency, etc. IoT devices send requests to fog devices in order to benefit from the computing resources of fog devices. The fog layer consists of a group of fog devices placed at the edge of the access network. Fog devices are grouped by fog zones: when a fog device is overloaded, it can offload requests to other fog devices in the same fog zone. At the cloud layer, there are almost unlimited computing resources organized in cloud data centers and can be used to perform tasks delivered by the fog layer.

[0063] In the fog computing network architecture of the present disclosure, fog devices are clustered into virtual organizations, i.e., fog areas, and they are interconnected through cloud gateways, which are respectively regarded as SDN switches and SDN controllers in the present disclosure. The fog gateway plays a core role, and the scheduling method of the present disclosure can be implemented on the fog gateway. The fog gateway is the interface between the application program of the user device layer and the fog layer resources. The cloud gateway is the interface between the fog layer resources and the cloud layer resources. The regional centralized distributed architecture used in the fog layer and the centralized centralized architecture used in the cloud layer.

[0064] It should be understood that Figure 1 The number of IoT devices and fog devices in the figure is only for illustration. Any number of IoT devices and fog devices may be provided according to the implementation requirements.

[0065] The following will be based on Figure 1 The scene described by Figure 2 to Figure 4 The scheduling method of the disclosed embodiment is described in detail.

[0066] Figure 2The flowchart of the scheduling method according to the embodiment of the present disclosure is schematically shown.

[0067] like Figure 2 As shown, the scheduling method of this embodiment includes operations S210 to S250.

[0068] In operation S210 , in response to receiving a pending job from an edge device, a credit rate and a request rate of the edge device corresponding to each fog device are obtained from a cloud gateway.

[0069] In operation S220, fuzzy logic reasoning is performed on the security of the edge device based on the credit rate and request rate of the edge device corresponding to each fog device to obtain a first reasoning result.

[0070] In operation S230, when the first reasoning result is greater than a preset safety threshold, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed in the fog device based on the calculation feature data of the fog device and the job attributes of the job to be processed to obtain a second reasoning result.

[0071] In operation S240, one or more target fog devices are determined from the plurality of fog devices based on the first reasoning result and the second reasoning result.

[0072] In operation S250 , the job to be processed is dispatched to one or more target fog devices.

[0073] According to an embodiment of the present disclosure, the edge device may be an IoT device or a fog device. The pending job represents a job for requesting computing resources and storage resources of the fog device. The pending job may be sent to the fog device through the IoT device. When the resources of the fog device are occupied, the fog device may send the received pending job to other fog devices, and the corresponding pending job may be processed by other fog devices.

[0074] According to an embodiment of the present disclosure, the cloud gateway is an SDN controller, and the fog gateway is an SDN switch. The credit rate is used to characterize the trust probability of the edge device, and the request rate characterizes the frequency of the edge device sending requests to the fog device. The credit rate and request rate of the pending job are identified by the credit rate and request rate of the edge device. The credit rate and request rate of each fog device corresponding to the edge device are stored in the cloud gateway. When a pending job is received from the edge device, a request is sent to the cloud gateway to obtain the credit rate and request rate of the edge device corresponding to each fog device.

[0075] According to the embodiments of the present disclosure, the credit rate and request rate of the edge device corresponding to each fog device can be averaged to obtain the credit rate and request rate of the edge device, and the credit rate of the edge device can be input into the set fuzzy inference engine, and the fuzzy inference engine outputs the first defuzzified inference result. The first inference result is in the form of a numerical value, and the first inference result is used to determine whether the job to be processed is safe or dangerous.

[0076] According to an embodiment of the present disclosure, the preset safety threshold may be set based on expert experience. For example, assuming that the threshold of the first reasoning result is above [0, 1], the preset safety threshold may be set to 0.5. By comparing the size between the preset safety threshold and the first reasoning result, subsequent processing is performed when the first reasoning result is greater than the preset safety threshold. The computational feature data of the fog device may include multiple indicator data for characterizing the processor performance of the fog device, the storage performance of the memory of the fog device, and the transmission performance of the fog device.

[0077] According to an embodiment of the present disclosure, the job attribute of the job to be processed may include the number of instructions that can be executed per second required by the job to be processed. The computing feature data of the fog device and the job attribute of the job to be processed are used to perform fuzzy logic reasoning on the execution efficiency of the job to be processed on the fog device to obtain a second reasoning result.

[0078] According to an embodiment of the present disclosure, one or more target fog devices are determined from multiple fog devices based on a first reasoning result that characterizes the safety performance of the pending job and a second processing result that characterizes the processing performance of the fog device. During the calculation process, the first reasoning result and the second reasoning result can be weighted, and by comparing different weighted results, a fog device corresponding to one or more larger weighted result values ​​can be selected as a target fog device. The pending job is forwarded to one or more target fog devices, and the pending job is processed by the target fog device.

[0079] According to the embodiment of the present disclosure, by obtaining the credit rate and request rate of the edge device for each fog device from the cloud gateway, the time for calculating the credit rate and request rate is saved, and the response efficiency of the network to the processing job under the fog computing structure is improved. By performing fuzzy reasoning on the credit rate and request rate, a first reasoning result is obtained. When the first reasoning result is greater than a preset security threshold, based on the calculation feature data of the fog device and the job attributes of the job to be processed, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed on the fog device to obtain a second reasoning result. Based on the first reasoning result and the second reasoning result, one or more target fog devices are determined from multiple fog devices. Since the first reasoning result characterizes the security of the job to be processed and the second reasoning result characterizes the processing efficiency of the fog device, therefore, the target fog device is determined in combination with the first reasoning result and the second reasoning result, and the task to be processed is scheduled to one or more target fog devices for processing, which can balance the security and fairness of fog devices in processing the job to be processed under fog computing, enhance the stability and reliability of the entire system, thereby reducing the waste of resources caused by security vulnerabilities or unfair resource allocation, and indirectly improve the processing efficiency.

[0080] According to an embodiment of the present disclosure, it is determined whether the first reasoning result is less than a preset threshold value. If the first reasoning result is less than the threshold value, the pending job sent by the edge device is rejected. In actual application scenarios, it can be manifested as rejecting the request of the edge device to process the pending job. By making a preliminary judgment on the pending job sent by the edge device through the first reasoning result, it is possible to avoid attacks on other devices in the fog computing network and improve the security of the network.

[0081] Figure 3 A schematic diagram of a membership function corresponding to a first reasoning result according to an embodiment of the present disclosure is schematically shown.

[0082] According to an embodiment of the present disclosure, fuzzy rules and membership functions are required when using a fuzzy processor.

[0083] like Figure 3 As shown, Figure 3 The three membership functions are credit rate, request rate and output result. The value of the fuzzy set with low credit rate is 0.0 to 0.5, the value of the fuzzy set with high request rate is 0.5 to 1, and the value of the fuzzy set with dangerous output result is 0.0 to 0.5. The higher the credit rate, the higher the security of the edge device, and the lower the request rate, the higher the security of the edge device. The output result of dangerous indicates that the security of the edge device is low. Similarly, the output result of potential threat indicates that the security of the edge device is average, and the output result of safe indicates that the security of the edge device is relatively high.

[0084] The fuzzy rules corresponding to the first inference result are shown in Table 1 below, which shows the corresponding relationship between different credit rates, request rates and output results. For example, if the credit rate is low and the request rate is high, the result is dangerous.

[0085] Table 1

[0086] Credit Rate Request rate Output Low Low Potential threats Low middle Danger Low high Danger middle Low Safety middle middle Potential threats middle high Danger high Low Danger high middle Safety high high Potential threats

[0087] According to an embodiment of the present disclosure, based on the computing feature data of the fog device and the job attributes of the job to be processed, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed on the fog device to obtain a second reasoning result, including:

[0088] According to the dependencies between multiple tasks included in the job to be processed, the job to be processed is decomposed into one or more tasks to be processed, wherein the multiple tasks to be processed are independent of each other; the task length of each task to be processed is determined according to the job attributes, wherein the job attributes include the task lengths of each of the multiple tasks included in the job to be processed; based on the calculated feature data and the task length of each task to be processed, fuzzy logic reasoning is performed on the execution efficiency of each task to be processed in the fog device to obtain a second reasoning result, wherein the calculated feature data includes the processor operation speed, remaining storage capacity and bandwidth of the fog device; the second reasoning result includes multiple efficiency reasoning results of one or more tasks to be processed, and the efficiency reasoning result characterizes the execution efficiency of each task to be processed in each fog device.

[0089] According to an embodiment of the present disclosure, the dependency relationship between multiple tasks describes the mutual dependency and execution order between the tasks. According to the dependency relationship between multiple tasks in the pending job, the pending job is decomposed into one or more pending tasks. In the case of multiple pending tasks, the multiple pending tasks can be processed in parallel, that is, the multiple pending tasks are independent of each other.

[0090] According to an embodiment of the present disclosure, the task length represents the average number of computer instructions required to complete the task. The task length of each task in the pending job can be evaluated based on the average number of computer instructions required for historical tasks by scanning the features of the pending tasks, such as the size of the input data, the complexity of the algorithm, etc., and the task length of each task in the pending job can be determined based on the task length of each task and the task lengths of the tasks included in the pending tasks.

[0091] According to an embodiment of the present disclosure, the calculation characteristic data includes the processor operation speed, remaining storage and bandwidth of the fog device, wherein the processor operation speed can be the number of instructions executed per second by the processor of the fog device, which can be expressed in millions of instructions per second (MIPS). The remaining storage represents the storage capacity available on the fog device. The bandwidth represents the maximum data transmission rate that can be supported in the network of the fog device. The fog gateway can obtain the processor operation speed, remaining storage and bandwidth of the fog device during the communication process with the fog device.

[0092] According to an embodiment of the present disclosure, the second reasoning result includes multiple efficiency reasoning results of one or more tasks to be processed, and the efficiency reasoning results characterize the execution efficiency of each task to be processed on each fog device. The calculation feature data of the fog device and the task length of each task to be processed are input into a fuzzy processor with a preset membership function and fuzzy rules, and the fuzzy reasoning machine outputs the second reasoning result.

[0093] According to the embodiments of the present disclosure, by decomposing the to-be-processed jobs into independent to-be-processed tasks, the efficiency reasoning result of each to-be-processed task on each fog device is determined according to the computing characteristic data of the fog device and the task length of each to-be-processed task, and the tasks can be reasonably allocated according to the efficiency reasoning result of the to-be-processed tasks corresponding to each fog device, so that the load of each fog device is relatively balanced, thereby improving the stability and reliability of the fog computing architecture.

[0094] According to an embodiment of the present disclosure, based on the first reasoning result and the second reasoning result, determining one or more target fog devices from a plurality of fog devices includes:

[0095] For each task to be processed, a first inference result and multiple efficiency inference results corresponding to each task to be processed are weightedly calculated to obtain multiple scheduling reference values ​​corresponding to each of the multiple fog devices; based on the multiple scheduling reference values, a target fog device corresponding to each task to be processed is determined from the multiple fog devices.

[0096] According to the embodiments of the present disclosure, in different application scenarios, the corresponding scheduling reference value can be achieved by assigning different weights to the first reasoning result and the efficiency reasoning result. For example, in order to balance the security and processing efficiency of the tasks to be processed on the fog device, the fairness and stability of the fog computing network are improved, the probability of error in the fog computing network is reduced, and the processing efficiency of the network is indirectly improved.

[0097] According to an embodiment of the present disclosure, based on a plurality of scheduling reference values, determining a target fog device corresponding to each task to be processed from a plurality of fog devices includes:

[0098] Initialize the particle positions and particle velocities of a plurality of randomly generated particles, wherein the plurality of particles represent a plurality of tasks to be processed; initialize the individual extreme values ​​of the plurality of particles based on a plurality of scheduling reference values ​​corresponding to each of the plurality of fog devices; iteratively optimize the initial group extreme value based on the particle positions, particle velocities and individual extreme values ​​of the plurality of particles to obtain a target group extreme value; and determine a target fog device from the plurality of fog devices based on the target group extreme value.

[0099] According to an embodiment of the present disclosure, the target fog device corresponding to each task to be processed can be determined based on a multi-objective particle swarm optimization algorithm (Multi-Objective Particle Swarm Optimization, MOPSO) and multiple scheduling reference values. A particle swarm is randomly generated, and the particle swarm includes multiple particles. The position of each particle is regarded as a scheme for scheduling the task to be processed to the fog device. Each particle has a corresponding particle position and particle velocity, wherein the particle position and particle velocity determine the movement direction of the particle in the search space.

[0100] According to the embodiment of the present disclosure, since the goal of the multi-objective particle swarm optimization algorithm is to minimize the target, and the larger the scheduling reference value, the closer the fog device corresponding to the task to be processed is to the target fog device, the scheduling reference value is multiplied by -1 and used as the fitness function value in the multi-objective particle swarm optimization algorithm. Based on the particle positions, particle velocities and individual extreme values ​​of each of the multiple particles, the initial group extreme value is iteratively optimized to obtain the target group extreme value. The fitness function value can be obtained by the following formula (1):

[0101] Aggregation=((Security*α) +(Efficiency*β))*(-1) (1);

[0102] Among them, Aggregation is the fitness function value, Security is the first reasoning result, Efficiency is the efficiency reasoning result, and α and β are preset weights.

[0103] According to an embodiment of the present disclosure, the target fog node corresponding to the task to be processed is determined based on the particle position corresponding to the extreme value of the target group. The multi-objective particle swarm optimization algorithm allocates the fog device to the task to be processed according to the extreme value of the target group of the task to be processed. In the case where the correspondence between the task to be processed and the fog device obtained based on the multi-objective particle swarm algorithm is {2,3,2,1,2,3,2,1}, the first element in the set {2,3,2,1,2,3,2,1} represents that the first fog device has a better processing performance in processing the second task to be processed, and the second element represents that the second fog device has a better processing performance in processing the third task to be processed.

[0104] According to the embodiments of the present disclosure, a target fog device corresponding to each task to be processed is determined from multiple fog devices by a multi-objective particle swarm optimization algorithm, so that the target fog device corresponding to the task to be processed can be found efficiently and quickly.

[0105] According to an embodiment of the present disclosure, based on the particle positions, particle velocities and individual extrema of each of the plurality of particles, an initial group extremum is iteratively optimized to obtain a target group extremum, including:

[0106] The following operations are performed in a loop until a preset number of iterations is reached: based on the individual extreme value of the current state and the respective particle positions of the multiple particles, and the group extreme value of the current state, the particle speed of each of the multiple particles in the current state is updated to obtain the particle speed of each of the multiple particles in the next state; based on the particle speed of each of the multiple particles in the next state and the respective particle positions of the multiple particles in the current state, the particle positions of each of the multiple particles in the current state are updated to obtain the particle positions of each of the multiple particles in the next state; and when the individual extreme value of each of the multiple particles in the next state is less than the group extreme value of the current state, the group extreme value of the next state is updated based on the individual extreme value of each of the multiple particles in the next state to obtain the group extreme value of the next state, wherein, when the number of iterations represented by the current state is the preset number of iterations, the group extreme value of the next state is represented as the target group extreme value.

[0107] According to an embodiment of the present disclosure, in a multi-objective particle swarm optimization algorithm, particles are randomly initialized. The individual extreme values ​​of all particles are used to update the group extreme value. The group extreme value of the current state is compared with the individual group value of the next state to obtain a group extreme value with higher fitness. The preset number of iterations can be the product of the number of fog devices and the number of tasks to be processed.

[0108] According to an embodiment of the present disclosure, in a multi-objective particle swarm optimization algorithm, based on the individual extreme value of the current state and the particle positions of each of the multiple particles, and the group extreme value of the current state, the particle speeds of each of the multiple particles in the current state are updated to obtain the particle speeds of each of the multiple particles in the next state, which can be achieved by formula (2):

[0109]

[0110] in, is the particle velocity of particle i in the k+1th iteration, that is, the particle velocity of particle i in the next state, C1 and C2 are acceleration factors, r1 and r2 are random numbers between (0,1) used to control the randomness of particle movement in the search space, W k is the inertia weight, which represents the balance between local search and global search. Characterizes the individual extreme value of particle i in the kth iteration. Gbest is the group extreme value. i represents the index of the particle, which is used to distinguish different particles in the particle group. Usually, i ranges from 1 to the total number of particles in the particle group. k represents the number of iterations, which is used to indicate the current iteration round of the algorithm. Usually, k ranges from 1 to the total number of iterations.

[0111] According to an embodiment of the present disclosure, in a multi-objective particle swarm optimization algorithm, based on the particle velocities of each of the multiple particles in the next state and the particle positions of each of the multiple particles in the current state, the particle positions of each of the multiple particles in the current state are updated to obtain the particle positions of each of the multiple particles in the next state, which can be achieved by formula (3):

[0112]

[0113] in, is the particle position of particle i in the k+1th iteration, that is, the particle position of particle i in the next state.

[0114] According to the embodiments of the present disclosure, the method for determining the target fog device by a multi-objective particle optimization algorithm is easier to implement in terms of the amount of calculation than the method for determining the target fog device by sorting the scheduling reference value. The method for determining the target fog device by a multi-objective particle optimization algorithm mainly involves updating the particle position and particle velocity, and the update rules are relatively simple, usually only requiring simple vector operations, with a small amount of calculation and a fast convergence speed.

[0115] According to an embodiment of the present disclosure, scheduling a job to be processed to one or more target fog devices includes:

[0116] Based on the identifier of the task to be processed and the control flow table, determine the scheduling path corresponding to one or more tasks to be processed included in the job to be processed, wherein the control flow table is obtained through the cloud gateway; according to the scheduling path corresponding to the one or more tasks to be processed, schedule the one or more tasks to be processed included in the job to be processed to the target fog device corresponding to each of the one or more tasks to be processed.

[0117] According to an embodiment of the present disclosure, a control flow table is managed by a cloud gateway, and the control flow table includes a field for matching an identifier of a task to be processed, and a scheduling path corresponding to the task to be processed. The scheduling path represents a path for sending the task to be processed to a target fog device. According to the scheduling path corresponding to one or more tasks to be processed, one or more tasks to be processed included in the job to be processed are forwarded to the target fog device corresponding to each of the one or more tasks to be processed. Scheduling the tasks to be processed through the control flow table of the cloud gateway improves the flexibility of the fog computing architecture.

[0118] According to an embodiment of the present disclosure, the scheduling method further includes:

[0119] Based on the three-way handshake between the edge device and each fog device, determine the credit rate of the edge device corresponding to each fog device; based on the number of connection requests and the maximum request amount of the edge device in a preset time period, determine the request rate of the edge device corresponding to each fog device; and send the credit rate and request rate of the edge device corresponding to each fog device to the cloud gateway.

[0120] According to an embodiment of the present disclosure, based on the idea that the probability of successful connection between an edge device with a high credit rate and a fog device is much higher than that of a malicious edge device, the credit rate of the fog device is determined based on the number of connections of each fog device. Based on the idea that a malicious edge device may try to connect to the fog device multiple times in a short period of time, the request rate of the edge device corresponding to each fog device is determined.

[0121] According to an embodiment of the present disclosure, assuming that edge device A sends a data packet of the first handshake (Transmission Control Protocol Synchronize, TCP SYN) in the transmission control protocol to fog device B, and edge device A is in the working set of fog device B, a flow for the forwarding direction is installed in the fog gateway through the cloud gateway, wherein the working set represents the set that allows edge devices to connect to fog device B. Assuming that edge device A is not in the working set of fog device B, it is added to the delay queue of fog device B. Every d seconds, a connection request is forwarded through the fog gateway to request that a new connection request be moved from the delay queue to the working set of fog device B. The request count counter in the fog gateway records the number of connection attempts in a preset time period.

[0122] According to an embodiment of the present disclosure, based on the number of connection requests and the maximum request amount of the edge device in a preset time period recorded by the counter of the fog gateway, the request rate of the edge device corresponding to each fog device is determined, wherein the maximum request amount represents the maximum number of requests initiated by the same edge device received by the fog gateway within the preset time period. For example, the preset time period can be one day or one week.

[0123] According to the embodiment of the present disclosure, the credit rate and request rate of the edge device corresponding to each fog device are sent to the cloud gateway, and the cloud gateway saves the credit rate and request rate of the edge device corresponding to each fog device, thereby saving computing time and improving the response efficiency of the processing jobs under the fog computing architecture.

[0124] According to an embodiment of the present disclosure, based on the three-way handshake between the edge device and each fog device, the credit rate of each fog device is determined, including:

[0125] The credit rate between the edge device and the fog device is determined based on the number of successful three-way handshakes between the edge device and the fog device and the number of failed three-way handshakes between the edge device and the fog device.

[0126] According to an embodiment of the present disclosure, it is assumed that edge device A sends a data packet of the first handshake (Transmission Control Protocol Synchronize, TCP SYN) in the transmission control protocol to fog device B. Since there is no flow matching the data packet in fog gateway C, the fog gateway forwards the data packet to the cloud gateway. The algorithm instance on the cloud gateway forwards the data packet to fog device B through the forwarder module on fog gateway C. The recorder module adds the identifier (ID) of fog device B to the target list that edge device A attempts to contact.

[0127] According to the three-way handshake received from fog device B, the following two situations may occur: (i) edge device A completes the three-way TCP handshake process with fog device B; (ii) edge device A fails to complete the three-way TCP handshake process with fog device B. Two counters are used to record the number of times edge device A completes the three-way TCP handshake with fog device B, and the number of times edge device A fails to complete the three-way TCP handshake with fog device B. The credit rate of edge devices and fog devices is calculated by the number of times the edge devices complete the three-way handshake and the total number of attempts to complete the three-way handshake.

[0128] According to the embodiments of the present disclosure, the idea is that the probability of successful connection between non-malicious edge devices and fog devices is much higher than that of malicious edge devices. Based on the number of successful three-way handshakes between edge devices and fog devices, and the number of failed three-way handshakes between edge devices and fog devices, the credit rate of edge devices and fog devices is determined, which helps to optimize the resource utilization of the fog computing network architecture and improve the performance and efficiency of the fog computing network architecture.

[0129] Figure 4 An interaction diagram of a scheduling method according to an embodiment of the present disclosure is schematically shown.

[0130] like Figure 4 As shown in operations S401 to S402, in operation S401, the credit rate of the edge device corresponding to each fog device is determined by the three-way handshake between the edge device and each fog device recorded in the counter. Based on the number of connection requests and the maximum request amount of the edge device in a preset time period, the request rate of the edge device corresponding to each fog device is determined. In operation S402, the fog gateway sends the credit rate and request rate of the edge device corresponding to each fog device to the cloud gateway.

[0131] According to the embodiments of the present disclosure, the reliability and stability of the connection between the edge device and each fog device are reflected by the credit rate and the request rate, so that the security assessment can be analyzed from multiple dimensions, thereby improving the accuracy of the security assessment.

[0132] like Figure 4 As shown in operations S403 to S407, in operation S403, the fog gateway responds to receiving a pending job from an edge device. In operation S404, the credit rate and request rate of the edge device corresponding to each fog device are obtained from the cloud gateway. In operation S405, the fog gateway performs fuzzy logic reasoning on the security of the edge device based on the credit rate and request rate of the edge device corresponding to each fog device, and obtains a first reasoning result. In operation S406, when the first reasoning result is greater than a preset security threshold, based on the calculation feature data of the fog device and the job attributes of the pending job, fuzzy logic reasoning is performed on the execution efficiency of the pending job on the fog device to obtain a second reasoning result. In operation S407, based on the first reasoning result and the second reasoning result, one or more target fog devices are determined from multiple fog devices.

[0133] According to an embodiment of the present disclosure, the first reasoning result is obtained by processing the credit rate and the request rate based on fuzzy reasoning. Since the edge computing system may face various uncertainties, such as network delays, device failures, etc. Therefore, compared with evaluating the security of the edge device based only on a certain logical reflection, the first reasoning result obtained by processing the credit rate and the request rate through fuzzy reasoning can reduce such uncertainty, thereby improving the accuracy of the security assessment.

[0134] According to the embodiments of the present disclosure, when it is determined that the security represented by the first reasoning result meets the preset security threshold requirements, subsequent scheduling operations are performed, thereby improving the security detection efficiency of the system. The second reasoning result obtained by fuzzy reasoning processing the calculation feature data of the fog device and the job attributes of the job to be processed can reduce uncertainty, thereby improving the accuracy of the security assessment.

[0135] According to an embodiment of the present disclosure, based on the first reasoning result and the second reasoning result, one or more target fog devices are determined from multiple fog devices. By comprehensively considering the first reasoning result characterizing security and the processing efficiency characterizing the job to be processed, the resource allocation of the fog layer can be better balanced and resource waste can be avoided, thereby more fairly meeting the needs of different jobs to be processed.

[0136] like Figure 4 As shown, in operation S408, the job to be processed is scheduled to one or more target fog devices.

[0137] Based on the above scheduling method, the present disclosure also provides a scheduling device. Figure 5The device is described in detail.

[0138] Figure 5 The structural block diagram of the scheduling device according to an embodiment of the present disclosure is schematically shown.

[0139] like Figure 5 As shown, the scheduling device 500 of this embodiment includes a response module 510 , a first reasoning module 520 , a second reasoning module 530 , a determination module 540 and a scheduling module 550 .

[0140] The response module 510 is used to obtain the credit rate and request rate of each fog device corresponding to the edge device from the cloud gateway in response to receiving the pending job from the edge device. In one embodiment, the response module 510 can be used to perform the operation S210 described above, which will not be repeated here.

[0141] The first reasoning module 520 is used to perform fuzzy logic reasoning on the security of the edge device based on the credit rate and request rate of each fog device to obtain a first reasoning result. In one embodiment, the first reasoning module 520 can be used to perform the operation S220 described above, which will not be repeated here.

[0142] The second reasoning module 530 is used to perform fuzzy logic reasoning on the execution efficiency of the job to be processed on the fog device based on the calculation feature data of the fog device and the job attributes of the job to be processed, and obtain a second reasoning result when the first reasoning result is greater than the preset safety threshold. In one embodiment, the second reasoning module 530 can be used to perform the operation S230 described above, which will not be repeated here.

[0143] The first determination module 540 is used to determine one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result. In one embodiment, the determination module 540 can be used to perform the operation S240 described above, which will not be described in detail here.

[0144] The scheduling module 550 is used to schedule the pending job to one or more target fog devices. In one embodiment, the scheduling module 550 can be used to perform the operation S250 described above, which will not be described in detail here.

[0145] According to an embodiment of the present disclosure, the second reasoning module 530 includes: a task decomposition module, a length determination module, and a result determination module.

[0146] The task decomposition module is used to decompose the job to be processed into one or more tasks to be processed according to the dependency relationship between multiple tasks included in the job to be processed, wherein the multiple tasks to be processed are independent of each other.

[0147] The length determination module is used to determine the task length of each task to be processed according to the job attributes, wherein the job attributes include the task lengths of each of the multiple tasks included in the job to be processed.

[0148] The result determination module is used to perform fuzzy logic reasoning on the execution efficiency of each task to be processed on the fog device based on the calculated feature data and the task length of each task to be processed, and obtain a second reasoning result, wherein the calculated feature data includes the processor operation speed, remaining storage capacity and bandwidth of the fog device. The second reasoning result includes multiple efficiency reasoning results of one or more tasks to be processed, and the efficiency reasoning results characterize the execution efficiency of each task to be processed on each fog device.

[0149] According to an embodiment of the present disclosure, the determination module 540 includes: a reference value determination module and a target determination module.

[0150] The reference value determination module is used to perform weighted calculation on the first reasoning result and multiple efficiency reasoning results corresponding to each task to be processed, so as to obtain multiple scheduling reference values ​​corresponding to each of the multiple fog devices.

[0151] The target determination module is used to determine a target fog device corresponding to each task to be processed from multiple fog devices based on multiple scheduling reference values.

[0152] According to an embodiment of the present disclosure, the target determination unit includes: a particle initialization unit, an extreme value initialization unit, an extreme value determination unit, and a target determination unit.

[0153] The particle initialization unit is used to initialize the particle positions and particle velocities of a plurality of randomly generated particles, wherein the plurality of particles represent a plurality of tasks to be processed.

[0154] The extreme value initialization unit is used to initialize the individual extreme values ​​of the plurality of particles based on the plurality of scheduling reference values ​​corresponding to the plurality of fog devices respectively.

[0155] The extreme value determination unit is used to iteratively optimize the initial group extreme value based on the particle positions, particle velocities and individual extreme values ​​of each of the multiple particles to obtain the target group extreme value.

[0156] The target determination unit is used to determine a target fog device from a plurality of fog devices based on a target group extreme value.

[0157] According to an embodiment of the present disclosure, the extreme value determination unit includes: a speed updating subunit, a position updating subunit, and an extreme value updating subunit.

[0158] The speed update subunit is used to cyclically perform the following operations until a preset number of iterations is reached: based on the individual extreme value of the current state and the particle positions of the multiple particles, and the group extreme value of the current state, the particle speed of each of the multiple particles in the current state is updated to obtain the particle speed of each of the multiple particles in the next state.

[0159] The position updating subunit is used to update the particle positions of the multiple particles in the current state based on the particle velocities of the multiple particles in the next state and the particle positions of the multiple particles in the current state to obtain the particle positions of the multiple particles in the next state.

[0160] The extreme value updating subunit is used to update the group extreme value of the next state based on the individual extreme values ​​of the multiple particles in the next state when the individual extreme values ​​of the multiple particles in the next state are less than the group extreme value of the current state, so as to obtain the group extreme value of the next state, wherein when the number of iterations represented by the current state is a preset number of iterations, the group extreme value of the next state is represented as the target group extreme value.

[0161] According to an embodiment of the present disclosure, the scheduling module 550 includes: a path determination submodule and a scheduling submodule.

[0162] The path determination submodule is used to determine the scheduling path corresponding to one or more tasks to be processed included in the job to be processed based on the identifier of the task to be processed and the control flow table, wherein the control flow table is obtained through the cloud gateway.

[0163] The scheduling submodule is used to schedule one or more pending tasks included in the pending job to the target fog device corresponding to each of the one or more pending tasks according to the scheduling path corresponding to the one or more pending tasks.

[0164] According to an embodiment of the present disclosure, the scheduling device further includes: a second determination module, a third determination module, and a starting module.

[0165] The second determination module is used to determine the credit rate of the edge device corresponding to each fog device based on the three-way handshake situation between the edge device and each fog device.

[0166] The third determination module is used to determine the request rate of the edge device corresponding to each fog device based on the number of connection requests and the maximum request amount of the edge device in a preset time period.

[0167] The launch module is used to send the credit rate and request rate of the edge device corresponding to each fog device to the cloud gateway.

[0168] According to an embodiment of the present disclosure, the second determination module includes: a determination submodule.

[0169] The determination submodule is used to determine the credit rate of the edge device and the fog device based on the number of successful three-way handshakes between the edge device and the fog device and the number of failed three-way handshakes between the edge device and the fog device.

[0170] According to an embodiment of the present disclosure, any multiple modules among the response module 510, the first reasoning module 520, the second reasoning module 530, the determination module 540 and the scheduling module 550 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module.

[0171] According to an embodiment of the present disclosure, at least one of the response module 510, the first reasoning module 520, the second reasoning module 530, the determination module 540 and the scheduling module 550 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application-specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware and firmware or in an appropriate combination of any of them. Alternatively, at least one of the response module 510, the first reasoning module 520, the second reasoning module 530, the determination module 540 and the scheduling module 550 can be at least partially implemented as a computer program module, and when the computer program module is run, the corresponding function can be performed.

[0172] Figure 6 A block diagram of an electronic device suitable for implementing a scheduling method according to an embodiment of the present disclosure is schematically shown.

[0173] like Figure 6 As shown, the electronic device 600 according to an embodiment of the present disclosure includes a processor 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage part 608 into a random access memory (RAM) 603. The processor 601 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or a related chipset and / or a special-purpose microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 601 may also include an onboard memory for caching purposes. The processor 601 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.

[0174] In RAM 603, various programs and data required for the operation of electronic device 600 are stored. Processor 601, ROM 602 and RAM 603 are connected to each other via bus 604. Processor 601 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM 602 and / or RAM 603. It should be noted that the program can also be stored in one or more memories other than ROM 602 and RAM 603. Processor 601 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in the one or more memories.

[0175] According to an embodiment of the present disclosure, the electronic device 600 may further include an input / output (I / O) interface 605, which is also connected to the bus 604. The electronic device 600 may further include one or more of the following components connected to the input / output (I / O) interface 605: an input portion 606 including a keyboard, a mouse, etc.; an output portion 607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 608 including a hard disk, etc.; and a communication portion 609 including a network interface card such as a LAN card, a modem, etc. The communication portion 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the input / output (I / O) interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 610 as needed, so that a computer program read therefrom is installed into the storage portion 608 as needed.

[0176] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present disclosure is implemented.

[0177] According to an embodiment of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, a computer-readable storage medium may include the ROM 602 and / or RAM 603 described above and / or one or more memories other than ROM 602 and RAM 603.

[0178] The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the scheduling method provided by the embodiment of the present disclosure.

[0179] The above functions defined in the system / device of the embodiment of the present disclosure are performed when the computer program is executed by the processor 601. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.

[0180] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 609, and / or installed from a removable medium 611. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.

[0181] In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 609, and / or installed from the removable medium 611. When the computer program is executed by the processor 601, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, apparatus, module, unit, etc. described above can be implemented by a computer program module.

[0182] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages ​​include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).

[0183] The flow charts and block diagrams in the accompanying drawings illustrate the possible architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0184] It will be appreciated by those skilled in the art that the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways, even if such combinations and / or combinations are not explicitly described in the present disclosure. In particular, the features described in the various embodiments and / or claims of the present disclosure may be combined and / or combined in a variety of ways without departing from the spirit and teachings of the present disclosure. All of these combinations and / or combinations fall within the scope of the present disclosure.

[0185] The embodiments of the present disclosure are described above. However, these embodiments are only for the purpose of illustration and are not intended to limit the scope of the present disclosure. Although the embodiments are described above separately, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. The scope of the present disclosure is defined by the attached claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make various substitutions and modifications, which should all fall within the scope of the present disclosure.

Claims

1. A scheduling method, characterized in that: The method comprises: In response to receiving a pending job from an edge device, obtaining a credit rate and a request rate of the edge device corresponding to each fog device from a cloud gateway; Based on the credit rate and request rate of the edge device corresponding to each fog device, fuzzy logic reasoning is performed on the security of the edge device to obtain a first reasoning result; When the first reasoning result is greater than a preset safety threshold, based on the calculation feature data of the fog device and the job attributes of the job to be processed, fuzzy logic reasoning is performed on the execution efficiency of the job to be processed on the fog device to obtain a second reasoning result; Based on the first reasoning result and the second reasoning result, determining one or more target fog devices from a plurality of fog devices; and The to-be-processed job is dispatched to the one or more target fog devices.

2. The method according to claim 1, characterized in that The method of performing fuzzy logic reasoning on the execution efficiency of the job to be processed on the fog device based on the computing feature data of the edge device corresponding to the fog device and the job attributes of the job to be processed to obtain a second reasoning result includes: Decomposing the job to be processed into one or more tasks to be processed according to the dependency relationship between the multiple tasks included in the job to be processed, wherein the multiple tasks to be processed are independent of each other; Determine the task length of each task to be processed according to the job attributes, wherein the job attributes include the task lengths of each of the multiple tasks included in the job to be processed; Based on the calculation feature data and the task length of each task to be processed, fuzzy logic reasoning is performed on the execution efficiency of each task to be processed in the fog device to obtain a second reasoning result, wherein the calculation feature data includes the processor operation speed, remaining storage capacity and bandwidth of the fog device; the second reasoning result includes multiple efficiency reasoning results of each of the one or more tasks to be processed, and the efficiency reasoning result characterizes the execution efficiency of each task to be processed in each fog device.

3. The method according to claim 2, characterized in that The determining one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result includes: For each task to be processed, performing a weighted operation on the first reasoning result and a plurality of efficiency reasoning results corresponding to each task to be processed to obtain a plurality of scheduling reference values ​​corresponding to each of the plurality of fog devices; Based on the multiple scheduling reference values, a target fog device corresponding to each task to be processed is determined from multiple fog devices.

4. The method according to claim 3, characterized in that: The step of determining a target fog device corresponding to each task to be processed from a plurality of fog devices based on the plurality of scheduling reference values ​​comprises: Initializing particle positions and particle velocities of a plurality of randomly generated particles, wherein the plurality of particles represent the plurality of tasks to be processed; Initializing individual extreme values ​​of each of the plurality of particles based on a plurality of scheduling reference values ​​corresponding to each of the plurality of fog devices; Iteratively optimizing the initial group extremum based on the particle positions, particle velocities, and individual extremums of each of the plurality of particles to obtain a target group extremum; and Based on the target group extreme value, the target fog device is determined from the plurality of fog devices.

5. The method according to claim 3, characterized in that: The iterative optimization of the initial group extreme value based on the particle positions, particle velocities and individual extreme values ​​of each of the multiple particles to obtain the target group extreme value includes: The following operations are performed in a loop until a preset number of iterations is reached: based on the individual extreme value of the current state and the particle positions of the multiple particles, and the group extreme value of the current state, the particle speed of each of the multiple particles in the current state is updated to obtain the particle speed of each of the multiple particles in the next state; Based on the respective particle velocities of the plurality of particles in the next state and the respective particle positions of the plurality of particles in the current state, updating the respective particle positions of the plurality of particles in the current state to obtain the respective particle positions of the plurality of particles in the next state; and When the individual extreme values ​​of each of the multiple particles in the next state are smaller than the group extreme value of the current state, the group extreme value of the next state is updated based on the individual extreme values ​​of each of the multiple particles in the next state to obtain the group extreme value of the next state, wherein, when the number of iterations represented by the current state is the preset number of iterations, the group extreme value of the next state is represented as the target group extreme value.

6. The method according to claim 3, characterized in that The step of dispatching the pending job to the one or more target fog devices comprises: Determine, based on the identifier of the task to be processed and the control flow table, a scheduling path corresponding to one or more tasks to be processed included in the job to be processed, wherein the control flow table is obtained through the cloud gateway; According to the scheduling path corresponding to the one or more tasks to be processed, the one or more tasks to be processed included in the job to be processed are scheduled to the target fog devices corresponding to the one or more tasks to be processed.

7. The method according to claim 1, characterized in that The method further comprises: Determine a credit rate of the edge device corresponding to each fog device based on a three-way handshake between the edge device and each fog device; Determine the request rate of each fog device corresponding to the edge device based on the number of connection requests and the maximum request amount of the edge device in a preset time period; and The credit rate and request rate of the edge device corresponding to each fog device are sent to the cloud gateway.

8. The method according to claim 7, characterized in that The determining the credit rate of each fog device based on the three-way handshake between the edge device and each fog device includes: The credit rate between the edge device and the fog device is determined based on the number of successful three-way handshakes between the edge device and the fog device and the number of failed three-way handshakes between the edge device and the fog device.

9. A scheduling device, characterized in that: The device comprises: A response module, configured to obtain, in response to receiving a pending job from an edge device, a credit rate and a request rate of the edge device corresponding to each fog device from a cloud gateway; A first reasoning module, configured to perform fuzzy logic reasoning on the security of the edge device based on the credit rate and request rate of each fog device corresponding to the edge device, to obtain a first reasoning result; A second reasoning module is used to perform fuzzy logic reasoning on the execution efficiency of the job to be processed on the fog device based on the calculation feature data of the fog device and the job attributes of the job to be processed, so as to obtain a second reasoning result when the first reasoning result is greater than a preset safety threshold; a determination module, configured to determine one or more target fog devices from a plurality of fog devices based on the first reasoning result and the second reasoning result; and A scheduling module is used to schedule the pending job to the one or more target fog devices.

10. An electronic device comprising: one or more processors; a memory for storing one or more computer programs, The method is characterized in that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 8.