A task scheduling method, a service device, and a storage medium for a service device

By using the terminal's historical moving trajectory in the service device to fit and predict its movement trajectory and residence time, the problem of uncertainty in task scheduling in traditional methods is solved, and more efficient task scheduling and signal quality are achieved.

CN114245288BActive Publication Date: 2025-05-30CHONGQING HKC OPTOELECTRONICS TECH CO LTD +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202111274925.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-29
Publication Date
2025-05-30
Estimated Expiration
2041-10-29

AI Technical Summary

Technical Problem

There is uncertainty in the multi-user multi-task scheduling method in the traditional edge computing environment, especially in the scenario of highly mobile terminals, it is difficult to effectively schedule tasks based on instantaneous locations only.

Method used

By obtaining the historical movement trajectory of the terminal, the predicted movement trajectory is fitted, and multiple terminal tasks within the signal coverage are scheduled based on the predicted residence time.

Benefits of technology

This method can reduce the number of migrations between terminals, improve the signal quality of the terminal, reduce the load pressure of the service equipment, and improve processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114245288B_ABST
    Figure CN114245288B_ABST
Patent Text Reader

Abstract

The present application relates to the field of task scheduling for service devices, and discloses a task scheduling method, a service device, and a storage medium for service devices. The method includes: determining the predicted movement trajectories of multiple terminals within the signal coverage range; respectively determining the predicted residence times of the multiple terminals within the signal coverage range according to the predicted movement trajectories of the multiple terminals; and scheduling the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals. By the above method, the present application can reduce the number of migrations between the terminal and the service device, and improve the signal quality of the terminal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of service device task scheduling, and in particular, to a task scheduling method for service devices, a service device, and a computer-readable storage medium. Background Art

[0002] Currently, with the development of the network, the service requirements for service devices are increasing day by day. Common service devices include servers, base stations, routers, etc. Since service devices have a certain load capacity, only a specific number of tasks can be connected to the service device. Therefore, it is crucial to reasonably schedule tasks for service devices.

[0003] In service device task scheduling, the mobile edge computing method is often used. Mobile edge computing can use the radio access network to provide the services and cloud computing functions required by telecom users' IT (Internet Technology) nearby, creating a telecom-level service environment with high performance, low latency, and high bandwidth, accelerating the rapid download of various contents, services, and applications in the network, and enabling consumers to enjoy an uninterrupted high-quality network experience. Mobile edge computing effectively integrates the two technologies of wireless networks and the Internet, adds functions such as computing, storage, and processing on the wireless network side, constructs an open platform to implant applications, and opens the information interaction between the wireless network and the service server through a wireless API to integrate the wireless network and services, upgrading traditional wireless base stations to intelligent base stations. At the same time, the deployment strategy (especially the geographical location) of mobile edge computing can achieve the advantages of low latency and high bandwidth. Mobile edge computing can also obtain wireless network information and more accurate location information in real time to provide more accurate services.

[0004] However, there are still many defects in the multi-user multi-task scheduling method in the traditional edge computing environment. For example: The traditional method mainly considers using the instantaneous position of the user as the input of the model for offline offloading decisions. However, in actual situations, edge users usually have high mobility. Therefore, making decisions only based on the instantaneous position has high uncertainty. Summary of the Invention

[0005] The main technical problem to be solved by the present application is to provide a task scheduling method. This method proposes to determine the predicted movement trajectory based on the historical movement trajectory of the terminal within the signal range of the service device, obtain the predicted residence time of the terminal within the signal coverage range according to the predicted movement trajectory, and schedule multiple terminal tasks within the signal coverage range according to the predicted residence time. This method can reduce the number of migrations between terminal service devices and improve the signal quality of the terminal.

[0006] To solve the above technical problem, a technical solution adopted by the present application is: providing a task scheduling method, including:

[0007] Determine the predicted movement trajectories of multiple terminals within the signal coverage range; respectively determine the predicted residence times of the multiple terminals within the signal coverage range according to the predicted movement trajectories of the multiple terminals; schedule the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals.

