Interface analysis method and terminal display method

By obtaining the response loss value of the target interface and using a threshold to determine the degree of failure, the problem of cloud note storage space being unable to respond normally due to interface failure was solved. This enabled accurate analysis and switching of interface failures, ensuring the normal operation of the storage space and user experience.

CN119788492BActive Publication Date: 2025-11-07CHINA MOBILE INTERNET CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411851491.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-16
Publication Date
2025-11-07
Estimated Expiration
2044-12-16

AI Technical Summary

Technical Problem

The lack of a comprehensive solution for interface failure analysis in existing technologies has led to cloud note storage spaces failing to respond properly.

Method used

By obtaining the response loss value of the target interface, the failure level of the interface is determined using the response loss threshold, and an interface switching instruction is generated to switch to another interface when a failure occurs, ensuring that the storage space responds normally.

Benefits of technology

It enables accurate analysis and timely switching of interface failures, ensuring the normal operation of cloud note storage space and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119788492B_ABST
    Figure CN119788492B_ABST
Patent Text Reader

Abstract

The application discloses an interface analysis method and a terminal display method. The interface analysis method comprises the following steps: acquiring a response loss value during target interface testing; and determining a fault degree of the target interface based on the response loss value and a response loss threshold.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the interface technical field, and in particular to an interface analysis method and a terminal display method. BACKGROUND

[0002] Cloud notes, as a product tool of a "cloud service", are different from traditional notes in that they can be used for users to record, share and collect notes at any time during online learning, and can also quickly search and classify to find notes, safely backup cloud notes, store valuable data and files that will never be lost, and automatically complete file synchronization, thereby efficiently managing personal knowledge.

[0003] Since a user terminal accesses a storage space of cloud notes through a corresponding access interface, when the access interface fails, the storage space of the cloud notes cannot normally respond to work. However, there is no relatively perfect solution for the analysis of the interface. SUMMARY

[0004] The present application discloses an interface analysis method and a terminal display method to solve the problem that there is no relatively perfect solution for the analysis of the interface.

[0005] To solve the above problems, the present application adopts the following technical solutions:

[0006] In a first aspect, the present application discloses an interface analysis method applied to a server, including: obtaining a response loss value when a target interface is tested; determining a fault degree of the target interface based on the response loss value and a response loss threshold.

[0007] In a second aspect, the present application discloses a terminal display method applied to a terminal, including: accessing a storage space of a target application through a target interface; receiving a fault degree of the target interface sent by a server and displaying.

[0008] In a third aspect, the present application discloses an interface analysis device applied to a server, including: an obtaining module for obtaining a response loss value when a target interface is tested; a determining module for determining a fault degree of the target interface based on the response loss value and a response loss threshold.

[0009] In a fourth aspect, the present application discloses a terminal display device applied to a terminal, including: an accessing module for accessing a storage space of a target application through a target interface; a receiving module for receiving a fault degree of the target interface sent by a server and displaying.

[0010] In a fifth aspect, an electronic device is provided, which includes a processor and a memory. The memory stores programs or instructions executable on the processor. The programs or instructions, when executed by the processor, implement the steps of the method according to the first aspect or the second aspect.

[0011] In a sixth aspect, a readable storage medium is provided, which stores programs or instructions. The programs or instructions, when executed by a processor, implement the steps of the method according to the first aspect or the second aspect.

[0012] In a seventh aspect, a computer program product is provided, which includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions that, when executed by a computer, cause the computer to perform the steps of the method according to the first aspect or the second aspect.

[0013] The technical solutions adopted by the present application can achieve the following beneficial effects:

[0014] The embodiments of the present application provide an interface analysis method. A server acquires a response loss value when a target interface is tested, and then determines the fault degree of the target interface based on the response loss value and a response loss threshold. By using the solutions of the present application, the fault degree of the interface can be determined, and the analysis of the interface can be realized. BRIEF DESCRIPTION OF DRAWINGS

