Processing method and device, electronic equipment and storage medium

By obtaining the current application scenarios of the target application and dynamically adjusting resource allocation, the problem of mismatch between application strategies and resources in the existing technology is solved, and more efficient resource utilization and user experience improvement is achieved.

CN119938314APending Publication Date: 2025-05-06LENOVO (BEIJING) LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411908040.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-23
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

When the application strategy is adjusted and optimized in the prior art, coarse-grained processing leads to mismatch of resources in different application scenarios within the application, resulting in resource loss.

Method used

By obtaining the application scenarios currently running in the target application, using the corresponding application strategies to fine-tune the target application, and dynamically adjust resource allocation to match the needs of different application scenarios.

Benefits of technology

It achieves more accurately meeting the needs of target applications in different application scenarios, reducing resource losses, and improving application performance and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119938314A_ABST
    Figure CN119938314A_ABST
Patent Text Reader

Abstract

The invention discloses a processing method and device, electronic equipment and a storage medium, and relates to the technical field of computers. The method comprises the following steps: if a target application is in a running state, acquiring a target application scene in which the target application runs currently; based on the target application scene currently operated by the target application, processing the target application by using a target application strategy; wherein if the target application scene is a first application scene, the target application strategy corresponding to the target application is a first application strategy; if the target application scene is a second application scene, the target application strategy corresponding to the target application is a second application strategy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a processing method, device, electronic device and storage medium. Background Art

[0002] In related technologies, policy adjustment or optimization is usually performed on the basis of the entire application. This coarse-grained processing method is effective in many cases. However, as the complexity and diversity of applications continue to increase, for specific application scenarios within the application, the current application policy and the resources actually used by the application do not match, resulting in useless resource loss. Summary of the invention

[0003] In response to the above technical problems, the embodiments of the present application provide a processing method, an apparatus, an electronic device and a storage medium.

[0004] The technical solution of the embodiment of the present application is implemented as follows:

[0005] In a first aspect, an embodiment of the present application provides a processing method, including:

[0006] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0007] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0008] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0009] In some embodiments, obtaining the target application scenario currently running the target application includes:

[0010] Obtaining round-trip time information of data transmission performed by the target application;

[0011] Based on the round-trip time information, a target application scenario in which the target application is currently running is determined.

[0012] In some embodiments, determining the target application scenario in which the target application is currently running based on the round-trip time information includes:

[0013] The round-trip time information is input into an application scenario recognition intelligent engine to obtain the target application scenario output by the application scenario recognition intelligent engine.

[0014] In some embodiments, the target application policy is used to adjust resources for the target application, and the first application policy and the second application policy have different amounts of resources.

[0015] In some embodiments, the resource is selected from at least one of the following combinations:

[0016] Network resources, computing resources, storage resources, security resources, and refresh rates.

[0017] In some embodiments, obtaining round-trip time information of data transmission performed by the target application includes:

[0018] Monitoring data transmitted by the target application to obtain a round-trip time value of each of at least two groups of data; each of the at least two groups of data includes first data and second data, the first data is data sent by the target application, and the second data is response data received by the target application for the first data;

[0019] Based on the round-trip time value of each group of data in the at least two groups of data, round-trip time information of data transmission performed by the target application is determined.

[0020] In some embodiments, monitoring the data transmitted by the target application to obtain a round trip time value of each set of data in at least two sets of data includes:

[0021] Monitoring data transmitted by the target application to obtain first message information corresponding to the first data and second message information corresponding to the second data included in each of at least two groups of data;

[0022] For any set of target data among the at least two sets of data, the round-trip time value of the target data is determined based on the first timestamp information in the first message information corresponding to the first data included in the target data and the second timestamp information in the second message information corresponding to the second data.

[0023] In a second aspect, an embodiment of the present application provides a processing device, including:

[0024] An acquisition module, used for acquiring a target application scenario currently being run by the target application if the target application is in a running state;

[0025] A processing module, configured to process the target application using a target application strategy based on the target application scenario currently being run by the target application;

[0026] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0027] In a third aspect, an embodiment of the present application provides an electronic device, including a memory and a processor, wherein the memory is used to store executable data instructions; when the processor is used to execute the executable data instructions stored in the memory, the following steps are implemented:

[0028] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0029] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0030] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0031] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:

[0032] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0033] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0034] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] In order to more clearly illustrate the technical solutions of the embodiments of the present application, a brief introduction will be given below to the drawings required for use in the embodiments. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0036] Figure 1One of the flow charts of a processing method provided in an embodiment of the present application;