[0008] Among them, determining the predicted movement trajectories of multiple terminals within the signal coverage range includes: obtaining the historical movement trajectories of the multiple terminals, where the historical movement trajectories at least include a sequence of trajectory points; fitting the sequence of trajectory points to obtain a fitting function; and determining the predicted movement trajectories of the multiple terminals within the signal coverage range according to the fitting function.

[0009] Among them, fitting the sequence of trajectory points to obtain a fitting function includes: dividing the sequence of trajectory points into a longitude sequence and a latitude sequence; respectively fitting the longitude sequence and the latitude sequence to obtain a longitude fitting function and a latitude fitting function.

[0010] Among them, determining the predicted movement trajectories of multiple terminals within the signal coverage range according to the fitting function includes: predicting the longitudes and latitudes of the multiple terminals at the next moment within the signal coverage range according to the longitude fitting function and the latitude fitting function to determine the corresponding predicted movement trajectories.

[0011] Among them, respectively determining the predicted residence times of the multiple terminals within the signal coverage range according to the predicted movement trajectories of the multiple terminals includes: determining the start times corresponding to the current positions of the multiple terminals; and respectively determining the end times corresponding to the positions where the multiple terminals leave the signal coverage range according to the predicted movement trajectories of the multiple terminals; and respectively determining the predicted residence times of the multiple terminals within the signal coverage range according to the start times and the end times.

[0012] Among them, scheduling the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals includes: determining the selection status of the tasks initiated by each terminal according to the predicted residence times of the multiple terminals, where the selection status includes selected and unselected; and scheduling the tasks initiated by the multiple terminals according to the selection status of the tasks initiated by the multiple terminals.

[0013] Among them, determining the selection status of the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals includes: sorting the tasks initiated by the multiple terminals in descending order according to the predicted residence times of the multiple terminals to form a task queue; determining that the selection status of the first set number of tasks in the task queue is selected; and determining that the selection status of the tasks other than the first set number of tasks in the task queue is unselected.

[0014] Among them, the set number is determined by the load capacity of the service device.

[0015] Among them, scheduling the tasks initiated by multiple terminals according to the selection status of the tasks initiated by the multiple terminals includes: in response to the selection status of the target task changing from unselected to selected, allocating the target task to the service device; or in response to the selection status of the target task changing from selected to unselected, unloading the target task.

[0016] Among them, the method further includes: confirming the load condition of the service device; in response to the load condition of the service device being full load, performing the step of scheduling the tasks initiated by the multiple terminals according to the predicted stay time of the multiple terminals.

[0017] Among them, the method further includes: obtaining a task allocation request for the target task initiated by the target terminal; in response to the allocation status of the target task being unallocated, determining the predicted stay time of the target terminal within the signal range of all service devices that meet the set conditions; and allocating the target task to the service device with the maximum predicted stay time.

[0018] Among them, determining the predicted stay time of the target terminal within the signal range of all service devices that meet the set conditions includes: obtaining information of all connectable and non-full-load service devices sent by the target terminal; and determining the predicted stay time of the target terminal within the signal range of all connectable and non-full-load service devices according to the service device information.

[0019] To solve the above problems, another technical solution adopted by this application is: providing a service device, including a processor and a memory coupled to the processor, where a computer program is stored in the memory, and the processor is configured to execute the computer program to implement the above method.

[0020] To solve the above problems, another technical solution adopted by this application is: providing a computer-readable storage medium, where program data is stored in the computer-readable storage medium, and when the program data is executed by a processor, it is used to implement the above method.