[0015] Figure 1 A flowchart of an interface analysis method disclosed by the embodiments of the present application is shown in the figure;

[0016] Figure 2 A flowchart of a terminal display method disclosed by the embodiments of the present application is shown in the figure;

[0017] Figure 3 A structural diagram of an interface analysis device disclosed by the embodiments of the present application is shown in the figure;

[0018] Figure 4 A structural diagram of a terminal display device disclosed by the embodiments of the present application is shown in the figure;

[0019] Figure 5 A structural diagram of an electronic device disclosed by the embodiments of the present application is shown in the figure. DETAILED DESCRIPTION

[0020] With reference to the drawings and the embodiments of the present application, the technical solutions in the embodiments of the present application will be clearly described. Obviously, the described embodiments are only some of the embodiments of the present application, but not all of them. Based on the embodiments of the present application, all other embodiments obtained by those of ordinary skill in the art are within the scope of protection of the present application.

[0021] The terms "first", "second", and the like in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than that illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally a category, not limited to the number of objects, for example, the first object can be one or more. In addition, "and / or" in the specification and claims means at least one of the objects connected electrically, and the character " / " generally represents an "or" relationship between the objects before and after it.

[0022] The interface analysis method and the terminal display method disclosed by the embodiments of the present application will be described in detail below in combination with the drawings and specific embodiments and application scenarios.

[0023] The present application discloses an interface analysis method, applied to a server, Figure 1 A flowchart of an interface analysis method disclosed by the embodiments of the present application is shown in FIG. 1. Figure 1 As shown in the figure, the method comprises the following steps:

[0024] S120, obtaining a response loss value when the target interface is tested.

[0025] The target interface is an interface used by the terminal to access the storage space of the target application.

[0026] By way of example, the target application can be a cloud note. It should be noted that the terminal can be a user domain, and the storage space of the cloud note can be a compatible base of the cloud note. Domain is a computer-specific term, which refers to an independent unit running in a Windows network. Domain can be a logical organization unit of a Windows network operating system, or a logical organization unit of the Internet. In the Windows network operating system, domain is a security boundary.

[0027] In the present application, the server obtains the response loss value when the target interface is tested, in the case that the terminal accesses the storage space of the target application through the target interface (i.e. connects the target interface with the storage space of the target application).

[0028] S140, determining the fault degree of the target interface based on the response loss value and a response loss threshold.

[0029] It should be noted that the response loss threshold can be a value pre-set according to actual needs.

[0030] In the present application, the fault degree of the target interface can be determined by comparing the response loss value during the target interface test with the response loss threshold.

[0031] The embodiments of the present application provide an interface analysis method, a server obtains a response loss value during a target interface test, and then determines the fault degree of the target interface based on the response loss value and a response loss threshold. By using the scheme of the present application, the fault degree of the interface can be determined, and the analysis of the interface can be realized.

[0032] In an implementation manner, the obtaining of the response loss value during the target interface test can include: obtaining a benchmark transmission duration and a benchmark throughput rate of the target interface during a benchmark test; obtaining a load transmission duration and a load throughput rate of the target interface during a load test; and determining the response loss value of the target interface during the test based on the benchmark transmission duration, the benchmark throughput rate, the load transmission duration and the load throughput rate.

[0033] In the present application, the benchmark test of the target interface is a test of the target interface when the CPU, memory and the like corresponding to the terminal are in normal operating conditions; and the load test of the target interface is a test of the target interface when the CPU or memory corresponding to the terminal is in full load / saturation.

[0034] When the target interface is tested, the server can send prompt information to the terminal, and the user can select a corresponding test file through the display interface of the terminal in the case that the terminal receives the prompt information. The test file is stored in the storage space of the terminal, and the storage space of the terminal stores a plurality of test files and file sizes corresponding to the test files, i.e., the file size of each test file is pre-known.