[0037] Figure 2 A schematic diagram of a round-trip time rule corresponding to an application scenario 1 provided in an embodiment of the present application;

[0038] Figure 3 A schematic diagram of a round-trip time rule corresponding to an application scenario 2 provided in an embodiment of the present application;

[0039] Figure 4 A schematic diagram of a round-trip time rule corresponding to an application scenario three provided in an embodiment of the present application;

[0040] Figure 5 A second flow chart of a processing method provided in an embodiment of the present application;

[0041] Figure 6 A third flow chart of a processing method provided in an embodiment of the present application;

[0042] Figure 7 A fourth flow chart of a processing method provided in an embodiment of the present application;

[0043] Figure 8 A fifth flow chart of a processing method provided in an embodiment of the present application;

[0044] Fig. 9 A schematic diagram of the structure of a processing device provided in an embodiment of the present application;

[0045] Fig.10 A schematic diagram of the physical structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0046] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the embodiments of the present application.

[0047] It should be noted that in the description of the embodiments of the present application, the terms "first", "second", etc. are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of the same type, and the number of objects is not limited. For example, the first object can be one or more.

[0048] It should be noted that as user needs continue to change, the functional and performance requirements of applications are also evolving. Within the application, different application scenarios have significantly different required resources due to their unique business logic and user behavior patterns. However, the current method of adjusting or optimizing policies based on the entire application does not match the application policy with the resources actually used by the application. The reason is that applications are not always in high demand. Different scenarios in which applications run have different corresponding resource requirements.

[0049] In order to overcome the above-mentioned defects of the related technology, the embodiments of the present application propose a processing method, an apparatus, an electronic device and a storage medium, which can use different target application strategies to perform refined processing on the target application according to the different target application scenarios in which the target application is currently running, and can more accurately meet the needs of the target application in different application scenarios, improve resource loss, and improve the performance and user experience of the target application.

[0050] In the following, in conjunction with the drawings in the embodiments of the present application, a processing method, an apparatus, an electronic device and a storage medium provided in the embodiments of the present application are exemplarily introduced.

[0051] Figure 1 One of the flow charts of a processing method provided in an embodiment of the present application is as follows: Figure 1 As shown, the method includes:

[0052] S101: If the target application is in a running state, obtain a target application scenario currently running the target application.

[0053] It should be noted that the target application in the embodiments of the present application may be a specific software program or application program that can be run on a user device (such as a smart phone, tablet computer, desktop computer, etc.). For example, the target application is an online game application, a social media application, an office software application, etc.

[0054] It should be noted that the target application scenario refers to the specific usage situation or state of the target application. For example, an online game application may be in different application scenarios such as "game update", "waiting in the lobby" or "game in progress"; a social media application may be in application scenarios such as "browsing friends' updates", "posting a new status" or "making a video call".

[0055] It should be noted that the specific state of the target application can be understood as the different functions / interfaces run by the target application. In other words, the different functions / interfaces of the target application are the different application scenarios included in the target application. Moreover, different applications have slightly different cabinets (structures or modules used to manage, allocate or control resources, functions or data flows within the application) for application scenarios. For example, for different functions / interfaces of online education applications (such as course list pages, video playback pages, online test pages, and score viewing pages, etc.), the cabinet will perform different resource allocation and control according to the specific needs of different functions / interfaces of online education applications. For example, for the video playback page, the cabinet needs to ensure that the video playback page can access and smoothly play high-quality video resources. This may involve the storage, transmission, and bandwidth management of video files during playback; for the score viewing page, the cabinet needs to ensure that the score viewing page can access and display accurate score data. This may involve the storage, retrieval, and permission management of score data during display. For another example, for different functions / interfaces of e-commerce applications (such as product list pages, product details pages, shopping cart pages, settlement pages, etc.), the cabinet will perform different resource allocation and control according to the specific needs of different functions / interfaces of e-commerce applications. For example, for the product list page, the cabinet needs to ensure that it can efficiently retrieve product data that meets the user's search or screening conditions from the database for display. This may involve improving the page loading speed through caching, paging and other technologies; for the settlement page, the cabinet needs to ensure the access and stable operation of at least one payment method, and update the payment interface in a timely manner to cope with changes in payment channels. It also needs to strengthen security control over the payment process and adopt technical means such as encrypted transmission and security authentication to ensure the security of user payment information.

[0056] In some embodiments, if the target application is in a running state, the target application scenario currently running by the target application can be determined based on the running log of the target application.