[0021] The beneficial effects of this application are as follows: Different from the prior art, this application provides a task scheduling method. This method determines the predicted movement trajectories of multiple terminals within the signal coverage range; determines the predicted residence times of the multiple terminals within the signal coverage range according to the predicted movement trajectories of the multiple terminals; and schedules the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals. In this way, compared with the prior art that uses the instantaneous geographical locations of terminals in mobile edge computing as the basis for task scheduling, this solution uses the predicted residence times of terminals in the area as the basis for task scheduling; since this residence time is the predicted future residence time, the tasks of terminals can be scheduled according to the long-term positions of the terminals, avoiding the problem of continuous switching between multiple service devices when the positions of terminals change frequently, thereby improving the quality of terminal signals. Further, through the pre-allocation of tasks, it also avoids the frequent processing and calculation of service devices, reduces the load pressure on service devices, and improves the processing efficiency of service devices. Description of the Drawings

[0022] In order to more clearly illustrate the technical solutions in the embodiments of this application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of this application. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings. Among them:

[0023] Figure 1 It is the first process schematic diagram of a task scheduling method for a service device provided in the first embodiment of this application;

[0024] Figure 2 It is the process schematic diagram of the method for determining the predicted movement trajectory provided in the first embodiment of this application;

[0025] Figure 3 It is the process schematic diagram of a method for determining a fitting function provided in the first embodiment of this application;

[0026] Figure 4 It is the process schematic diagram of a method for determining the residence time provided in the first embodiment of this application;

[0027] Figure 5 It is the process schematic diagram of an embodiment of a task scheduling method provided in the first embodiment of this application;

[0028] Figure 6 It is the process schematic diagram of another embodiment of a task scheduling method provided in the first embodiment of this application;

[0029] Figure 7 It is the second process schematic diagram of a task scheduling method for a service device provided in the second embodiment of this application;

[0030] Figure 8 It is the third process schematic diagram of a task scheduling method for a service device provided in the second embodiment of the present application;

[0031] Figure 9 It is the fourth process schematic diagram of a task scheduling method for a service device provided in the second embodiment of the present application;

[0032] Figure 10 It is the structural schematic diagram of an embodiment of a service device provided in the third embodiment of the present application;

[0033] Figure 11 It is the structural schematic diagram of an embodiment of a computer-readable storage medium provided in the fourth embodiment of the present application. Detailed implementation manners

[0034] Next, the technical solutions in the embodiments of the present application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present application. It can be understood that the specific embodiments described herein are only used to explain the present application, rather than limiting the present application. Additionally, it should be noted that for the sake of description, only parts related to the present application rather than all methods and processes are shown in the accompanying drawings. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of the present application.

[0035] The terms "including" and "having" in the present application and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally further include steps or units not listed, or may optionally further include other steps or units inherent to these processes, methods, products, or devices.

[0036] Referring to "embodiment" herein means that a specific feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the present application. The phrase appears in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art explicitly and implicitly understand that the embodiments described herein may be combined with other embodiments.

[0037] Embodiment 1:

[0038] Refer to Figure 1 , Figure 1 It is the first process schematic diagram of a task scheduling method for a service device provided in the first embodiment of the present application. The task scheduling method of the service device in this embodiment specifically includes steps 11 to 13:

[0039] Step 11: Determine the predicted movement trajectories of multiple terminals within the signal coverage area;

[0040] There are usually multiple terminals within the signal coverage area of the service device. Since terminals have the property of being movable, the positions of the multiple terminals are not fixed. Based on the interaction between the signal and the service device, the historical movement trajectories of each terminal can be determined, and thus the predicted movement trajectories of each terminal can be determined.

[0041] Step 12: According to the predicted movement trajectories of the multiple terminals, respectively determine the predicted residence times of the multiple terminals within the signal coverage area;

[0042] The predicted movement trajectory contains multiple location information, that is, multiple predicted trajectory points, and each trajectory corresponds to a different moment. From the predicted trajectory points, the moment when the terminal just leaves the signal coverage area of the service device can be obtained. Therefore, according to the moments when the multiple terminals leave the signal coverage area and the current moment, the predicted residence times of the multiple terminals within the signal coverage area can be determined.

[0043] Step 13: Schedule the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals.

[0044] The residence times of the multiple terminals within the signal coverage area of the above service device are different. A long residence time within the coverage area means that the terminal will not leave the signal coverage area in a short time. Therefore, the tasks of this terminal can be selected to be connected to the service device; a short residence time within the coverage area means that the terminal will leave the signal coverage area in a short time. Therefore, the service device unloads the tasks of this terminal.

