Traffic request access methods, devices, computer equipment, readable storage media, and program products
By assessing the latency sensitivity of traffic requests and classifying or forwarding them accordingly, the problem of low access accuracy in traditional access methods is solved, and efficient matching and processing of traffic requests is achieved.
Patent Information
- Application Number
- CN202510594374.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-09
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2045-05-09
AI Technical Summary
Traditional traffic request access methods cannot effectively match the processing needs of traffic requests, resulting in latency-sensitive requests not being forwarded in a timely manner or latency-insensitive requests being forwarded first, leading to low access accuracy.
By receiving traffic information from traffic requests, we assess their latency sensitivity and classify requests into appropriate queues or forward them directly to downstream clusters based on the latency assessment type, ensuring that requests match processing needs.
It improves the accuracy of traffic request access, ensures that latency-sensitive requests are processed in a timely manner, and queues latency-insensitive requests as needed, thereby improving overall processing efficiency.
Smart Images

Figure CN120128553B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of big data technology, and in particular to a traffic request access method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Technology
[0002] The model is used to provide services and products for production and application. It calls the access layer of the model through the Application Programming Interface (API), and the access layer forwards the requests for downstream clusters to process. As the model is continuously promoted and applied, the number of requests that the model needs to process is usually large. Therefore, there is an urgent need for a traffic request access method.
[0003] Currently, traditional traffic request access uses a fixed access method, which can easily lead to a mismatch between the access method and the traffic request processing requirements. Specifically, traffic requests that need to be processed as soon as possible may not be forwarded to the downstream cluster in a timely manner, while requests that do not need to be processed as soon as possible may be forwarded to the downstream cluster for processing first. In other words, the accuracy of traffic request access is low. Summary of the Invention
[0004] Therefore, it is necessary to provide a traffic request access method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the accuracy of traffic request access in response to the above-mentioned technical problems.
[0005] Firstly, this application provides a method for accessing traffic requests, including:
[0006] Receive a traffic request and obtain the traffic information of the traffic request, wherein the traffic request is used for model inference;
[0007] Based on the traffic information, the latency sensitivity of the traffic request is evaluated to obtain the latency evaluation type of the traffic request;
[0008] If the latency assessment type is a latency-insensitive type, then the traffic requests are classified according to the resource processing occupancy information of the traffic requests to obtain the classification results, and a target queue is selected from multiple preset queues based on the classification results.
[0009] The traffic request is written to the target queue, and then forwarded to the downstream cluster through the target queue;
[0010] If the latency assessment type is a latency-sensitive type, the traffic request will be forwarded to the downstream cluster.
[0011] Secondly, this application also provides a traffic request access device, comprising:
[0012] An acquisition module is used to receive traffic requests and acquire traffic information of the traffic requests, wherein the traffic requests are used for model inference;
[0013] An evaluation module is used to evaluate the latency sensitivity of the traffic request based on the traffic information, and obtain the latency evaluation type of the traffic request;
[0014] The forwarding module is configured to: if the latency assessment type is a latency-insensitive type, classify the traffic request according to the resource processing occupancy information of the traffic request, obtain a classification result, select a target queue from multiple preset queues according to the classification result, write the traffic request into the target queue, and forward the traffic request to the downstream cluster through the target queue; if the latency assessment type is a latency-sensitive type, forward the traffic request to the downstream cluster.
[0015] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:
[0016] Receive a traffic request and obtain the traffic information of the traffic request, wherein the traffic request is used for model inference;
[0017] Based on the traffic information, the latency sensitivity of the traffic request is evaluated to obtain the latency evaluation type of the traffic request;
[0018] If the latency assessment type is a latency-insensitive type, then the traffic requests are classified according to the resource processing occupancy information of the traffic requests to obtain the classification results, and a target queue is selected from multiple preset queues based on the classification results.
[0019] The traffic request is written to the target queue, and then forwarded to the downstream cluster through the target queue;
[0020] If the latency assessment type is a latency-sensitive type, the traffic request will be forwarded to the downstream cluster.
[0021] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:
[0022] Receive a traffic request and obtain the traffic information of the traffic request, wherein the traffic request is used for model inference;
[0023] Based on the traffic information, the latency sensitivity of the traffic request is evaluated to obtain the latency evaluation type of the traffic request;
[0024] If the latency assessment type is a latency-insensitive type, then the traffic requests are classified according to the resource processing occupancy information of the traffic requests to obtain the classification results, and a target queue is selected from multiple preset queues based on the classification results.
[0025] The traffic request is written to the target queue, and then forwarded to the downstream cluster through the target queue;
[0026] If the latency assessment type is a latency-sensitive type, the traffic request will be forwarded to the downstream cluster.
[0027] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps:
[0028] Receive a traffic request and obtain the traffic information of the traffic request, wherein the traffic request is used for model inference;
[0029] Based on the traffic information, the latency sensitivity of the traffic request is evaluated to obtain the latency evaluation type of the traffic request;
[0030] If the latency assessment type is a latency-insensitive type, then the traffic requests are classified according to the resource processing occupancy information of the traffic requests to obtain the classification results, and a target queue is selected from multiple preset queues based on the classification results.
[0031] The traffic request is written to the target queue, and then forwarded to the downstream cluster through the target queue;
[0032] If the latency assessment type is a latency-sensitive type, the traffic request will be forwarded to the downstream cluster.
[0033] The aforementioned traffic request access method, apparatus, computer device, computer-readable storage medium, and computer program product receive traffic requests and obtain traffic information of the traffic requests, wherein the traffic requests are used for model inference; based on the traffic information, the latency sensitivity of the traffic requests is evaluated to obtain a latency evaluation type of the traffic requests; if the latency evaluation type includes a latency-sensitive type, the traffic requests are forwarded to a downstream cluster; if the latency evaluation type includes a latency-insensitive type, the traffic requests are queued to obtain a request queuing result for the traffic requests, and the traffic requests are forwarded to a downstream cluster according to the request queuing result.
[0034] Thus, based on traffic information, the latency sensitivity of traffic requests is first assessed. Then, based on the latency assessment type that can characterize latency sensitivity, the traffic requests are forwarded in a corresponding manner. Specifically, for latency-sensitive types, the requests are directly forwarded to the downstream cluster so that the downstream cluster can process the traffic requests in a timely manner. For latency-insensitive types, the traffic requests are first written to a target queue, and then forwarded to the downstream cluster through the target queue. This ensures that the access method corresponding to the traffic request matches the traffic request processing requirements, thereby improving the accuracy of traffic request access. Attached Figure Description
[0035] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0036] Figure 1 This is an application environment diagram of a traffic request access method in one embodiment;
[0037] Figure 2 This is a flowchart illustrating a traffic request access method in one embodiment;
[0038] Figure 3 This is a flowchart illustrating the steps of evaluating the latency sensitivity of a traffic request based on traffic information to obtain the latency evaluation type of the traffic request in one embodiment.
[0039] Figure 4 This is a flowchart illustrating the steps of classifying traffic requests based on resource processing occupancy information in one embodiment to obtain classification results.
[0040] Figure 5 This is a flowchart illustrating the step of selecting a target queue from multiple preset queues based on classification results in one embodiment.
[0041] Figure 6 This is a structural block diagram of a traffic request access device in one embodiment;
[0042] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0043] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0044] It should be noted that the information (e.g., traffic information, resource processing usage information, queue resource allocation information, preset request rate limiting conditions, and queued requests) and data (including but not limited to data used for analysis, stored data, and displayed data) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the acquisition, transmission, storage, use, and processing of the relevant data comply with the relevant provisions of national laws and regulations. Users can refuse or easily refuse content pushes (e.g., classification results, latency assessment types, and queue write status). In the embodiments of this application, certain existing industry solutions such as software, components, and models may be mentioned. These should be considered exemplary, and their purpose is merely to illustrate the feasibility of implementing the technical solution of this application, but does not mean that the applicant has already used or necessarily used such a solution.
[0045] The traffic request access method provided in this application embodiment can be applied to, for example, Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104 or placed on a cloud or other network server. Server 104 receives traffic requests and obtains the traffic information of the requests, where the traffic requests are used for model inference. Based on the traffic information, the latency sensitivity of the traffic requests is evaluated to obtain a latency evaluation type. If the latency evaluation type is latency-insensitive, the traffic requests are classified according to their resource processing occupancy information to obtain a classification result. Based on the classification result, a target queue is selected from multiple preset queues. The traffic requests are written to the target queue and forwarded to the downstream cluster through the target queue. If the latency evaluation type is latency-sensitive, the traffic requests are forwarded to the downstream cluster. Terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, projection devices, etc. Portable wearable devices can include smartwatches, smart bracelets, and head-mounted displays. Head-mounted displays can be virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc. Server 104 can be a standalone physical server, a server cluster or distributed system consisting of multiple physical servers, or a cloud server providing cloud computing services.
[0046] In one exemplary embodiment, such as Figure 2As shown, a traffic request access method is provided, which can be applied to... Figure 1 Taking server 104 as an example, the explanation includes the following steps 202 to 210. Wherein:
[0047] Step 202: Receive traffic requests and obtain traffic information of the traffic requests, wherein the traffic requests are used for model inference.
[0048] In step 202, the traffic request can be sent by either the client or the terminal; there is no restriction on this.
[0049] Traffic information includes at least one of the following: user feedback traffic information, request size information, traffic request association information, and traffic request business information.
[0050] Step 204: Based on the traffic information, assess the latency sensitivity of the traffic request to obtain the latency assessment type of the traffic request.
[0051] For example, step 204 includes: evaluating the latency sensitivity of the traffic request based on at least one of user feedback traffic information, request size information, traffic request association information, and traffic request business information, to obtain the latency evaluation type of the traffic request.
[0052] It is understandable that user feedback traffic information can, to some extent, reveal the urgency of the user's traffic request processing requirements; request size information can, to some extent, determine the processing time of the traffic request; traffic request correlation information can, to some extent, reflect the degree of correlation between the traffic request and other traffic requests; and traffic request business information can, to some extent, reflect the degree of correlation between the traffic request and business processing.
[0053] In this way, by taking at least one of the following as the basis: user feedback traffic information, request size information, traffic request association information, and traffic request business information, the latency sensitivity of traffic requests can be evaluated to obtain the latency evaluation type of traffic requests. Thus, the latency sensitivity of traffic requests can be quantified from at least one of the above dimensions to obtain the latency evaluation type, thereby ensuring the accuracy of the latency evaluation type.
[0054] Step 206: If the latency assessment type is latency-insensitive, then classify the traffic requests according to the resource processing occupancy information of the traffic requests, obtain the classification results, and select the target queue from multiple preset queues according to the classification results.
[0055] For example, classifying traffic requests based on their resource processing usage information to obtain classification results includes: determining the resource processing usage information of traffic requests based on their request size information, classifying the traffic requests based on their resource processing usage information, and obtaining classification results.
[0056] The queue resources allocated to multiple preset queues may be the same or different. Therefore, the dequeue duration information corresponding to multiple preset queues may be the same or different.
[0057] It is understandable that when distributing queue resources evenly across multiple preset queues, a target queue can be randomly selected from these preset queues. However, since the initial classification of traffic requests was based solely on whether they were latency-sensitive, this classification was rather extreme. There might be a traffic request whose latency sensitivity did not reach the latency-sensitive level, but was close to it. However, because queue resources were not distributed on demand across multiple preset queues, this traffic request could not be expedited, resulting in low accuracy in traffic request access.
[0058] Therefore, multiple preset queues need to be set such that at least two preset queues have the same allocated queue resources.
[0059] This ensures more refined queue selection for traffic requests, thereby improving the accuracy of traffic request access.
[0060] For example, selecting a target queue from multiple preset queues based on the classification results includes: obtaining queue information of multiple preset queues, wherein the queue information includes at least one of queue resource allocation information and queued requests; for each preset queue, evaluating the time required for the last queued request to be dequeued in the preset queue based on the queue information of the preset queue, and obtaining the dequeue time information of the preset queue; and selecting a target queue whose dequeue time information matches the classification results from the multiple preset queues.
[0061] Step 208: Write the traffic request to the target queue, and then forward the traffic request to the downstream cluster through the target queue.
[0062] As one embodiment, writing a traffic request to a target queue includes: serializing the traffic request to obtain a serialized request, wherein the request format of the serialized request matches a preset queue, such as JSON (JavaScript Object Notation) format, XML (eXtensible Markup Language) format, etc.; and writing the serialized request to the target queue.
[0063] Step 210: If the latency assessment type is latency-sensitive, then forward the traffic request to the downstream cluster.
[0064] It is understandable that, before forwarding traffic requests to the downstream cluster, since no rate limiting is applied to the traffic requests, the downstream cluster may be unable to operate normally after the traffic requests are forwarded, thus affecting the processing of requests that are being processed by the downstream cluster, as well as the processing of traffic requests waiting to be forwarded to the downstream cluster.
[0065] Optionally, if the latency assessment type includes a latency-sensitive type, then forwarding the traffic request to the downstream cluster includes: if the latency assessment type includes a latency-sensitive type, obtaining a preset request rate limiting condition, wherein the preset request rate limiting condition includes at least one of a request quantity rate limiting condition, a request size rate limiting condition, and a request latency rate limiting condition; if it is detected that the traffic request corresponds to a request quantity rate limiting condition, then terminating the traffic request forwarding process; if it is detected that the traffic request corresponds to a request quantity rate limiting condition, then terminating the traffic request forwarding process if the traffic request corresponds to a request size rate limiting condition, or if the traffic request corresponds to a request latency rate limiting condition; if the traffic request corresponds to a request size rate limiting condition and also does not meet the request latency rate limiting condition, then forwarding the traffic request to the downstream cluster.
[0066] Among them, the request size rate limiting condition is used to characterize the restriction condition of the traffic request size; the request latency rate limiting condition is implemented on a minute-level dimension, and the request latency rate limiting condition is implemented with a time window.
[0067] Therefore, considering that the latency assessment type includes latency-sensitive types, the traffic request is directly forwarded to the downstream cluster. Thus, before directly forwarding the traffic request to the downstream cluster, the traffic request is first checked in three dimensions: latency, number of requests, and request size. Only after all three dimensions pass the check is the traffic request forwarded to the downstream cluster. If any of the three dimensions fails the check, the traffic request forwarding process is terminated.
[0068] Considering that the verification complexity of the three dimensions—latency, number of requests, and request size—is ordered from smallest to largest as follows: number of requests, latency, and request size, performing verification in the order of the above-mentioned verification complexity can improve the efficiency of rate limiting verification to a certain extent.
[0069] Optionally, before forwarding the traffic request to the downstream cluster via the target queue, the method further includes: if it is detected that the traffic request meets the request quantity rate limiting condition, then terminating the forwarding process of the traffic request; if it is detected that the traffic request does not meet the request quantity rate limiting condition, then executing the step of forwarding the traffic request to the downstream cluster via the target queue.
[0070] Therefore, considering that there is a waiting process after writing traffic requests to the target queue, we do not perform checks on the latency and request size of traffic requests, but only perform rate limiting checks on the number of requests. This avoids unnecessary checks and improves the efficiency of checks.
[0071] Understandably, the current access layer does not differentiate between application programming interfaces, which can easily lead to situations where data between multiple models is not interconnected or synchronized.
[0072] Optionally, after receiving a traffic request, the method further includes: extracting the data portion of the traffic request, querying custom fields from the data portion, and generating a request tag for the traffic request based on the custom fields to distinguish the traffic request; and synchronizing metadata with the access layer based on the request tag through the access layer's management interface.
[0073] This allows data to be exchanged and synchronized between multiple models.
[0074] In the above-described traffic request access method, the latency sensitivity of traffic requests is first assessed based on traffic information. Then, based on the latency assessment type that can characterize the latency sensitivity, the traffic requests are forwarded in a corresponding manner. Specifically, for latency-sensitive types, the requests are directly forwarded to the downstream cluster so that the downstream cluster can process the traffic requests in a timely manner. For latency-insensitive types, the traffic requests are first written to a target queue, and then forwarded to the downstream cluster through the target queue. This ensures that the access method corresponding to the traffic request matches the traffic request processing requirements, thus improving the accuracy of traffic request access.
[0075] In one exemplary embodiment, such as Figure 3 As shown, a method for accurately assessing the latency sensitivity of traffic requests is provided. Based on traffic information, the latency sensitivity of traffic requests is assessed to obtain the latency assessment type of the traffic requests, including steps 302 to 308. Wherein:
[0076] Step 302: Based on the user-reported traffic information, evaluate the latency of the traffic request to obtain latency information.
[0077] In step 302, the user feedback traffic information is used to characterize the urgency of the user's traffic request processing, and the user feedback traffic information can be identified from the field part of the traffic request.
[0078] As an example, step 302 includes: assessing the urgency of the user's processing requirement for the traffic request based on the user's feedback traffic information to obtain processing requirement information; and assessing the time delay of the traffic request based on the processing requirement information to obtain time delay information.
[0079] Among them, the higher the urgency of the processing requirement represented by the processing requirement information, the greater the time extension represented by the time extension information obtained from the evaluation.
[0080] Optionally, based on user-reported traffic information, the method further includes: identifying processing descriptors in the field portion of the traffic request and determining the processing descriptors as user-reported traffic information, such as modifiers like "immediately" and "now," and time adverbs like "before noon today" and "before tomorrow."
[0081] Among them, the faster the processing time represented by the processing descriptor, the higher the urgency of the processing requirement represented by the processing requirement information.
[0082] Step 304: Based on the traffic request association information, evaluate the correlation between the traffic request and each processed traffic request to obtain the traffic association information.
[0083] In step 304, the traffic request association information can be determined by the similarity of the fields between the traffic request and each processed traffic request. The processed traffic request refers to the traffic request that has been forwarded to the downstream cluster and processed by the downstream cluster.
[0084] As an example, step 304 includes: evaluating the proportion of field similarity between each traffic request and each processed traffic request based on the traffic request association information; evaluating the association between each traffic request and each processed traffic request based on the proportion of field similarity between each traffic request and each processed traffic request to obtain traffic association information.
[0085] The greater the proportion of similar fields between traffic requests and processed traffic requests, the higher the correlation between the traffic requests and processed traffic requests represented by the evaluated traffic association information.
[0086] As one embodiment, based on the traffic request association information, the proportion of field similarity between each traffic request and each processed traffic request is evaluated, including: obtaining the total field length of the traffic request; locating the field similarity between each traffic request and each processed traffic request based on the traffic request association information to obtain similar fields; and determining the ratio between the field length of each similar field and the total field length as the proportion of field similarity between each traffic request and each processed traffic request.
[0087] In this way, by using the proportion of similar fields, the correlation between traffic requests and each processed traffic request is quantified, thereby improving the accuracy of the assessment of the correlation between traffic requests and each processed traffic request.
[0088] As one embodiment, the correlation between a traffic request and each processed traffic request is evaluated based on the proportion of similarity between the traffic request and each processed traffic request in the fields, to obtain traffic correlation information. This includes: summing the correlations between the traffic request and each processed traffic request based on the proportion of similarity between the traffic request and each processed traffic request in the fields, and determining the sum of correlations as traffic correlation information; and / or, filtering related requests that are related to the traffic request from each processed traffic request based on the proportion of similarity between the traffic request and each processed traffic request in the fields, and determining the total number of related requests as traffic correlation information.
[0089] Step 306: Based on the traffic request service information, assess the importance of traffic requests to the corresponding services to obtain traffic importance information.
[0090] In step 306, the traffic request service information includes information related to the corresponding service. Specifically, the fields in the traffic request field section that are related to the service are identified as traffic request service information.
[0091] As an example, step 306 includes: determining the correlation between the traffic request and the corresponding service based on the field content of the traffic request service information, wherein the correlation determination method includes, but is not limited to: chi-square test, covariance determination method, linear correlation coefficient (Pearson correlation coefficient) method, Spearman rank correlation coefficient, Kendall rank correlation coefficient, and multiple linear regression method; and evaluating the importance of the traffic request to the corresponding service based on the correlation between the traffic request and the corresponding service to obtain traffic importance information, wherein the higher the correlation between the traffic request and the corresponding service, the higher the importance of the traffic request to the corresponding service represented by the traffic importance information.
[0092] In this way, by quantifying the importance of traffic requests to the corresponding business by comparing the correlation between traffic requests and the business they correspond to, the accuracy of the assessment of the importance of traffic requests to the business they correspond to is improved.
[0093] Step 308: Based on latency information, traffic association information, and traffic importance information, assess the latency sensitivity of traffic requests to obtain the latency assessment type of traffic requests.
[0094] For example, step 308 includes: assigning forwarding priorities to traffic requests based on latency information, traffic association information, and traffic importance information; and evaluating the latency sensitivity of traffic requests based on the forwarding priorities to obtain the latency evaluation type of the traffic requests.
[0095] Among them, the shorter the time delay represented by the delay information, the higher the forwarding priority assigned; the higher the sum of the correlations between the traffic request and each processed traffic request represented by the traffic association information, the higher the forwarding priority assigned; or, the more processed traffic requests associated with the traffic request represented by the traffic association information, the higher the forwarding priority assigned; the higher the importance of the traffic request to the corresponding service represented by the traffic importance information, the higher the forwarding priority assigned.
[0096] Furthermore, based on latency information, traffic association information, and traffic importance information, forwarding priorities are assigned to traffic requests, including: weighting the latency information according to a first weight to obtain latency-weighted information; weighting the traffic association information according to a second weight to obtain traffic association-weighted information; and weighting the traffic importance information according to a third weight to obtain traffic importance-weighted information. The first, second, and third weights can be set as needed, and their sum is 1. The latency-weighted information, traffic association-weighted information, and traffic importance-weighted information are then merged to obtain the forwarding priority.
[0097] It is understandable that, since the resources of the downstream cluster are limited, there may be situations where traffic requests are forwarded with a high priority, but due to excessive resource consumption in the downstream cluster or excessive resource consumption for processing traffic requests, the requests cannot be processed in a timely manner. If the above situations are not considered, the downstream cluster may experience lag, resulting in inaccurate traffic request access.
[0098] As one embodiment, the latency sensitivity of traffic requests is evaluated based on forwarding priority to obtain the latency evaluation type of the traffic requests. This includes: if the forwarding priority meets a preset priority condition, obtaining the remaining resource information of the downstream cluster and the resource processing occupancy information of the traffic requests; if the resource processing occupancy information matches the remaining resource information, the latency-sensitive type is determined as the latency evaluation type of the traffic requests; if the resource processing occupancy information does not match the remaining resource information, the latency-insensitive type is determined as the latency evaluation type of the traffic requests; if the forwarding priority does not meet the preset priority condition, the latency-insensitive type is determined as the latency evaluation type of the traffic requests.
[0099] The preset priority condition can be higher than a preset priority threshold, which can be set as needed. Resource processing occupancy information represents the resource status required to process traffic requests. This information is determined by the request size; the larger the request size, the more resources are required to process it. Remaining resource information represents the remaining resources available to the downstream cluster.
[0100] Furthermore, the method also includes: determining that the resource processing occupancy information and the remaining resource information do not match when the amount of resources required to process the traffic request, as represented by the resource processing occupancy information, exceeds the amount of remaining resources, as represented by the remaining resource information; and determining that the resource processing occupancy information and the remaining resource information match when the amount of resources required to process the traffic request, as represented by the resource processing occupancy information, does not exceed the amount of remaining resources, as represented by the remaining resource information.
[0101] Thus, considering the possibility that a traffic request might have a high forwarding priority, but cannot be processed in a timely manner due to excessive resource consumption in the downstream cluster or excessive resource consumption for traffic request processing, a matching judgment is made between resource consumption information and remaining resource information after the forwarding priority meets the preset priority condition. Therefore, when it is expected that the downstream cluster can process the traffic request normally, the latency-sensitive type is determined as the latency evaluation type of the traffic request; when it is expected that the downstream cluster cannot process the traffic request normally, the latency-insensitive type is determined as the latency evaluation type of the traffic request. This ensures that the downstream cluster can always process traffic requests normally and improves the accuracy of traffic request access.
[0102] In this embodiment, by using latency information (which characterizes the latency of a traffic request), traffic association information (which characterizes the correlation between a traffic request and each processed traffic request), and traffic importance information (which characterizes the importance of a traffic request to the corresponding service) as the evaluation criteria for the latency sensitivity of a traffic request, the latency sensitivity of a traffic request can be evaluated from the above three dimensions. This results in a latency evaluation type obtained based on a richer set of dimensions, thus improving the accuracy of the latency sensitivity evaluation of traffic requests.
[0103] In one exemplary embodiment, such as Figure 4 As shown, to provide an accurate method for classifying traffic requests, traffic requests are classified based on their resource processing occupancy information, resulting in classification results including steps 402 to 406. Wherein:
[0104] Step 402: Generate a priority coefficient for forwarding priority based on the resource processing occupancy information of the traffic request.
[0105] In step 402, the smaller the amount of resources required to process the traffic request, the higher the priority coefficient of the generated forwarding priority.
[0106] Step 404: Update the forwarding priority according to the priority coefficient to obtain the updated priority.
[0107] The update methods in step 404 include, but are not limited to, addition and multiplication.
[0108] As an example, step 404 includes: determining the update priority by multiplying the priority coefficient by the forwarding priority.
[0109] In another embodiment, step 404 includes: determining the update priority by summing the priority coefficient and the forwarding priority.
[0110] Step 406: Classify traffic requests according to update priority to obtain classification results.
[0111] In step 406, the classification result is used to characterize the dequeue priority of traffic requests. Specifically, the higher the update priority, the higher the dequeue priority represented by the classification result.
[0112] As an example, step 406 includes: obtaining each preset dequeue priority; determining the target dequeue priority that is closest to the update priority among the preset dequeue priorities as the classification result. The preset dequeue priorities can be set by the user as needed, or they can correspond to the queue resource allocation information. Specifically, the number of different allocated resource amounts corresponding to the queue resource allocation information is consistent with the number of preset dequeue priorities, and the larger the allocated resource amount corresponding to the resource allocation information, the higher the corresponding preset dequeue priority.
[0113] In this embodiment, considering that the smaller the amount of resources required to process a traffic request, as indicated by the resource processing occupancy information, the shorter the processing time, the faster the target queue can write the next request after the traffic request is written to it. Therefore, the resource processing occupancy information is used as the basis for generating the priority coefficient, and the forwarding priority is updated through the priority coefficient. This ensures that the updated priority reflects both the forwarding priority obtained from the above-mentioned multiple dimensions and the processing time required for the traffic request. Since the updated priority is the basis for classifying traffic requests, the accuracy of traffic request classification is improved.
[0114] In one exemplary embodiment, such as Figure 5 As shown, to provide an accurate method for selecting the target queue corresponding to a traffic request from a preset queue, selecting the target queue from multiple preset queues based on the classification results includes steps 502 to 508. Wherein:
[0115] Step 502: Obtain queue resource allocation information and queued requests for multiple preset queues.
[0116] In step 502, the queue resource allocation information is used to characterize the amount of resources allocated to each preset queue; the queued requests are used to characterize at least one of the number of queued requests and the amount of resources required to process each queued request.
[0117] Step 504: For each preset queue, the queuing rate of the preset queue is evaluated based on the queue resource allocation information of the preset queue to obtain the queuing rate information of the preset queue.
[0118] In step 504, the higher the amount of resources allocated to a preset queue represented by the queue resource allocation information, the faster the queuing rate of the preset queue represented by the evaluated queuing rate information.
[0119] As one embodiment, step 504 includes: obtaining a normal rate; generating a rate coefficient corresponding to a preset queue based on the queue resource allocation information of the preset queue, wherein the higher the amount of resources allocated to the preset queue as represented by the queue resource allocation information, the higher the rate coefficient corresponding to the preset queue is; adjusting the normal rate based on the rate coefficient to obtain the queuing rate information of the preset queue, wherein the rate adjustment method includes, but is not limited to, rate addition and rate multiplication, specifically: determining the queuing rate information of the preset queue by multiplying the rate coefficient and the normal rate; or, determining the queuing rate information of the preset queue by summing the rate coefficient and the normal rate.
[0120] Step 506: Based on the queued requests and queuing rate information of the preset queue, evaluate the dequeue time of the queued requests in the preset queue to obtain the dequeue time information of the preset queue.
[0121] For example, step 506 includes: evaluating the processing workload corresponding to the preset queue based on the queued requests to obtain processing workload information; and evaluating the dequeue duration of the queued requests based on the processing workload information and the queuing rate information to obtain the dequeue duration information of the preset queue.
[0122] The more requests that have been queued in the preset queue, the longer the dequeue time of the queued requests will be as represented by the evaluated dequeue time information; the more resources required to process the queued requests, the longer the dequeue time of the queued requests will be as represented by the evaluated dequeue time information; the lower the queuing rate represented by the queuing rate information, the longer the dequeue time of the queued requests will be as represented by the evaluated dequeue time information.
[0123] Step 508: Select the target queue from multiple preset queues whose dequeue duration information matches the classification result.
[0124] As an example, step 508 includes: determining the dequeueing requirement duration information corresponding to the traffic request based on the classification result, wherein the higher the dequeueing priority represented by the classification result, the shorter the dequeueing requirement duration represented by the determined dequeueing requirement duration information; and selecting a target queue from multiple preset queues whose dequeueing duration information matches the dequeueing requirement duration information.
[0125] In this embodiment, considering that the preset queue itself has queue resource allocation, resulting in a queue forwarding time, and that after the preset queue enqueues a request, it needs to be processed by the downstream cluster before it can forward the next request, there is also a queue forwarding waiting time. The queue forwarding time is quantified by the queue resource allocation information, and the queue forwarding waiting time is quantified by the enqueued requests, thus obtaining the final dequeue duration information. Based on the dequeue duration information, the target queue that matches the traffic request is selected, thus improving the accuracy of queue selection.
[0126] As a detailed embodiment, a traffic request is received, and traffic information of the traffic request is obtained, wherein the traffic request is used for model inference; based on the traffic information fed back by the user, the latency of the traffic request is evaluated to obtain latency information; based on the traffic request association information, the correlation between the traffic request and each processed traffic request is evaluated to obtain traffic association information; based on the traffic request service information, the importance of the traffic request to the corresponding service is evaluated to obtain traffic importance information; based on the latency information, traffic association information, and traffic importance information, a forwarding priority is assigned to the traffic request; if the forwarding priority meets a preset priority condition, the remaining resource information of the downstream cluster and the resource processing occupancy information of the traffic request are obtained, and if the resource processing occupancy information matches the remaining resource information, the latency-sensitive type is determined as the latency evaluation type of the traffic request; if the resource processing occupancy information does not match the remaining resource information, the latency-insensitive type is determined as the latency evaluation type of the traffic request; if the forwarding priority does not meet the preset priority condition, the latency-insensitive type is determined as the latency evaluation type of the traffic request.
[0127] Furthermore, if the latency assessment type is latency-insensitive, a priority coefficient for forwarding priority is generated based on the resource processing occupancy information of the traffic request; the forwarding priority is updated based on the priority coefficient to obtain the updated priority; the traffic requests are classified based on the updated priority to obtain the classification results, and the queue resource allocation information and queued requests of multiple preset queues are obtained; for each preset queue, the queuing rate of the preset queue is evaluated based on the queue resource allocation information of the preset queue to obtain the queuing rate information of the preset queue; the dequeue duration of the queued requests of the preset queue is evaluated based on the queued requests and queuing rate information of the preset queue to obtain the dequeue duration information of the preset queue; and a target queue whose dequeue duration information matches the classification results is selected from multiple preset queues. The traffic request is written to the target queue and forwarded to the downstream cluster through the target queue. If the latency assessment type includes a latency-sensitive type, a preset request rate limiting condition is obtained, wherein the preset request rate limiting condition includes at least one of the following: request quantity rate limiting condition, request size rate limiting condition, and request latency rate limiting condition. If it is detected that the traffic request meets the request quantity rate limiting condition, the forwarding process of the traffic request is terminated. If it is detected that the traffic request does not meet the request quantity rate limiting condition, the forwarding process of the traffic request is terminated if the traffic request meets the request size rate limiting condition or if the traffic request meets the request latency rate limiting condition. If the traffic request does not meet both the request size rate limiting condition and the request latency rate limiting condition, the traffic request is forwarded to the downstream cluster.
[0128] Thus, based on traffic information, the latency sensitivity of traffic requests is first assessed. Then, based on the latency assessment type that can characterize latency sensitivity, the traffic requests are forwarded in a corresponding manner. Specifically, for latency-sensitive types, the requests are directly forwarded to the downstream cluster so that the downstream cluster can process the traffic requests in a timely manner. For latency-insensitive types, the traffic requests are first written to a target queue, and then forwarded to the downstream cluster through the target queue. This ensures that the access method corresponding to the traffic request matches the traffic request processing requirements, thereby improving the accuracy of traffic request access.
[0129] Furthermore, by using latency information (characterizing the duration of a traffic request), traffic association information (characterizing the correlation between a traffic request and other processed traffic requests), and traffic importance information (characterizing the importance of a traffic request to the corresponding service) as the evaluation criteria for the latency sensitivity of traffic requests, the latency sensitivity of traffic requests can be evaluated from the above three dimensions. This results in a latency evaluation type obtained based on a richer set of dimensions, thus improving the accuracy of the latency sensitivity evaluation. Additionally, considering that the smaller the amount of resources required to process a traffic request, as indicated by resource processing occupancy information, the shorter the processing time, the faster the target queue can write the next request after the traffic request is written. Therefore, resource processing occupancy information is used as the basis for generating priority coefficients, and the forwarding priority is updated using these priority coefficients. This ensures that the updated priority reflects both the forwarding priority determined by the above multiple dimensions and the processing time required for the traffic request. Since the updated priority is the basis for classifying traffic requests, the accuracy of traffic request classification is improved.
[0130] Furthermore, considering that the preset queue itself has queue resource allocation, resulting in a queue forwarding time, and that after a request is queued, it needs to be processed by the downstream cluster before it can be forwarded to the next request, the preset queue also has a queue forwarding waiting time. By quantifying the queue forwarding time through queue resource allocation information and by quantifying the queue forwarding waiting time through queued requests, the final dequeue duration information can be obtained. Based on the dequeue duration information, the target queue that matches the traffic request can be selected, thus improving the accuracy of queue selection.
[0131] It should be understood that although the steps in the flowcharts of the above embodiments are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the above embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.
[0132] Based on the same inventive concept, this application also provides a traffic request access device for implementing the traffic request access method described above. The solution provided by this device is similar to the implementation described in the above method; therefore, the specific limitations in one or more traffic request access device embodiments provided below can be found in the limitations of the traffic request access method described above, and will not be repeated here.
[0133] In one exemplary embodiment, such as Figure 6 As shown, a traffic request access device 600 is provided, including: an acquisition module 602, an evaluation module 604, and a forwarding module 606, wherein:
[0134] The acquisition module 602 is used to receive traffic requests and acquire traffic information of the traffic requests, wherein the traffic requests are used for model inference;
[0135] Evaluation module 604 is used to evaluate the latency sensitivity of traffic requests based on traffic information and obtain the latency evaluation type of traffic requests;
[0136] The forwarding module 606 is used to determine that the data to be identified needs to be backed up if the backup score of the data to be identified is greater than the score threshold corresponding to the data to be identified.
[0137] In one embodiment, the traffic information includes user feedback traffic information, traffic request association information, and traffic request service information; the evaluation module 604 is further configured to evaluate the latency of the traffic request based on the user feedback traffic information to obtain latency information; evaluate the correlation between the traffic request and each processed traffic request based on the traffic request association information to obtain traffic association information; evaluate the importance of the traffic request to the corresponding service based on the traffic request service information to obtain traffic importance information; and evaluate the latency sensitivity of the traffic request based on the latency information, traffic association information, and traffic importance information to obtain the latency evaluation type of the traffic request.
[0138] In one embodiment, the evaluation module 604 is further configured to allocate forwarding priorities to traffic requests based on latency information, traffic association information, and traffic importance information; if the forwarding priority meets the preset priority conditions, the remaining resource information of the downstream cluster and the resource processing occupancy information of the traffic request are obtained; if the resource processing occupancy information matches the remaining resource information, the latency-sensitive type is determined as the latency evaluation type of the traffic request; if the resource processing occupancy information does not match the remaining resource information, the latency-insensitive type is determined as the latency evaluation type of the traffic request; if the forwarding priority does not meet the preset priority conditions, the latency-insensitive type is determined as the latency evaluation type of the traffic request.
[0139] In one embodiment, the forwarding module 606 is further configured to generate a priority coefficient for forwarding priority based on the resource processing occupancy information of the traffic request; update the forwarding priority based on the priority coefficient to obtain an updated priority; and classify the traffic request based on the updated priority to obtain a classification result.
[0140] In one embodiment, the forwarding module 606 is further configured to obtain queue resource allocation information and queued requests of multiple preset queues; for each preset queue, evaluate the queuing rate of the preset queue based on the queue resource allocation information of the preset queue to obtain the queuing rate information of the preset queue; evaluate the dequeue duration of the queued requests of the preset queue based on the queued requests and queuing rate information of the preset queue to obtain the dequeue duration information of the preset queue; and select a target queue from the multiple preset queues whose dequeue duration information matches the classification result.
[0141] In one embodiment, the forwarding module 606 is further configured to, if the latency assessment type includes a latency-sensitive type, obtain a preset request rate limiting condition, wherein the preset request rate limiting condition includes at least one of a request quantity rate limiting condition, a request size rate limiting condition, and a request latency rate limiting condition; if it is detected that the traffic request corresponds to the request quantity rate limiting condition, then the forwarding process of the traffic request is terminated; if it is detected that the traffic request corresponds to the request quantity rate limiting condition, then the forwarding process of the traffic request is terminated if the traffic request corresponds to the request size rate limiting condition, or if the traffic request corresponds to the request latency rate limiting condition; if the traffic request corresponds to the request size rate limiting condition and the traffic request latency rate limiting condition, then the traffic request is forwarded to the downstream cluster.
[0142] Each module in the aforementioned traffic request access device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the corresponding operations of each module.
[0143] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 7As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When executed by the processor, the computer program implements a traffic request access method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.
[0144] Those skilled in the art will understand that Figure 7 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0145] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above-described method embodiments.
[0146] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps in the above method embodiments.
[0147] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.
[0148] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0149] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0150] The above embodiments are merely illustrative of several implementation methods of this application, and their descriptions are relatively specific and detailed. However, they should not be construed as limiting the scope of protection of this application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the appended claims.
Claims
1. A traffic request access method, characterized in that, The method includes: Receive traffic requests and obtain traffic information of the traffic requests, wherein the traffic requests are used for model inference, and the traffic information includes user feedback traffic information, traffic request association information, and traffic request business information; Based on the user feedback traffic information, the traffic request is evaluated for latency to obtain latency information; based on the traffic request association information, the correlation between the traffic request and each processed traffic request is evaluated to obtain traffic association information; based on the traffic request service information, the importance of the traffic request to the corresponding service is evaluated to obtain traffic importance information; based on the latency information, the traffic association information, and the traffic importance information, the latency sensitivity of the traffic request is evaluated to obtain the latency evaluation type of the traffic request. The user feedback traffic information is used to characterize the urgency of the user's processing of the traffic request; the traffic request association information is determined by the field similarity between the traffic request and the processed traffic requests; the processed traffic requests are traffic requests that have been forwarded to the downstream cluster and processed by the downstream cluster; and the traffic request service information are the fields in the traffic request that are associated with the corresponding service. If the latency assessment type is a latency-insensitive type, then the traffic requests are classified according to the resource processing occupancy information of the traffic requests to obtain the classification results, and a target queue is selected from multiple preset queues based on the classification results. The traffic request is written to the target queue, and then forwarded to the downstream cluster through the target queue; If the latency assessment type is a latency-sensitive type, then the traffic request is forwarded to the downstream cluster; The step of evaluating the correlation between the traffic request and each processed traffic request based on the traffic request correlation information to obtain traffic correlation information includes: obtaining the total field length of the traffic request; locating the similar parts of the fields between the traffic request and each processed traffic request based on the traffic request correlation information to obtain similar fields; determining the ratio between the field length of each similar field and the total field length as the proportion of the similar part between the traffic request and each processed traffic request; and evaluating the correlation between the traffic request and each processed traffic request based on the proportion of the similar part between the traffic request and each processed traffic request to obtain traffic correlation information.
2. The method according to claim 1, characterized in that, The step of evaluating the latency sensitivity of the traffic request based on the latency information, the traffic association information, and the traffic importance information to obtain the latency evaluation type of the traffic request includes: Based on the time delay information, the traffic association information, and the traffic importance information, a forwarding priority is assigned to the traffic request; If the forwarding priority meets the preset priority condition, the remaining resource information of the downstream cluster and the resource processing occupation information of the traffic request are obtained. If the resource processing occupation information matches the remaining resource information, the latency-sensitive type is determined as the latency evaluation type of the traffic request. If the resource processing occupation information does not match the remaining resource information, the latency-insensitive type is determined as the latency evaluation type of the traffic request. If the forwarding priority does not meet the preset priority condition, then the latency-insensitive type is determined as the latency evaluation type of the traffic request.
3. The method according to claim 2, characterized in that, The step of classifying traffic requests based on the resource processing occupancy information of the traffic requests to obtain classification results includes: Based on the resource processing occupancy information of the traffic request, a priority coefficient for the forwarding priority is generated; The forwarding priority is updated based on the priority coefficient to obtain the updated priority; Based on the update priority, traffic requests are categorized to obtain the categorization results.
4. The method according to claim 1, characterized in that, The step of selecting a target queue from multiple preset queues based on the classification result includes: Obtain queue resource allocation information and queued requests from multiple preset queues; For each preset queue, the queuing rate of the preset queue is evaluated based on the queue resource allocation information of the preset queue, and the queuing rate information of the preset queue is obtained. Based on the queued requests in the preset queue and the queuing rate information, the dequeue time of the queued requests in the preset queue is evaluated to obtain the dequeue time information of the preset queue. Select a target queue from the plurality of preset queues whose dequeue duration information matches the classification result.
5. The method according to claim 1, characterized in that, If the latency assessment type includes a latency-sensitive type, then forwarding the traffic request to the downstream cluster includes: If the latency assessment type includes a latency-sensitive type, then a preset request rate limiting condition is obtained, wherein the preset request rate limiting condition includes at least one of a request quantity rate limiting condition, a request size rate limiting condition, and a request latency rate limiting condition; If it is detected that the traffic request meets the request quantity rate limiting condition, then the forwarding process of the traffic request is terminated; If it is detected that the traffic request does not meet the request quantity rate limiting condition, then if the traffic request meets the request size rate limiting condition, or if the traffic request meets the request latency rate limiting condition, the forwarding process of the traffic request will be terminated. If the traffic request does not meet the request size rate limiting condition and does not meet the request latency rate limiting condition, the traffic request will be forwarded to the downstream cluster.
6. A traffic request access device, characterized in that, The device includes: The acquisition module is used to receive traffic requests and acquire traffic information of the traffic requests, wherein the traffic requests are used for model inference, and the traffic information includes user feedback traffic information, traffic request association information, and traffic request business information; An evaluation module is used to evaluate the latency of the traffic request based on the user feedback traffic information to obtain latency information; evaluate the correlation between the traffic request and each processed traffic request based on the traffic request association information to obtain traffic association information; evaluate the importance of the traffic request to the corresponding service based on the traffic request service information to obtain traffic importance information; and evaluate the latency sensitivity of the traffic request based on the latency information, the traffic association information, and the traffic importance information to obtain the latency evaluation type of the traffic request. The user feedback traffic information is used to characterize the urgency of the user's processing of the traffic request; the traffic request association information is determined by the field similarity between the traffic request and the processed traffic requests; the processed traffic requests are traffic requests that have been forwarded to the downstream cluster and processed by the downstream cluster; and the traffic request service information are fields in the traffic request that are associated with the corresponding service. The forwarding module is configured to: if the latency assessment type is a latency-insensitive type, classify the traffic request according to the resource processing occupancy information of the traffic request, obtain a classification result, select a target queue from multiple preset queues according to the classification result, write the traffic request into the target queue, and forward the traffic request to the downstream cluster through the target queue; if the latency assessment type is a latency-sensitive type, forward the traffic request to the downstream cluster. The evaluation module is also used to obtain the total field length of the traffic request, locate the similar parts of the fields between the traffic request and each processed traffic request according to the traffic request association information, obtain similar fields, determine the ratio between the field length of each similar field and the total field length as the proportion of the field similarity between the traffic request and each processed traffic request, evaluate the association between the traffic request and each processed traffic request according to the proportion of the field similarity between the traffic request and each processed traffic request, and obtain traffic association information.
7. The apparatus as claimed in claim 6, characterized in that, The evaluation module is also used to assign forwarding priorities to the traffic requests based on the time delay information, the traffic association information, and the traffic importance information; If the forwarding priority meets the preset priority condition, the remaining resource information of the downstream cluster and the resource processing occupation information of the traffic request are obtained. If the resource processing occupation information matches the remaining resource information, the latency-sensitive type is determined as the latency evaluation type of the traffic request. If the resource processing occupation information does not match the remaining resource information, the latency-insensitive type is determined as the latency evaluation type of the traffic request. If the forwarding priority does not meet the preset priority condition, then the latency-insensitive type is determined as the latency evaluation type of the traffic request.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 5.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.
10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Method and system for dispatching data
CN101834787A
Resource allocation method, device and equipment and readable storage medium
CN118803476A