[0035] In the benchmark test of the target interface, after the user selects the test file, the test file is simulated to be transmitted through the target interface, which means that the test file is transmitted from the terminal to the target address through the target interface. The target address is mainly used to store the transmitted test file, and the target address will be cleaned up at the end of the test file transmission. The start transmission time and the end transmission time are recorded. The end transmission time is subtracted from the start transmission time to obtain the benchmark transmission time JCTi of the test file transmitted by the target interface corresponding to the terminal. At the same time, a fixed test duration is set, and the number of files, the number of processing transactions and the number of user accesses through the target interface in the test duration are counted, so as to obtain the file transmission amount, the number of processing transactions and the number of user accesses through the target interface in the test duration. The file transmission amount is compared with the test duration to obtain the benchmark file throughput rate JWTi of the target interface per unit time. Similarly, the benchmark transaction throughput rate JSTi and the benchmark user throughput rate JYTi of the target interface per unit time are obtained. Then, the benchmark throughput rate JTTi of the target interface per unit time is obtained, that is, JTTi = JWTi + JSTi + JYTi.

[0036] It should be noted that the terminal is configured with a corresponding clock module, which is used to record the time nodes of various transactions.

[0037] In the load test of the target interface, the same process as the benchmark test of the target interface is used to obtain the load transmission time FCTi and the load throughput rate FTTi of the target interface.

[0038] After the server obtains the benchmark transmission time and the benchmark throughput rate of the target interface in the benchmark test, and the load transmission time and the load throughput rate of the target interface in the load test, the server determines the response loss value of the target interface in the test based on the benchmark transmission time, the benchmark throughput rate, the load transmission time and the load throughput rate.

[0039] In an implementation manner, the determination of the response loss value of the target interface in the test based on the benchmark transmission time, the benchmark throughput rate, the load transmission time and the load throughput rate can include: determining a transmission time difference based on the benchmark transmission time and the load transmission time; determining a throughput rate difference based on the benchmark throughput rate and the load throughput rate; and determining the response loss value of the target interface in the test based on the transmission time difference, the benchmark transmission time, a first weight coefficient, the throughput rate difference, the benchmark throughput rate and a second weight coefficient.

[0040] In the present application, the transmission time difference CTCi of the target interface can be obtained by calculating the difference between the reference transmission time and the load transmission time, the throughput difference TTCi of the target interface can be obtained by calculating the difference between the reference throughput and the load throughput, and then the response loss value of the target interface during testing can be calculated wherein a is a first weight coefficient and b is a second weight coefficient.

[0041] In an implementation manner, the determining the failure degree of the target interface based on the response loss value and a response loss threshold can comprise: in a case where the response loss value is greater than the response loss threshold, determining a response loss overrun value of the target interface based on the response loss value and the response loss threshold; and determining the failure degree of the target interface based on the response loss overrun value and sending the failure degree to the terminal.

[0042] In the present application, in a case where the response loss value is greater than the response loss threshold, the response loss overrun value of the target interface can be obtained by subtracting the response loss threshold from the response loss value, then a response loss failure mapping table can be obtained, the response loss failure mapping table can be stored in a database, the response loss failure mapping table comprises a numerical interval and a failure level corresponding to the numerical interval, the numerical interval to which the response loss overrun value of the target interface belongs can be determined by comparing the response loss overrun value of the target interface with the response loss failure mapping table, and then the failure level of the target interface can be determined according to the numerical interval, and the failure level of the target interface is sent to the terminal. It should be noted that the comparison technology in the present application is prior art.

[0043] The response loss failure mapping table can be as follows:

[0044]

[0045] In the above table, X1, X2, X3 and X4 are fixed values, and X1 < X2 < X3 < X4, which are input by the staff, wherein the failure degree of the first failure level is higher than that of the second failure level, and the failure degree of the second failure level is higher than that of the third failure level.

[0046] In the present application, after determining the failure degree of the target interface, the level of the target interface can be adjusted based on the failure degree of the target interface. It should be noted that the higher the failure degree of the target interface, the lower the level of the target interface, the higher the level of the target interface, the more important the file transmitted through the target interface, the lower the level of the target interface, the less important the file transmitted through the target interface, thereby avoiding the problem of important file transmission.