[0057] In some embodiments, if the target application is in a running state, statistics of the user's current behavior may be collected to determine the target application scenario in which the target application is currently running.

[0058] In some embodiments, if the target application is in a running state, the target application scenario in which the target application is currently running can be identified based on computer vision technology.

[0059] S102: Based on the target application scenario in which the target application is currently running, process the target application using a target application policy.

[0060] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0061] In an embodiment of the present application, if it is determined that the target application scenario currently running the target application is the first application scenario, the target application is processed using the first application strategy; if it is determined that the target application scenario currently running the target application is the second application scenario, the target application is processed using the second application strategy.

[0062] It should be noted that the first application policy may be a policy pre-set for the first application scenario for adjusting or optimizing the target application; the second application policy may be a policy pre-set for the second application scenario for adjusting or optimizing the target application.

[0063] In some embodiments, if it is determined that the target application scenario currently being run by the target application is the first application scenario, the first application strategy may be used to process the first application scenario of the target application. The first application strategy may focus on providing sufficient resources for the first application scenario to ensure its smooth operation. For example, if the first application scenario is a video playback scenario, the first application strategy may increase the allocation of central processing unit (CPU) resources and memory resources to improve the smoothness and response speed of video playback.

[0064] In some embodiments, if it is determined that the target application scenario currently being run by the target application is the second application scenario, the second application strategy may be used to process the second application scenario of the target application. The second application strategy may adjust resource allocation according to the specific needs of the second application scenario. For example, if the second application scenario is a text editing scenario, the second application strategy may reduce resources related to graphics rendering and increase resources related to text processing to improve the efficiency and comfort of text editing.

[0065] It can be understood that the processing method provided in the embodiment of the present application obtains the target application scenario currently running by the target application when the target application is in a running state, and then processes the target application based on the target application scenario currently running by the target application using the target application policy. Moreover, if the target application scenario is a first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is a second application scenario, the target application policy corresponding to the target application is the second application policy. In this way, it is effectively achieved that different target application scenarios currently running by the target application are used to perform refined processing of the target application using different target application policies, which can more accurately meet the needs of the target application in different application scenarios and improve the performance and user experience of the target application.

[0066] In some embodiments, the target application policy is used to adjust resources for the target application, and the first application policy and the second application policy have different amounts of resources.

[0067] It should be noted that the target application policy can be a set of predefined rules or instructions for adjusting the resource allocation of the target application according to the specific application scenario of the target application. The target application policy aims to optimize the performance, response speed, resource utilization and user experience of the application.

[0068] It should be noted that since the first application scenario and the second application scenario are different application scenarios included in the target application, and different application scenarios may have their own specific performance requirements and resource consumption patterns, the first application strategy used to process the target application in the first application scenario and the second application strategy used to process the target application in the second application scenario have different resource amounts.

[0069] For example, if the target application is a video playback application, the first application scenario is a high-definition video playback scenario, and the second application scenario is a video list browsing scenario.

[0070] It is understandable that in the HD video playback scenario, users expect the video to play smoothly, without stuttering or delay, and with clear picture quality. This requires the video playback application to efficiently handle tasks such as video decoding, rendering, and audio synchronization. In this scenario, the video playback application consumes a lot of CPU resources for video decoding and image processing, and requires a lot of memory to cache video frames and audio data. In addition, network bandwidth is also a key resource for downloading video streams from the server. In order to meet the performance requirements of the HD video playback scenario, the first application strategy will prioritize allocating sufficient CPU time and memory resources to the video playback task to ensure that the video can play smoothly. At the same time, the first application strategy will also optimize the network request and caching mechanism to reduce video loading time and improve playback stability. In addition, in order to reduce power consumption, the first application strategy may limit the running of other non-essential background tasks.

[0071] In the video list browsing scenario, users expect to be able to quickly scroll the list, view video thumbnails and titles, and quickly locate the video of interest. This requires the video playback application to respond quickly to the user's scrolling operation and quickly load and display the video list items. In this scenario, the video playback application will consume a certain amount of CPU resources to process the user's scrolling events and update the user interface (UI), and a certain amount of memory is required to cache the data and images of the video list items. Compared with the high-definition video playback scenario, the resource consumption in this scenario is relatively small. In order to meet the performance requirements of the video list browsing scenario, the second application strategy will optimize the UI rendering and scrolling performance to ensure that the list can scroll smoothly and respond quickly. At the same time, the second application strategy will limit the loading quality and quantity of video thumbnails to reduce the consumption of memory and network resources. In addition, in order to provide a better user experience, the second application strategy may preload the data of some video list items to reduce user waiting time.