[0045] Optionally, the service device may include: a server, a base station, a router, etc.

[0046] This application determines the predicted movement trajectories of multiple terminals within the signal coverage area; according to the predicted movement trajectories of the multiple terminals, respectively determine the predicted residence times of the multiple terminals within the signal coverage area; according to the predicted residence times of the multiple terminals, schedule the tasks initiated by the multiple terminals. In this way, compared with the prior art that uses the instantaneous geographical location of the terminal in mobile edge computing as the basis for task scheduling, this embodiment uses the predicted residence time of the terminal in the area as the basis for task scheduling; since this residence time is the predicted future residence time, the tasks of the terminal can be scheduled according to the long-term position of the terminal, avoiding the problem of continuous switching between multiple service devices when the position of the terminal changes frequently, thereby improving the quality of the terminal signal. Further, through the pre-allocation of tasks, it also avoids the frequent processing and calculation of the service device, reduces the load pressure on the service device, and improves the processing efficiency of the service device.

[0047] In determining the predicted movement trajectories of multiple terminals within the signal coverage area, this application proposes a method for determining the predicted movement trajectories. Refer to Figure 2 , Figure 2 which is a schematic flowchart of the method for determining the predicted movement trajectories provided in Embodiment 1 of this application. This embodiment specifically includes steps 111 to 113:

[0048] Step 111: Obtain the historical movement trajectories of multiple terminals, where the historical movement trajectories at least include a sequence of trajectory points;

[0049] When a terminal is within the signal coverage area of the service device, the terminal and the service device continuously perform information interaction, which includes geographical location information. Therefore, the service device can obtain the geographical location information of the terminal in real time. The service device obtains a trajectory point containing geographical location information every preset time and forms a historical trajectory point sequence. The historical trajectory point sequence is updated every preset time.

[0050] Optionally, the geographical location information includes: longitude information, latitude information, and altitude information.

[0051] Optionally, the service device can also obtain the historical trajectory point sequence by acquiring the historical movement trajectory points stored in the terminal. During the movement of the terminal, it will store the location information of the historical movement trajectory, which is uploaded to the service device through the interaction between the service device and the terminal, so as to obtain the historical movement trajectory points of the terminal.

[0052] Step 112: Fit the sequence of trajectory points to obtain a fitting function;

[0053] This application uses the polynomial fitting method to fit the sequence of trajectory points. Polynomial fitting is to use a polynomial expansion to fit all the observation points in a small analysis area containing several analysis grid points to obtain an objective analysis field of the observed data. The expansion coefficients are usually determined using the least squares fitting. This application uses the historical trajectory point sequence obtained by the service device and adopts the means of polynomial fitting to obtain the fitting function.

[0054] Step 113: Determine the predicted movement trajectories of multiple terminals within the signal coverage area according to the fitting function.

[0055] After obtaining the fitting function, by inputting the corresponding time, the position information corresponding to that time can be obtained, so as to predict the predicted movement trajectories of multiple terminals within the signal coverage area.

[0056] Among them, the predicted movement trajectories change continuously with the historical movement trajectories.

[0057] In fitting the sequence of trajectory points to obtain the fitting function, this application proposes a method for determining the fitting function. Refer to Figure 3 , Figure 3It is a schematic flowchart of a method for determining a fitting function provided in the first embodiment of the present application. This embodiment specifically includes steps 1121 to 1122:

[0058] Step 1121: Divide the sequence of trajectory points into a longitude sequence and a latitude sequence;

[0059] Each historical trajectory point contains longitude information and latitude information. Therefore, the longitude information in each trajectory point is combined to form a longitude sequence, and the latitude information in each trajectory point is combined to form a latitude sequence.

[0060] Step 1122: Fit the longitude sequence and the latitude sequence respectively to obtain a longitude fitting function and a latitude fitting function.