[0047] In an implementation manner, the method can further include: in a case where the response loss value is less than or equal to the response loss threshold, determining that the target interface is in a normal state, and then not performing any operation.

[0048] In an implementation manner, the method can further include: in a case where the response loss value is greater than the response loss threshold, generating an interface switching instruction, where the interface switching instruction is used to instruct to switch an interface used by the terminal to access the storage space of the target application; and sending the interface switching instruction to an interface switching module. That is, in a case where it is determined that the target interface is faulty, the interface switching module is used to switch, so that the terminal accesses the storage space of the target application through another interface, and then a corresponding function is realized, so that the storage space of the target application can normally respond to work. It should be noted that one terminal can correspond to multiple access interfaces.

[0049] In the embodiments of the present application, before the response loss value of the target interface in a test state is acquired, the safety of the target interface can be determined; and the acquiring of the response loss value of the target interface in a test state can include: in a case where it is determined that the target interface is safe, the response loss value of the target interface in a test state is acquired.

[0050] In the present application, in a case where the terminal accesses the storage space of the target application through the target interface (that is, the target interface is connected with the storage space of the target application), the safety of the target interface can be determined, in a case where it is determined that the target interface is safe, the response loss value of the target interface in a test state is acquired, and then the fault degree of the target interface is further determined.

[0051] In a case where it is determined that the target interface is not safe, an interface switching instruction is generated, and the interface switching instruction is sent to an interface switching module.

[0052] In an implementation manner, the determining of the safety of the target interface can include: determining a safety test value corresponding to the target interface based on historical safety data of the target interface, where the historical safety data includes at least one of a number of safety accidents of the target interface, a duration of each safety accident of the target interface, and a number of files damaged in the storage space of the target application caused by the terminal accessing the storage space of the target application through the target interface; determining a test scheme corresponding to the target interface based on the safety test value; obtaining a cloned interface corresponding to the target interface by cloning the target interface; and performing a safety test on the cloned interface based on a test file and the test scheme.

[0053] In the present application, the historical security data of the target interface can be obtained from the database, and then the security test value corresponding to the target interface can be determined. The historical security data of the target interface can include at least one of the number of security incidents of the target interface, the duration of each security incident of the target interface, and the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface. That is, the security test value corresponding to the target interface can be determined based on the number of security incidents of the target interface, the duration of each security incident of the target interface, and the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface. The security test value corresponding to the target interface can also be determined based on two of the number of security incidents of the target interface, the duration of each security incident of the target interface, and the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface. The security test value corresponding to the target interface can also be determined based on the number of security incidents of the target interface, the duration of each security incident of the target interface, and the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface.

[0054] For example, after obtaining the number of security incidents of the target interface, the duration of each security incident of the target interface, and the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface, the security test value AQi corresponding to the target interface can be determined based on the following formula: AQi = (SGi x b1 + ZTi x b2 + SHi x b3) / (b1 + b2 + b3), where i is the number of the interface corresponding to the terminal, i = 1, 2, …, n, SGi is the number of security incidents of the target interface, ZTi is the sum of the duration of each security incident of the target interface, SHi is the number of files causing damage to the storage space of the target application when the terminal accesses the storage space of the target application through the target interface, and b1, b2, and b3 are weight coefficients.

[0055] In the present application, the historical security data of the target interface can also include the number of outages of the terminal accessing the storage space of the target application through the target interface and the duration of each outage.

[0056] After determining the security test value corresponding to the target interface, the test scheme corresponding to the target interface can be determined according to the security test value corresponding to the target interface and the test scheme determination table. The test scheme determination table contains the correspondence between the security test interval and the test scheme. According to the security test interval to which the security test value corresponding to the target interface belongs, the test scheme corresponding to the target interface is determined.

[0057] The test scheme determination table is shown as follows:

[0058]

[0059] In the above table, Y1, Y2, Y3 and Y4 are fixed values, and Y1 < Y2 < Y3 < Y4.