[0072] It can be seen from the above examples that the resource amounts of the first application strategy for processing the video playback application in the high-definition video playback scenario and the second application strategy for processing the video playback application in the video list browsing scenario are different.

[0073] It can be understood that the embodiment of the present application can more accurately meet the needs of the target application in different application scenarios and improve the performance and user experience of the target application by respectively processing the target application using the first application strategy and the second application strategy with different resource amounts for the first application scenario and the second application scenario of the target application.

[0074] In some embodiments, the resource is selected from at least one of the following combinations:

[0075] Network resources, computing resources, storage resources, security resources, and refresh rates.

[0076] It should be noted that network resources, including network bandwidth, network latency, and network connection stability, are crucial for the communication and data transmission of target applications. By adjusting network resources, the response time and user experience of target applications can be optimized.

[0077] It should be noted that computing resources include CPU, memory and graphics processing unit (GPU), etc., which are used to process the computing needs of the target application. The allocation of these computing resources can be dynamically adjusted according to the load and performance requirements of the target application.

[0078] It should be noted that storage resources include hard disks, solid state drives (SSDs), and cloud storage, etc., which are used to store data of target applications. According to the data storage requirements of the target application, the capacity and type of storage resources can be adjusted to ensure data reliability and access speed.

[0079] It should be noted that security resources are used to protect target applications from attacks and data leakage, including firewalls, intrusion detection systems, data encryption, and identity authentication.

[0080] It should be noted that the refresh rate is used to describe the number of times the screen image is refreshed per second, in Hertz (Hz). This indicator is more related to the performance and user experience of display devices (such as monitors, mobile phone screens, etc.). In the field of electronic display, the refresh rate directly affects the smoothness and stability of the image. A high refresh rate can reduce image flicker and smear, making dynamic images smoother and more realistic. Especially in games and high-speed motion videos, a high refresh rate can significantly enhance the user's visual experience. Measures to optimize the refresh rate for specific application scenarios include adjusting the frame rate, reducing rendering delays, etc.

[0081] In some embodiments, obtaining the target application scenario currently running the target application includes:

[0082] Obtaining round-trip time information of data transmission performed by the target application;

[0083] Based on the round-trip time information, a target application scenario in which the target application is currently running is determined.

[0084] It should be noted that the relevant technology can usually only identify the foreground running status of an application (such as the online game "Honor of Kings"), but cannot accurately identify different application scenarios within the application (such as "game update", "lobby waiting" or "game in progress" and other application scenarios). This limits the implementation of strategies for optimizing or adjusting specific application scenarios within the application (such as "game in progress").

[0085] In the embodiment of the present application, considering that when the target application runs in different application scenarios, the round-trip time information for data transmission is different, the round-trip time information is used to characterize the law or pattern of the round-trip time (RTT) for data transmission when the target application runs in a specific application scenario. Figures 2 to 4 As shown, Figure 2 The round-trip time pattern corresponding to the application scenario 1 shown is the test result of the round-trip time pattern corresponding to the "Waiting in the Lobby" scenario of the online game "Honor of Kings". Figure 3 The round-trip time pattern corresponding to the second application scenario shown is the test result of the round-trip time pattern corresponding to the "Game Update" scenario of the online game "Honor of Kings". Figure 4 The round-trip time rule corresponding to the application scenario 3 shown is the test result of the round-trip time rule corresponding to the "game in progress" scenario of the online game "Honor of Kings". Figures 2 to 4 It can be seen that in the three different application scenarios of the online game "Honor of Kings" ("Waiting in the Lobby", "Game Update" and "Game in Progress"), the round-trip time patterns of data transmission are obviously different.

[0086] Therefore, in an embodiment of the present application, if it is determined that the target application is in a running state, the round-trip time information of the target application performing data transmission within the current specific time period (for example, 20 seconds, 30 seconds or 50 seconds) can be obtained, and then based on the round-trip time information, the target application scenario in which the target application is currently running can be identified.

[0087] It should be noted that RTT refers to the duration required for a network request to reach the destination (such as the server) from the starting point (such as the client) and return to the starting point again, usually in milliseconds (ms). It represents the time required for a data packet to travel back and forth in the network, and is one of the important indicators for measuring network performance.

[0088] For example, Figure 5 A second flow chart of a processing method provided in an embodiment of the present application is as follows: Figure 5 As shown, the method includes:

[0089] S501: If the target application is in a running state, obtain round-trip time information of data transmission performed by the target application.

[0090] S502: Determine a target application scenario in which the target application is currently running based on the round-trip time information.

[0091] S503: Based on the target application scenario in which the target application is currently running, process the target application using a target application policy.

[0092] It should be noted that, for the description of the same steps and the same contents in this embodiment as those in other embodiments, reference can be made to the description in other embodiments and will not be repeated here.

[0093] It is understandable that the embodiment of the present application identifies the target application scenario by round-trip time information of data transmission based on the target application, which has higher accuracy and reliability than traditional methods such as log analysis or user behavior statistics. The reason is that, on the one hand, the round-trip time measurement can reflect the time for the data packet to go from the source to the destination and then return to the source in real time, which helps to quickly capture small changes in network or application performance. In contrast, log analysis or user behavior statistics usually rely on post-collection and analysis of data, and may not provide real-time performance monitoring; on the other hand, the round-trip time measurement can usually achieve millisecond-level accuracy, which can accurately capture small delays in the data transmission process, while log analysis or user behavior statistics may be affected by multiple factors such as data sampling rate, data format and data fineness, resulting in reduced accuracy.

[0094] In some embodiments, determining the target application scenario in which the target application is currently running based on the round-trip time information includes:

[0095] The round-trip time information is input into an application scenario recognition intelligent engine to obtain the target application scenario output by the application scenario recognition intelligent engine.

[0096] In the embodiment of the present application, if the target application is in a running state, the round-trip time information of the target application for data transmission is obtained, and then the obtained round-trip time information is input into the application scenario recognition intelligent engine to obtain the target application scenario output by the application scenario recognition intelligent engine. The application scenario recognition intelligent engine can be a pre-trained machine learning model.

[0097] In some embodiments, the round-trip time regularity information or round-trip time pattern (RTT Pattern) information of data transmission of the target application in different application scenarios can be collected, and then the collected round-trip time regularity information or round-trip time pattern information in different application scenarios can be used as sample data, and these sample data can be divided into positive samples and negative samples to train the initially constructed application scenario recognition intelligent engine, so as to obtain a trained application scenario recognition intelligent engine for identifying the application scenario in which the target application runs.

[0098] For example, Figure 6 A third flow chart of a processing method provided in an embodiment of the present application is as follows: Figure 6 As shown, the method includes:

[0099] S601: If the target application is in a running state, obtain round-trip time information of data transmission performed by the target application.

[0100] S602: Input the round-trip time information into an application scenario recognition intelligent engine to obtain a target application scenario currently running by the target application output by the application scenario recognition intelligent engine.

[0101] S603: Based on the target application scenario in which the target application is currently running, process the target application using a target application policy.

[0102] It should be noted that, for the description of the same steps and the same contents in this embodiment as those in other embodiments, reference can be made to the description in other embodiments and will not be repeated here.

[0103] It can be understood that since the round-trip time information can reflect the data transmission characteristics of the target application in different application scenarios, the embodiment of the present application inputs the round-trip time information of the target application's data transmission into the application scenario recognition intelligent engine, and the application scenario recognition intelligent engine can accurately identify the target application scenario in which the target application is currently running.

[0104] In some embodiments, obtaining round-trip time information of data transmission performed by the target application includes:

[0105] Monitoring data transmitted by the target application to obtain a round-trip time value of each of at least two groups of data; each of the at least two groups of data includes first data and second data, the first data is data sent by the target application, and the second data is response data received by the target application for the first data;

[0106] Based on the round-trip time value of each group of data in the at least two groups of data, round-trip time information of data transmission performed by the target application is determined.

[0107] In the embodiment of the present application, if it is determined that the target application is in a running state, the data transmitted by the target application can be monitored to obtain the round-trip time value of each group of data in at least two groups of data, and then the round-trip time information of the data transmission performed by the target application can be determined based on the round-trip time value of each group of data in the at least two groups of data. The round-trip time value of each group of data is obtained based on the sending time of the first data in the group of data and the receiving time of the second data, and the second data is the response data received by the target application for the first data.

[0108] In some embodiments, if it is determined that the target application is in a running state, the user identifier of the process used to run the target application in the system kernel can be determined based on the application name of the target application, and then the data transmitted by the target application can be monitored based on the user identifier.