[0061] The longitude sequence and the latitude sequence do not conform to the basic function mapping relationship when mapped to the plane rectangular coordinate system. Therefore, the fitting function can be solved by using the one-to-one correspondence between time and longitude and between time and latitude.

[0062] Let the polynomial be:

[0063]

[0064] where k represents the number of historical trajectory points, m represents the order of the polynomial, and a 0 , a 1 , …, a k represent the polynomial parameters.

[0065] Substitute the longitude sequence of k points and the corresponding time of each longitude value into the polynomial to obtain:

[0066]

[0067] where x 1 , …, x k represent the times corresponding to k longitude values respectively, y 1 , …, y k represent the longitude sequence, and R 1 , …, R k represent the error sequence.

[0068] The above formula can also be expressed as:

[0069]

[0070] Use the least squares method to calculate a j (j = 0, 1, …, m) that minimizes σ, where

[0071]

[0072] The above formula can be solved by solving the matrix XA = Y, A = aj (j = 0, 1, …, m) is solved, that is, A = X -1 Y, where

[0073]

[0074] Through the above solution process, the fitting parameter A is obtained, and thus the longitude fitting function is obtained.

[0075] Similarly, by substituting the latitude sequence and the corresponding time of each latitude value into the polynomial and solving through the above steps, the latitude fitting function can be obtained.

[0076] After obtaining the longitude fitting function and the latitude fitting function, by substituting the future time value into the longitude fitting function and the latitude fitting function, the longitude and latitude corresponding to the future time can be obtained, and thus the predicted trajectory sequences of multiple terminals can be obtained.

[0077] Through the above embodiments, the historical trajectory point sequence can be divided into a longitude sequence and a latitude sequence, and the polynomial is used to fit them respectively to obtain the longitude fitting function and the latitude fitting function, so as to obtain the predicted trajectory sequence.

[0078] In determining the predicted residence time of multiple terminals within the signal coverage range according to the predicted movement trajectories of multiple terminals, the present application proposes a method for determining the residence time. Refer to Figure 4 , Figure 4 is a schematic flowchart of a method for determining the residence time provided in Embodiment 1 of the present application. This embodiment specifically includes steps 121 to 123:

[0079] Step 121: Determine the start time corresponding to the current positions of multiple terminals;

[0080] Step 122: According to the predicted movement trajectories of multiple terminals, respectively determine the end time corresponding to the positions where multiple terminals leave the signal coverage range;

[0081] According to the predicted movement trajectory points, the time corresponding to the trajectory points where multiple terminals just leave the signal coverage range can be obtained, and this time is the end time;

[0082] Step 123: According to the start time and the end time, respectively determine the predicted residence time of multiple terminals within the signal coverage range.

[0083] By subtracting the start time from the end time of multiple terminals, the predicted residence time of multiple terminals within the signal coverage range is obtained.

[0084] The longer the predicted residence time is, the less likely it is that the terminal will leave the signal coverage area. Therefore, the service device preferentially selects the task corresponding to this terminal. The shorter the predicted residence time is, the more likely it is that the terminal will leave the signal coverage area. Therefore, the service device selects the task corresponding to this terminal with a delay.

[0085] Through Embodiments 1-4, the predicted residence times of multiple terminals can be obtained, and the tasks initiated by the multiple terminals are scheduled according to the predicted residence times. Refer to Figure 5 , Figure 5 is a schematic flowchart of an embodiment of a task scheduling method provided in Embodiment 1 of this application. This embodiment specifically includes Steps 131 to 132:

[0086] Step 131: Determine the selection status of the tasks initiated by multiple terminals according to the predicted residence times of the multiple terminals. The selection status includes selected and unselected;

[0087] In the above embodiment, the predicted residence times of multiple terminals within the signal coverage area have been calculated. Each terminal may initiate one task or multiple tasks. The service device is used to determine that the selection status of each task is selected or unselected.

[0088] Step 132: Schedule the tasks initiated by multiple terminals according to the selection status of the tasks initiated by the multiple terminals.