[0060] The test scheme includes a first test scheme, a second test scheme and a third test scheme, different test schemes include different test times, test durations and test intensities, wherein the test times, test durations and test intensities of the first test scheme are higher than the test times, test durations and test intensities of the second test scheme, and the test times, test durations and test intensities of the second test scheme are higher than the test times, test durations and test intensities of the third test scheme. It should be noted that the determination of the high and low of the test intensity can be distinguished by the number of viruses invading the target interface at the same time, and the higher the test intensity, the more viruses invade the target interface at the same time.

[0061] In the present application, cloning technology can be used to copy the target interface to obtain a cloned interface corresponding to the target interface, and then the cloned interface and the test file are imported into a virtual space in the server, so that the cloned interface combines the test scheme to perform security testing, in the virtual space, the test file can be accessed through the cloned interface. If the test file combined with the test scheme does not change through the cloned interface, the cloned interface is safe, and the target interface is safe, if the test file combined with the test scheme changes through the cloned interface, the cloned interface is unsafe, and the target interface is unsafe, an interface switching instruction is generated and sent to the interface switching module.

[0062] In the present application, the cloned interface corresponding to the target interface is used for security testing, compared with directly testing the security of the target interface, the user experience can be avoided when the interface has security problems.

[0063] In an implementation manner, the determining of the security test value corresponding to the target interface based on the historical security data of the target interface can include: verifying the interface number of the target interface based on the interface number allowed to be accessed by the storage space of the target application; and determining the security test value corresponding to the target interface based on the historical security data of the target interface in a case where the verification of the interface number of the target interface is passed.

[0064] In the present application, in the case that the terminal accesses the storage space of the target application through the target interface (i.e. connecting the target interface with the storage space of the target application), the interface number allowed to access the storage space of the target application is acquired, the interface number of the target interface is compared with the interface number allowed to access the storage space of the target application, in the case that the comparison of the interface number of the target interface passes, the security test value corresponding to the target interface is determined based on the historical security data of the target interface, and in the case that the comparison of the interface number of the target interface does not pass, the terminal is refused to access the storage space of the target application through the target interface (i.e. the target interface is refused to be connected with the storage space of the target application).

[0065] In the present application, the comparison can be implemented by using Chinese word segmentation, shape comparison and the like.

[0066] By using the scheme of the present application, the interface corresponding to the terminal can be monitored and detected for security and fault, the normal operation of the terminal is ensured, and the normal response of the storage space of the target application is effectively guaranteed.

[0067] The present application discloses a terminal display method, which is applied to a terminal, Figure 2 A flowchart of the terminal display method disclosed by the present application is shown in FIG. 1. Figure 2 As shown in the figure, the method comprises the following steps:

[0068] S220, accessing the storage space of the target application through the target interface.

[0069] Exemplarily, the target application can be a cloud note.

[0070] S240, receiving and displaying the fault degree of the target interface sent by the server.

[0071] Exemplarily, in the case that the fault degree of the target interface is the third fault level, the target interface is displayed as the third fault level.

[0072] The present application provides a terminal display method, the terminal accesses the storage space of the target application through the target interface, then receives and displays the fault degree of the target interface sent by the server, and realizes fault early warning.

[0073] In an implementation manner, after the step of accessing the storage space of the target application through the target interface, and before the step of receiving and displaying the fault degree of the target interface sent by the server, the method can further comprise the following steps: receiving prompt information sent by the server, the prompt information being used for indicating to test the target interface; in response to receiving the prompt information, displaying a selectable test file; receiving a determination operation on the selectable test file; and sending the selected test file to the server.

[0074] The interface analysis method provided in the embodiments of the present application can be executed by an interface analysis device. The interface analysis device provided in the embodiments of the present application is described by taking the interface analysis device executing the interface analysis method as an example.

[0075] The interface analysis device disclosed in the present application is applied to a server.