[0109] In some embodiments, when data transmission by the target application is monitored based on a user identifier, a hook function can be called to intercept at least two sets of data transmitted by the target application, thereby determining the message information of the intercepted at least two sets of data, and then determining the round-trip time value of each set of data in the at least two sets of data based on the message information of the at least two sets of data.

[0110] For example, Figure 7 A fourth flow chart of a processing method provided in an embodiment of the present application is as follows: Figure 7 As shown, the method includes:

[0111] S701. If the target application is in a running state, monitor the data transmitted by the target application to obtain a round-trip time value for each of at least two groups of data; each of the at least two groups of data includes first data and second data, the first data is data sent by the target application, and the second data is response data received by the target application for the first data.

[0112] S702: Determine round-trip time information for data transmission by the target application based on the round-trip time value of each group of data in the at least two groups of data.

[0113] S703: Input the round-trip time information into an application scenario recognition intelligent engine to obtain a target application scenario currently running by the target application output by the application scenario recognition intelligent engine.

[0114] S704: Based on the target application scenario in which the target application is currently running, process the target application using a target application policy.

[0115] It should be noted that, for the description of the same steps and the same contents in this embodiment as those in other embodiments, reference can be made to the description in other embodiments and will not be repeated here.

[0116] It can be understood that the embodiment of the present application monitors the data transmitted by the target application to obtain the round-trip time value of each group of data in at least two groups of data, and then based on the round-trip time value of each group of data in the at least two groups of data, it is possible to accurately obtain the round-trip time information of the data transmission of the target application.

[0117] In some embodiments, monitoring the data transmitted by the target application to obtain a round trip time value of each set of data in at least two sets of data includes:

[0118] Monitoring data transmitted by the target application to obtain first message information corresponding to the first data and second message information corresponding to the second data included in each of at least two groups of data;

[0119] For any set of target data among the at least two sets of data, the round-trip time value of the target data is determined based on the first timestamp information in the first message information corresponding to the first data included in the target data and the second timestamp information in the second message information corresponding to the second data.

[0120] It should be noted that the system kernel module (kernel module) to which the target application belongs can be used to record the timestamp information of data sending and data receiving, and the timestamp information is carried in the data message.

[0121] In an embodiment of the present application, if the target application is in a running state, the data transmitted by the target application can be monitored to obtain first message information corresponding to the first data and second message information corresponding to the second data included in each of at least two groups of data, wherein the first message information carries first timestamp information, and the first timestamp information represents the time when the first message corresponding to the first data is recorded in the system kernel module, and the second message information carries second timestamp information, and the second timestamp information represents the time when the second message corresponding to the second data is recorded in the system kernel module. Then, based on the first timestamp information in the first message information corresponding to the first data in each group of data and the second timestamp information in the second message information corresponding to the second data, the round-trip time value of the group of data can be obtained.

[0122] It can be understood that since the first data is the data sent by the target application and the second data is the response data received by the target application for the first data, the round-trip time value of the group of data can be obtained by subtracting the first timestamp in the first message information corresponding to the first data from the second timestamp in the second message information corresponding to the second data.

[0123] For example, Figure 8 A fifth flow chart of a processing method provided in an embodiment of the present application is as follows: Figure 8 As shown, the method includes:

[0124] S801. If the target application is in a running state, monitor data transmitted by the target application to obtain first message information corresponding to first data and second message information corresponding to second data included in each of at least two groups of data.

[0125] S802. For each set of target data in the at least two sets of data, determine the round-trip time value of the target data based on the first timestamp information in the first message information corresponding to the first data included in the target data and the second timestamp information in the second message information corresponding to the second data.

[0126] S803: Determine round-trip time information for data transmission by the target application based on the round-trip time value of each group of target data in the at least two groups of data.

[0127] S804: Input the round-trip time information into an application scenario recognition intelligent engine to obtain a target application scenario currently running by the target application output by the application scenario recognition intelligent engine.

[0128] S805: Based on the target application scenario in which the target application is currently running, process the target application using a target application policy.

[0129] It should be noted that, for the description of the same steps and the same contents in this embodiment as those in other embodiments, reference can be made to the description in other embodiments and will not be repeated here.

[0130] It can be understood that the embodiment of the present application monitors the data transmitted by the target application to obtain the first message information corresponding to the first data and the second message information corresponding to the second data included in each of at least two groups of data, and then based on the first timestamp information in the first message information corresponding to the first data in each group of data and the second timestamp information in the second message information corresponding to the second data, the round-trip time value of the group of data can be accurately obtained, thereby helping to accurately obtain the round-trip time information of the target application for data transmission.