[0089] According to the selection status of the tasks initiated by multiple terminals and the residence times of the terminals corresponding to the multiple tasks within the signal coverage area, the tasks can be sorted to form a task queue, the first preset number of tasks are selected and connected to the service device, and task scheduling is performed according to the initial status and the selected status of the tasks initiated by multiple terminals.

[0090] In the process of determining the selection status of the tasks initiated by multiple terminals according to the predicted residence times of the multiple terminals, this application also proposes a task scheduling method. Refer to Figure 6 , Figure 6 is a schematic flowchart of another embodiment of a task scheduling method provided in Embodiment 1 of this application. This embodiment specifically includes Steps 1311 to 1312:

[0091] Step 1311: Sort the tasks initiated by multiple terminals in descending order according to the predicted residence times of the multiple terminals to form a task queue;

[0092] Through Embodiment 4, the predicted residence times of multiple terminals can be obtained, and the terminals are arranged in descending order according to the predicted residence times. The number of tasks corresponding to each terminal is different, and may be one or multiple tasks. Therefore, the tasks of multiple terminals are arranged in descending order according to the predicted residence times of the corresponding terminals to form a task queue.

[0093] Step 1312: Determine that the selection status of the first set number of tasks in the task queue is selected; and determine that the selection status of the tasks other than the first set number of tasks in the task queue is not selected.

[0094] Each service device has a certain load capacity. During the task scheduling process, determine the status of the tasks in the first load capacity number of task queues with the largest predicted residence time as selected, and determine the selection status of the tasks other than the tasks in the first load capacity number of task queues as not selected, where the set number is determined by the load capacity.

[0095] Schedule the tasks initiated by multiple terminals according to the selection status of each task by the service device. If the selection status of the target task changes from not selected to selected, allocate the target task to the service device; if the selection status of the target task changes from selected to not selected, unload the target task from the service device; if the selection status of the target task remains selected all the time, do not perform any operation on the target task. The terminal tasks can be scheduled in the above manner.

[0096] Embodiment 2:

[0097] Refer to Figure 7 , Figure 7 is the second process schematic diagram of a task scheduling method for a service device provided in Embodiment 2 of the present application. This embodiment specifically includes Steps 21 to 22:

[0098] Step 21: Confirm the load condition of the service device;

[0099] Before task scheduling, detect whether the load condition of the service device is full load or not full load. Usually, when the service device is not full load, the tasks initiated by the terminal can be directly allocated. In the case where the service device is full load, it is necessary to sort the tasks initiated by multiple terminals according to the predicted residence time and then perform task scheduling.

[0100] Step 22: In response to the load condition of the service device being full load, execute the step of scheduling the tasks initiated by multiple terminals according to the predicted residence time of multiple terminals.

[0101] When the load condition of the service device is full load, since there are still many terminals within the signal coverage of the service device that are not connected to the service device, it is necessary to determine the predicted movement trajectory based on the historical movement trajectories of all terminals within the signal coverage; calculate the predicted residence time according to the predicted movement trajectory of the terminal; arrange the tasks initiated by each terminal in descending order of the predicted residence time of the corresponding terminal to obtain a task queue; determine the selection status of the tasks initiated by the first load capacity terminals as selected, and the selection status of the tasks other than those initiated by the first load capacity terminals as unselected; according to the selection status of each terminal, the service device performs task scheduling on it.

[0102] The service device re-detects every certain time interval whether the current load condition of the service device is full load, that is, whether the number of tasks allocated to the service device has reached the load capacity of the service device. If the service device is full load, it reallocates all terminal tasks within the signal coverage of the service device.

[0103] Setting the time interval has the following advantages: There is no need to frequently detect the status of the service device, saving service resources, and at the same time avoiding the jittery migration of some tasks and consuming resources; it can also migrate in advance the terminal tasks within the signal coverage of the service device that are about to go out of this coverage to a more suitable service device, and can also avoid the disconnection caused by the terminal tasks leaving the service range of the service device.