[0076] Figure 3 FIG. 1 is a structural schematic diagram of an interface analysis device disclosed in the embodiments of the present application. As shown in FIG. 1, the interface analysis device 300 includes an acquisition module 310 and a determination module 320. Figure 3

[0077] In the present application, the acquisition module 310 is configured to acquire a response loss value in a target interface test; and the determination module 320 is configured to determine a fault degree of the target interface based on the response loss value and a response loss threshold.

[0078] In an implementation manner, the acquisition module 310 acquires the response loss value in the target interface test, including: acquiring a reference transmission duration and a reference throughput rate of the target interface in a reference test; acquiring a load transmission duration and a load throughput rate of the target interface in a load test; and determining the response loss value in the target interface test based on the reference transmission duration, the reference throughput rate, the load transmission duration and the load throughput rate.

[0079] In an implementation manner, the acquisition module 310 determines the response loss value in the target interface test based on the reference transmission duration, the reference throughput rate, the load transmission duration and the load throughput rate, including: determining a transmission duration difference value based on the reference transmission duration and the load transmission duration; determining a throughput rate difference value based on the reference throughput rate and the load throughput rate; and determining the response loss value in the target interface test based on the transmission duration difference value, the reference transmission duration, a first weight coefficient, the throughput rate difference value, the reference throughput rate and a second weight coefficient.

[0080] In an implementation manner, the determination module 320 determines the fault degree of the target interface based on the response loss value and the response loss threshold, including: in a case where the response loss value is greater than the response loss threshold, determining a response loss overrun value of the target interface based on the response loss value and the response loss threshold; and determining the fault degree of the target interface based on the response loss overrun value and sending the fault degree to a terminal.

[0081] In an implementation manner, the determination module 320 is further configured to determine that the target interface is in a normal state in a case where the response loss value is less than or equal to the response loss threshold.

[0082] ​In an implementation manner, the determining module 320 is further configured to generate an interface switching instruction in a case where the response loss value is greater than a response loss threshold, where the interface switching instruction is used to instruct to switch an interface used by the terminal to access the storage space of the target application; and the determining module 320 is further configured to send the interface switching instruction to an interface switching module.

[0083] In an implementation manner, the determining module 320 is further configured to determine the security of the target interface before the response loss value of the target interface during the test is acquired; and the acquiring module 310 acquires the response loss value of the target interface during the test, including: in a case where the security of the target interface is determined, acquiring the response loss value of the target interface during the test.

[0084] In an implementation manner, the determining module 320 determines the security of the target interface, including: determining a security test value corresponding to the target interface based on historical security data of the target interface, where the historical security data includes at least one of a number of security accidents of the target interface, a duration of each security accident of the target interface, and a number of files damaged in the storage space of the target application caused by the terminal accessing the storage space of the target application through the target interface; determining a test scheme corresponding to the target interface based on the security test value; obtaining a cloned interface corresponding to the target interface by cloning the target interface; and performing a security test on the cloned interface based on a test file and the test scheme.

[0085] In an implementation manner, the determining module 320 determines the security test value corresponding to the target interface based on the historical security data of the target interface, including: verifying an interface number of the target interface based on an interface number allowed to access the storage space of the target application; and in a case where the verification of the interface number of the target interface is passed, determining the security test value corresponding to the target interface based on the historical security data of the target interface.

[0086] The interface analysis device provided by the embodiments of the present application can implement all the processes of the interface analysis method, and thus, details are not described herein again.

[0087] The terminal display method provided by the embodiments of the present application can be executed by the terminal display device. The terminal display device is taken as an example to illustrate the terminal display method provided by the embodiments of the present application.

[0088] The terminal display device disclosed by the embodiments of the present application is applied to a terminal.

[0089] Figure 4 FIG. 1 is a structural schematic diagram of a terminal display device disclosed by the embodiments of the present application. As shown in FIG. 1, the terminal display device includes a terminal display device 100. Figure 4As shown, the terminal display device 400 comprises an access module 410 and a receiving module 420.