[0131] In some embodiments, a structure named tracked_tcp_seq can be defined for recording the TCP data packet information transmitted by the target application, and the structure includes the following members: sock (socket descriptor of Transmission Control Protocol (TCP) data packet), seq (sequence number of TCP data packet), tstamp (timestamp of TCP data packet in the system kernel at this time), list (a linked list used to connect the structure tracked_tcp_seq).

[0132] In some embodiments, when monitoring the data transmitted by the target application, the transmitted Internet Protocol (IP) data packets can be intercepted by calling a hook function. The intercepted data sent by the target application can be processed in a predefined function hook_func_out; the intercepted data received by the target application can be processed in a predefined function hook_func_in.

[0133] In some embodiments, in the function hook_func_out, if it is TCP data sent by the target application, the sock identifier, sequence number and system kernel time of the TCP data are saved in the structure tracked_tcp_seq, and the structure is added to the end of the linked list.

[0134] In some embodiments, in the function hook_func_in, if it is TCP data received by the target application, it is matched with the tracked_tcp_seq stored in the linked list. If the corresponding sock identifier is found, and the confirmation (ACK) sequence number of this TCP data is greater than the sequence number stored in the corresponding tracked_tcp_seq, it indicates that the received TCP data is a reply to the previously sent TCP data. The difference between the system kernel time at this time and the system kernel time stored in the corresponding tracked_tcp_seq is the calculated RTT value.

[0135] It can be understood that the embodiment of the present application intercepts the transmission data by calling the hook function, and performs logical judgment and logical calculation on the message information corresponding to the intercepted data, so as to accurately obtain the RTT value of the target application transmission data, thereby helping to accurately identify the target application scenario in which the target application runs based on the rules presented by the RTT value, so as to achieve refined processing of the target application using the target application strategy for the identified target application scenario.

[0136] The processing device provided in the embodiment of the present application is described below. The processing device described below and the processing method described above can be referenced to each other.

[0137] Fig. 9 A schematic diagram of a processing device provided in an embodiment of the present application is shown in FIG. Fig. 9 As shown, the device includes: an acquisition module 910 and a processing module 920; wherein:

[0138] The acquisition module 910 is used to acquire the target application scenario currently running by the target application if the target application is in a running state;

[0139] A processing module 920, configured to process the target application using a target application policy based on the target application scenario currently being run by the target application;

[0140] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0141] The processing device provided in the embodiment of the present application obtains the target application scenario currently running by the target application when the target application is in a running state, and then processes the target application by using the target application policy based on the target application scenario currently running by the target application. Moreover, if the target application scenario is a first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is a second application scenario, the target application policy corresponding to the target application is the second application policy. In this way, it is effectively achieved that different target application scenarios currently running by the target application are used to perform refined processing of the target application by using different target application policies, which can more accurately meet the needs of the target application in different application scenarios and improve the performance and user experience of the target application.

[0142] In some embodiments, the acquisition module 910 includes:

[0143] An acquisition unit, used to acquire round-trip time information of data transmission performed by the target application;

[0144] A determination unit is used to determine a target application scenario in which the target application is currently running based on the round-trip time information.

[0145] In some embodiments, the determining unit is further configured to:

[0146] The round-trip time information is input into an application scenario recognition intelligent engine to obtain the target application scenario output by the application scenario recognition intelligent engine.

[0147] In some embodiments, the target application policy is used to adjust resources for the target application, and the first application policy and the second application policy have different amounts of resources.

[0148] In some embodiments, the resource is selected from at least one of the following combinations:

[0149] Network resources, computing resources, storage resources, security resources, and refresh rates.

[0150] In some embodiments, the acquisition unit includes:

[0151] a monitoring subunit, configured to monitor the data transmitted by the target application, and obtain a round trip time value of each of at least two groups of data; each of the at least two groups of data includes first data and second data, the first data is data sent by the target application, and the second data is response data received by the target application for the first data;

[0152] The determination subunit is used to determine the round-trip time information of the target application performing data transmission based on the round-trip time value of each group of data in the at least two groups of data.

[0153] In some embodiments, the monitoring subunit is also used to: monitor the data transmitted by the target application, obtain first message information corresponding to the first data and second message information corresponding to the second data included in each of at least two groups of data; for any one group of target data in the at least two groups of data, determine the round-trip time value of the target data based on the first timestamp information in the first message information corresponding to the first data included in the target data and the second timestamp information in the second message information corresponding to the second data.