[0104] In many cases, when a terminal enters the signal coverage of a new service device or has been unloaded by other service devices, it is necessary to allocate tasks for such terminals. For this situation, please refer to Figure 8 , Figure 8 which is the third process schematic diagram of a task scheduling method for a service device provided in Embodiment 2 of the present application. This embodiment specifically includes steps 31 to 33:

[0105] Step 31: Obtain a task allocation request initiated by a target terminal for a target task;

[0106] Step 32: In response to the allocation status of the target task being unallocated, determine the predicted residence time of the target terminal within the signal ranges of all service devices that meet the set conditions;

[0107] The allocation status of the target task is unallocated, in allocation, and allocated. Among them, the allocation status of the tasks initiated by the terminals newly entering the signal coverage of the service device and the tasks initiated by the unloaded terminals is unallocated; when an unallocated task makes an allocation request and a service device responds to this request, the service device sets the status of the unallocated task to in allocation; when calculating the predicted residence time and determining the status of the terminal task as selected, the status of the task is set to allocated.

[0108] After the unassigned task issues a task assignment request, each service device within the signal coverage range that includes this terminal can calculate the predicted residence time of this terminal within the signal coverage range of each service device.

[0109] Step 33: Assign the target task to the service device with the maximum predicted residence time.

[0110] Among multiple selectable service devices, the longer the residence time, the longer the time that this service device can provide services for this task, and the more stable the connection. Therefore, the target task is assigned to the service device with the maximum predicted residence time.

[0111] During the process of determining the predicted residence time of the target terminal within the signal ranges of all service devices that meet the set conditions in response to the assignment status of the target task being unassigned, refer to Figure 9 , Figure 9 which is the fourth process schematic diagram of a task scheduling method for a service device provided in the second embodiment of this application. This embodiment specifically includes steps 321 to 322:

[0112] Step 321: Obtain information of all connectable and non-full service devices sent by the target terminal;

[0113] After the target terminal sends a task assignment request, the service device responds to this request. Determine the predicted movement trajectory of this target terminal in the responding service device. The target terminal detects all service devices that can generate information interaction, including full service devices and non-full service devices, determines all connectable and non-full service devices, and uploads the information of the service devices that meet the conditions to the responding service device.

[0114] Step 322: Determine the predicted residence time of the target terminal within the signal ranges of all connectable and non-full service devices according to the service device information.

[0115] Calculate the predicted residence time of the terminal within the signal coverage ranges of all connectable and non-full service devices on the responding service device, select the service device with the maximum predicted residence time, and return the selection result to the target terminal. The target terminal sends a task assignment request to the finally selected service device and assigns the task to this service device.

[0116] When the service device is full, after the service device schedules the task initiated by the terminal once, it enters the waiting stage. Every certain time interval, it executes again the step of scheduling the tasks initiated by multiple terminals according to the predicted residence times of multiple terminals until the service device detects the appearance of a new terminal task request, then it stops waiting and executes the step of determining the optimal service device on the responding service device according to the predicted residence times of all connectable and non-full service devices.

[0117] Embodiment 3:

[0118] Based on the above embodiments, refer to Figure 10 , Figure 10 which is a schematic structural diagram of an embodiment of a service device provided in Embodiment 3 of the present application.

[0119] The service device 100 includes a processor 110 and a memory 120. The processor 110 and the memory 120 are coupled. A computer program is stored in the memory 120, and the computer program is used to execute the above task scheduling method.

[0120] Embodiment 4:

[0121] Specifically refer to Figure 11 , Figure 11 which is a schematic structural diagram of an embodiment of a computer-readable storage medium provided in Embodiment 4 of the present application.

[0122] The computer-readable storage medium 200 includes program data 210. When the program data 210 is executed by a processor, the above task scheduling method can be implemented.