[0090] In the present application, the access module 410 is configured to access a storage space of a target application through a target interface; and the receiving module 420 is configured to receive a failure degree of the target interface sent by a server and display the failure degree.

[0091] The terminal display device provided by the embodiments of the present application can realize the various processes realized by the terminal display method embodiments, and thus, details are not repeated here.

[0092] Optionally, as shown, Figure 5 The embodiments of the present application also provide an electronic device 500, which comprises a processor 501 and a memory 502, and the memory 502 stores a program or instructions which can be run on the processor 501. When the program or instructions are executed by the processor 501, the various steps of the above interface analysis method embodiments are realized, or when the program or instructions are executed by the processor 501, the various steps of the above terminal display method embodiments are realized, and the same technical effects can be achieved. To avoid repetition, details are not repeated here.

[0093] It should be noted that the electronic device in the embodiments of the present application includes a mobile electronic device and a non-mobile electronic device.

[0094] The embodiments of the present application also provide a readable storage medium, which stores a program or instructions. When the program or instructions are executed by a processor, the various processes of the above interface analysis method embodiments are realized, or when the program or instructions are executed by the processor, the various processes of the above terminal display method embodiments are realized, and the same technical effects can be achieved. To avoid repetition, details are not repeated here.

[0095] The processor is the processor in the electronic device in the above embodiments. The readable storage medium includes a computer readable storage medium, such as a computer readable only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0096] The embodiments of the present application also provide a computer program product, which comprises a computer program stored on a non-transitory computer readable storage medium. The computer program comprises program instructions, and when the program instructions are executed by a computer, the computer executes the steps of the above interface analysis method or the steps of the above terminal display method.

[0097] In the above embodiments of the present application, the differences between the various embodiments are mainly described. The different optimization features between the various embodiments can be combined to form a more optimal embodiment as long as they are not contradictory. To consider the brevity of the writing, details are not repeated here.

[0098] The above merely provides an example of the present application, but is not intended to limit the present application. The present application can have various modifications and changes for those skilled in the art. Any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application shall be included in the scope of claims of the present application.

Claims

1. An interface analysis method characterized by, Applied to a server, comprising: obtaining a response loss value when a target interface is tested; determining a fault degree of the target interface based on the response loss value and a response loss threshold; the obtaining of the response loss value when the target interface is tested, comprising: obtaining a benchmark transmission duration and a benchmark throughput rate of the target interface when a benchmark test is performed; obtaining a load transmission duration and a load throughput rate of the target interface when a load test is performed; determining the response loss value when the target interface is tested based on the benchmark transmission duration, the benchmark throughput rate, the load transmission duration, the load throughput rate, a first weight coefficient and a second weight coefficient.

2. The method of claim 1, wherein, the determining of the response loss value when the target interface is tested based on the benchmark transmission duration, the benchmark throughput rate, the load transmission duration, the load throughput rate, a first weight coefficient and a second weight coefficient, comprising: determining a transmission duration difference value based on the benchmark transmission duration and the load transmission duration; determining a throughput rate difference value based on the benchmark throughput rate and the load throughput rate; determining the response loss value when the target interface is tested based on the transmission duration difference value, the benchmark transmission duration, a first weight coefficient, the throughput rate difference value, the benchmark throughput rate and a second weight coefficient.

3. The method of claim 1, wherein, the determining of the fault degree of the target interface based on the response loss value and the response loss threshold, comprising: in the case that the response loss value is greater than the response loss threshold, determining a response loss overrun value of the target interface based on the response loss value and the response loss threshold; determining the fault degree of the target interface based on the response loss overrun value and sending the fault degree to a terminal.

4. The method of claim 3, wherein, further comprising: in the case that the response loss value is less than or equal to the response loss threshold, determining that the target interface is in a normal state.

5. The method of claim 3, wherein, further comprising: in the case that the response loss value is greater than the response loss threshold, generating an interface switching instruction, wherein the interface switching instruction is used to instruct to switch an interface used by the terminal to access a storage space of a target application; sending the interface switching instruction to an interface switching module.