[0154] It should be noted here that the above-mentioned processing device provided in the embodiment of the present application can implement all the method steps implemented in the above-mentioned processing method embodiment, and can achieve the same technical effect. The parts and beneficial effects that are the same as the method embodiment in this embodiment will not be described in detail here.

[0155] Fig.10 A schematic diagram of the physical structure of an electronic device provided in an embodiment of the present application, such as Fig.10 As shown, the electronic device may include: a processor (processor) 1010, a communication interface (CommunicationsInterface) 1020, a memory (memory) 1030 and a communication bus 1040, wherein the processor 1010, the communication interface 1020 and the memory 1030 communicate with each other through the communication bus 1040. The processor 1010 may call the executable data instructions stored in the memory 1030 to execute the processing method provided by the above embodiments, and the method includes:

[0156] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0157] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0158] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0159] In addition, the executable data instructions stored in the above-mentioned memory 1030 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the embodiment of the present application can be essentially or partly embodied in the form of a software product that contributes to the relevant technology. The software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store program code.

[0160] The present application also provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the processing method provided in the above embodiments is implemented. The method includes:

[0161] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0162] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0163] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0164] The present application also provides a computer program product, which includes a computer program stored in a computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the processing methods provided in the above embodiments. The method includes:

[0165] If the target application is in a running state, obtaining the target application scenario currently running by the target application;

[0166] Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy;

[0167] Among them, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; if the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

[0168] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative work.

[0169] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the embodiments of the present application may adopt the form of hardware embodiments, software embodiments, or embodiments in combination with software and hardware. Moreover, the embodiments of the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) that contain computer-usable program code.

[0170] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0171] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0172] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0173] The above description is merely an optional embodiment of the present application and is not intended to limit the protection scope of the present application.

Claims

1. A processing method comprising: If the target application is in a running state, obtaining the target application scenario currently running by the target application; Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy; Wherein, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; If the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

2. According to the processing method of claim 1, the step of obtaining the target application scenario currently running the target application comprises: Obtaining round-trip time information of data transmission performed by the target application; Based on the round-trip time information, a target application scenario in which the target application is currently running is determined.

3. The processing method according to claim 2, wherein determining the target application scenario in which the target application is currently running based on the round-trip time information comprises: The round-trip time information is input into an application scenario recognition intelligent engine to obtain the target application scenario output by the application scenario recognition intelligent engine. 4 . The processing method according to claim 1 , wherein the target application policy is used to adjust resources for the target application, and the resource amounts of the first application policy and the second application policy are different.

5. The processing method according to claim 4, wherein the resource is selected from at least one of the following combinations: Network resources, computing resources, storage resources, security resources, and refresh rates.

6. The processing method according to claim 2 or 3, wherein obtaining round-trip time information of data transmission performed by the target application comprises: Monitoring data transmitted by the target application to obtain a round trip time value for each set of data in at least two sets of data; Each of the at least two groups of data includes first data and second data, the first data is data sent by the target application, and the second data is response data received by the target application for the first data; Based on the round-trip time value of each group of data in the at least two groups of data, round-trip time information of data transmission performed by the target application is determined.

7. The processing method according to claim 6, wherein the step of monitoring the data transmitted by the target application to obtain a round trip time value of each of at least two groups of data comprises: Monitoring data transmitted by the target application to obtain first message information corresponding to the first data and second message information corresponding to the second data included in each of at least two groups of data; For any set of target data among the at least two sets of data, the round-trip time value of the target data is determined based on the first timestamp information in the first message information corresponding to the first data included in the target data and the second timestamp information in the second message information corresponding to the second data.

8. A processing device comprising: An acquisition module, used for acquiring a target application scenario currently being run by the target application if the target application is in a running state; A processing module, configured to process the target application using a target application strategy based on the target application scenario currently being run by the target application; Wherein, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; If the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

9. An electronic device, comprising: A memory for storing executable data instructions; The processor is used to implement the following steps when executing the executable data instructions stored in the memory: If the target application is in a running state, obtaining the target application scenario currently running by the target application; Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy; Wherein, if the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; If the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.

10. A computer-readable storage medium, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the following steps are implemented: If the target application is in a running state, obtaining the target application scenario currently running by the target application; Based on the target application scenario in which the target application is currently running, processing the target application using a target application policy; in, If the target application scenario is the first application scenario, the target application policy corresponding to the target application is the first application policy; If the target application scenario is the second application scenario, the target application policy corresponding to the target application is the second application policy.