[0123] Different from the prior art, the present application proposes a task scheduling method. First, determine the predicted movement trajectories of multiple terminals within the signal coverage area; according to the predicted movement trajectories of the multiple terminals, respectively determine the predicted residence times of the multiple terminals within the signal coverage area; according to the predicted residence times of the multiple terminals, schedule the tasks initiated by the multiple terminals. The present application proposes to obtain predicted trajectory points using the historical trajectory points of the terminals, determine the predicted residence times within the signal coverage area of the service device according to the predicted trajectory points, and schedule the tasks initiated by the terminals according to the predicted residence times. This method takes into account the high mobility of the terminals and detects the load condition of the service device at regular time intervals. If it is fully loaded, the above method is used for task scheduling. Generally speaking, the present invention can overcome the deficiencies of driving terminal task scheduling according to geographical proximity, effectively improve the service rate for terminals, and effectively reduce the number of terminal migrations.

[0124] The above are only the embodiments of the present application, and do not limit the patent scope of the present application. Any equivalent structural or equivalent process transformation made using the specification and drawings of the present application, or directly or indirectly applied to other related technical fields, shall be equally included in the patent protection scope of the present application.

Claims

1. A task scheduling method for a service device, characterized in that, the method includes: Determining the predicted movement trajectories of multiple terminals within the signal coverage range; According to the predicted movement trajectories of the multiple terminals, respectively determining the predicted residence times of the multiple terminals within the signal coverage range; Confirming the load condition of the service device, and in response to the load condition of the service device being full, scheduling the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals; Wherein, the scheduling the tasks initiated by the multiple terminals according to the predicted residence times of the multiple terminals includes: Sorting the tasks initiated by the multiple terminals in descending order of the predicted residence times of the multiple terminals to form a task queue; Determining that the selection status of the first set number of tasks in the task queue is selected; and determining that the selection status of the tasks other than the first set number of tasks in the task queue is not selected; In response to the selection status of a target task changing from not selected to selected, allocating the target task to the service device; or In response to the selection status of a target task changing from selected to not selected, unloading the target task.

2. The method according to claim 1, characterized in that, the determining the predicted movement trajectories of multiple terminals within the signal coverage range includes: Obtaining the historical movement trajectories of the multiple terminals, where the historical movement trajectories at least include a sequence of trajectory points; Fitting the sequence of trajectory points to obtain a fitting function; Determining the predicted movement trajectories of multiple terminals within the signal coverage range according to the fitting function.

3. The method according to claim 2, characterized in that, the fitting the sequence of trajectory points to obtain a fitting function includes: Dividing the sequence of trajectory points into a longitude sequence and a latitude sequence; Respectively fitting the longitude sequence and the latitude sequence to obtain a longitude fitting function and a latitude fitting function; the determining the predicted movement trajectories of multiple terminals within the signal coverage range according to the fitting function includes: Predicting the longitude and latitude of multiple terminals within the signal coverage range at the next moment according to the longitude fitting function and the latitude fitting function to determine the corresponding predicted movement trajectories.

4. The method according to claim 1, characterized in that, the respectively determining the predicted residence times of the multiple terminals within the signal coverage range according to the predicted movement trajectories of the multiple terminals includes; Determining the start time corresponding to the current positions of the multiple terminals; and According to the predicted movement trajectories of the multiple terminals, respectively determining the end times corresponding to the positions where the multiple terminals leave the signal coverage range; According to the start time and the end time, respectively determining the predicted residence times of the multiple terminals within the signal coverage range.

5. The method according to claim 1, characterized in that, the method further includes: Obtaining a task allocation request for a target task initiated by a target terminal; In response to the allocation status of the target task being unallocated, determining the predicted residence time of the target terminal within the signal range of all service devices that meet the set conditions; Assign the target task to the service device with the maximum predicted residence time.

6. A service device, characterized in that the device includes a processor and a memory coupled to the processor, the memory stores a computer program, and the processor is configured to execute the computer program to implement the method according to any one of claims 1-5.

7. A computer-readable storage medium, characterized in that the computer-readable storage medium stores program data, and the program data, when executed by a processor, is used to implement the method according to any one of claims 1-5.

Citation Information

Patent Citations

  • Mobile edge network service unloading method and device

    CN113407251A