6. The method of claim 1, wherein, before the obtaining of the response loss value when the target interface is tested, further comprising: determining the security of the target interface; the obtaining of the response loss value when the target interface is tested, comprising: in the case that the target interface is determined to be secure, obtaining the response loss value when the target interface is tested.

7. The method of claim 6, wherein, the determining of the security of the target interface, comprising: determining a security test value corresponding to the target interface based on historical security data of the target interface, wherein the historical security data comprises at least one of a number of security accidents of the target interface, a duration of each security accident of the target interface, and a number of files damaged in a storage space of a target application accessed by a terminal through the target interface; determining a test scheme corresponding to the target interface based on the security test value; obtaining a cloned interface corresponding to the target interface by cloning the target interface; performing a security test on the cloned interface based on a test file and the test scheme.

8. The method of claim 7, wherein, The target interface-based historical security data is used to determine a security test value corresponding to the target interface, including: Verifying the interface number of the target interface based on the interface number allowed to access the storage space of the target application; In the case that the interface number of the target interface is verified, the target interface-based historical security data is used to determine a security test value corresponding to the target interface.

9. A terminal display method characterized by comprising: Applied to a terminal, including: Accessing a storage space of a target application through a target interface; Receiving and displaying a failure degree of the target interface sent by a server, wherein the failure degree of the target interface is determined based on a response loss value when the target interface is tested and a response loss threshold, and the response loss value when the target interface is tested is determined based on a benchmark transmission duration of the target interface when a benchmark test is performed, a benchmark throughput rate of the target interface when the benchmark test is performed, a load transmission duration of the target interface when a load test is performed, a load throughput rate of the target interface when the load test is performed, a first weight coefficient, and a second weight coefficient.

10. An interface analysis apparatus characterized by comprising: Applied to a server, including: An obtaining module, configured to obtain a response loss value when a target interface is tested; A determining module, configured to determine a failure degree of the target interface based on the response loss value and a response loss threshold; The obtaining module obtains a response loss value when a target interface is tested, including: obtaining a benchmark transmission duration and a benchmark throughput rate of the target interface when a benchmark test is performed; obtaining a load transmission duration and a load throughput rate of the target interface when a load test is performed; and determining the response loss value when the target interface is tested based on the benchmark transmission duration, the benchmark throughput rate, the load transmission duration, the load throughput rate, a first weight coefficient, and a second weight coefficient.

11. A terminal display device, characterized by comprising: Applied to a terminal, including: An accessing module, configured to access a storage space of a target application through a target interface; A receiving module, configured to receive and display a failure degree of the target interface sent by a server, wherein the failure degree of the target interface is determined based on a response loss value when the target interface is tested and a response loss threshold, and the response loss value when the target interface is tested is determined based on a benchmark transmission duration of the target interface when a benchmark test is performed, a benchmark throughput rate of the target interface when the benchmark test is performed, a load transmission duration of the target interface when a load test is performed, a load throughput rate of the target interface when the load test is performed, a first weight coefficient, and a second weight coefficient.

12. An electronic device, comprising: A processor and a memory, the memory stores programs or instructions executable on the processor, and the programs or instructions are executed by the processor to implement steps of the interface analysis method according to any one of claims 1-8, or the programs or instructions are executed by the processor to implement steps of the terminal display method according to claim 9.

13. A readable storage medium, characterized by, The readable storage medium stores programs or instructions, and the programs or instructions are executed by the processor to implement steps of the interface analysis method according to any one of claims 1-8, or the programs or instructions are executed by the processor to implement steps of the terminal display method according to claim 9.

14. A computer program product, characterised in that, The computer program product comprises a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, cause the computer to carry out the steps of the interface analysis method according to any one of claims 1 to 8, or the steps of the terminal display method according to claim 9.

Citation Information

Patent Citations

  • Application interface time consumption test method and system and electronic equipment

    CN114398281A

  • Business poor quality fault diagnosis method, device and equipment, terminal and storage medium

    CN116915577A