Method, device, electronic device and storage medium for determining code changes

By monitoring application code changes and call changes, the high-risk problem during the upgrade and iteration process is solved, automated and intuitive monitoring is achieved, and the risk of application upgrade and iteration is reduced.

CN114327577BActive Publication Date: 2025-09-09BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202111632713.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-29
Publication Date
2025-09-09
Estimated Expiration
2041-12-29

AI Technical Summary

Technical Problem

During the application upgrade and iteration process, due to changes in the calls of basic functional modules and APIs, the upgrade and iteration risks are high and difficult to discover and monitor during the development and testing phase.

Method used

By determining the changes between the first code and the second code, the second change related to the call change of the monitored object is further determined, the call change is monitored using code comparison tools and target monitoring functions, and intuitive prompt information is sent to the monitoring user to reduce the risk of upgrade iteration.

Benefits of technology

It achieves automated, comprehensive and intuitive monitoring of call changes, reduces the risk of application upgrade iterations, and improves the accuracy and efficiency of monitoring.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114327577B_ABST
    Figure CN114327577B_ABST
Patent Text Reader

Abstract

The present disclosure provides a method, device, electronic device, readable storage medium and computer program product for determining code changes, and relates to the field of intelligent search. The specific implementation scheme is: determining a first change of a first code relative to a second code, the first code and the second code are different versions of codes compiled for a target application, and the first change is used to represent the code change between the first code and the second code; in the first change, determining a second change related to the call change of the object to be monitored, the object to be monitored is a monitoring object preset for the target application, the call change is used to represent the change in the call of the object to be monitored, and the second change is used to represent the code change related to the call change. This scheme can monitor the call changes of the object to be monitored more comprehensively and intuitively.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to artificial intelligence and intelligent search technology, and can be used in scenarios such as artificial intelligence and intelligent search. Background Art

[0002] With the rapid development of computing and internet technologies, more and more applications have been developed to provide users with a variety of services. In the process of providing services to users, applications often need to be continuously upgraded and iterated in order to promptly fix existing problems or add new service features.

[0003] During application upgrades and iterations, changes in the call paths of some basic functional modules and application programming interfaces (APIs) often have a significant impact on the application. Therefore, the emergence of these call path changes often brings greater risks to application upgrades and iterations. Summary of the Invention

[0004] The present disclosure provides a method, apparatus, electronic device, readable storage medium, and computer program product for determining code changes, so as to comprehensively and intuitively monitor the call changes of the monitored object.

[0005] According to one aspect of the present disclosure, a method for determining a code change is provided, which may include the following steps:

[0006] Determining a first change of a first code relative to a second code, where the first code and the second code are different versions of codes compiled for a target application, and the first change indicates a code change between the first code and the second code;

[0007] In the first change situation, the second change situation related to the call change of the object to be monitored is determined. The object to be monitored is a monitoring object preset for the target application. The call change is used to indicate the change in the call of the object to be monitored, and the second change situation is used to indicate the code change related to the call change.

[0008] According to a second aspect of the present disclosure, a device for determining a code change is provided, which may include:

[0009] a first change determination unit, configured to determine a first change of a first code relative to a second code, the first code and the second code being different versions of codes compiled for a target application, the first change indicating a code change between the first code and the second code;

[0010] The second change situation determination unit is used to determine the second change situation related to the call change of the object to be monitored in the first change situation. The object to be monitored is a monitoring object preset for the target application. The call change is used to indicate the change in the call of the object to be monitored, and the second change situation is used to indicate the code change related to the call change.

[0011] According to another aspect of the present disclosure, there is provided an electronic device, comprising:

[0012] at least one processor; and

[0013] a memory communicatively connected to the at least one processor; wherein,

[0014] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method in any embodiment of the present disclosure.

[0015] According to another aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided. The computer instructions are used to cause a computer to execute the method in any embodiment of the present disclosure.

[0016] According to another aspect of the present disclosure, a computer program product is provided, including a computer program / instruction, wherein the computer program / instruction implements the method in any embodiment of the present disclosure when executed by a processor.

[0017] The technology disclosed herein, after determining the code changes between the first code and the second code, can further determine the code changes related to the call changes of the object to be monitored based on the code changes between the first code and the second code. The technology disclosed herein can automatically monitor the code changes related to the call changes of the object to be monitored, and based on the code changes related to the call changes, can more comprehensively and intuitively monitor the call changes of the object to be monitored.

[0018] In addition, based on the code changes related to the call changes, it is possible to further detect whether the call changes of the monitored objects will have an adverse impact on the upgrade and iteration of the application. This reduces the risk of the call changes of the monitored objects on the upgrade and iteration of the application.

[0019] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The accompanying drawings are used to better understand the present invention and do not constitute a limitation of the present invention.

[0021] Figure 1 A flowchart of a method for determining code changes is provided for an embodiment of the present disclosure;

[0022] Figure 2 This is a flowchart of a method for determining a second change situation provided in an embodiment of the present disclosure;

[0023] Figure 3 This is a flowchart of a sending method for a second change situation provided in an embodiment of the present disclosure;

[0024] Figure 4 A schematic diagram of a device for determining a code change is provided for an embodiment of the present disclosure;

[0025] Figure 5 A schematic diagram of an electronic device provided in accordance with an embodiment of the present disclosure. DETAILED DESCRIPTION

[0026] The following description of exemplary embodiments of the present disclosure is made in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding. These details should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0027] Thanks to the rapid development of computing and internet technologies, intelligent computing devices are becoming increasingly prevalent in our daily lives. Simultaneously, a large number of applications running on these devices have been developed to provide users with a wide range of services. However, in the process of providing services, these applications often require continuous upgrades and iterations to fix bugs or add new features.

[0028] However, as applications continue to provide services to users for longer periods of time, their scale often grows, and the risks faced by applications during iterative upgrades also increase. Specifically, as the scale of an application grows, changes in the invocation of some basic functional modules and APIs within the application often directly or indirectly impact multiple other functional modules and APIs, which in turn significantly impact the application itself. Therefore, when risks arise in the invocation of basic functional modules and APIs, they often also pose risks to application upgrades.

[0029] Therefore, to mitigate the risks associated with application upgrades and iterations caused by changes in calls to basic functional modules and APIs, it is necessary to monitor these changes. However, as applications scale, their code base often grows, and some changes are not reflected in the business presentation layer. Therefore, these changes are often difficult to detect during the development and testing phases.

[0030] In addition, since the changes in the calls of some basic functional modules and APIs do not have a direct impact on the service functions of the application, they are often easily overlooked by testers during the development and testing phase.

[0031] In order to solve the above problems, the embodiment of the present disclosure provides a method for determining code changes. Figure 1 , which is a flowchart of a method for determining code changes according to an embodiment of the present disclosure. The method may include the following steps:

[0032] Step S101: determining a first change of a first code relative to a second code, where the first code and the second code are different versions of codes compiled for a target application, and the first change indicates a code change between the first code and the second code.

[0033] Step S102: In the first change situation, determine the second change situation related to the call change of the object to be monitored, the object to be monitored is the monitoring object preset in the target application, the call change is used to indicate the change of the call of the object to be monitored, and the second change situation is used to indicate the code change related to the call change.

[0034] The method for determining code changes provided in the embodiments of the present disclosure, after determining the code changes between the first code and the second code, can further determine the code changes related to the call changes of the object to be monitored based on the code changes between the first code and the second code. The technology disclosed in the present disclosure can automatically monitor the code changes related to the call changes of the object to be monitored, and based on the code changes related to the call changes, it can more comprehensively and intuitively monitor the call changes of the object to be monitored.

[0035] In addition, based on the code changes related to the call changes, it is possible to further detect whether the call changes of the monitored objects will have an adverse impact on the upgrade and iteration of the application. This reduces the risk of the call changes of the monitored objects on the upgrade and iteration of the application.

[0036] The so-called first code and second code are different versions of code compiled by product developers and maintainers for the target application to implement iterative product upgrades. The code version of the first code is higher than the code version of the second code. Specifically, for different versions of the target application, "Target Application Version 1.0" and "Target Application Version 1.1," the first code is the code for "Target Application Version 1.1," and the second code is the code for "Target Application Version 1.0."

[0037] The so-called objects to be monitored include but are not limited to functional modules and APIs in the target application.

[0038] In an embodiment of the present disclosure, a specific implementation method for determining a first change situation of a first code relative to a second code may be: first, comparing the first code with the second code to determine a first change point between the first code and the second code, and then determining the first change point as the first change situation.

[0039] For different versions of the target application code, the code changes between the two versions may be more. In addition, for applications with larger product scales, the code scales of the first code and the second code are also often larger, so the code changes may also be more complicated.

[0040] In order to more clearly and concisely represent the first change, after comparing the first code with the second code, the change points between the codes may be screened out, and the change points between the codes may be used as the first change.

[0041] In addition, determining the first change point as the first change situation can also reduce the workload and complexity of determining the second change situation in the first change situation.

[0042] In the specific implementation process, the first code and the second code can be compared using a code comparison tool, such as a version control system (Subversion, SVN). In addition, in the embodiments of the present disclosure, there is no specific limitation on the code comparison tool, as long as the code changes between different versions of the code can be clearly and completely obtained.

[0043] In the embodiment of the present disclosure, since some code change points in the first change point do not cause the call change of the monitored object, in order to allow relevant personnel to more accurately and specifically determine the call change of the monitored object, the code change points that affect the call change of the monitored object can be further obtained in the first change point. The specific implementation process is as follows:

[0044] First, a second change point related to the call change is determined in the first change point, where the second change point represents a change point of the call code between the first code and the second code, where the call code is a code for calling the monitored object. Then, the second change point is determined as the second change situation.

[0045] In applications, functions in a certain function module or API are often used to call functions in other function modules or APIs, thus realizing the mutual calling of different function modules and APIs. Therefore, in order to more intuitively and conveniently determine whether the monitored object has undergone call changes, it can be achieved by monitoring the preset target monitoring function for the monitored object. For specific implementation methods, please refer to Figure 2 , Figure 2 This is a flow chart of a method for determining a second change situation provided in an embodiment of the present disclosure. The steps for determining the second change situation include:

[0046] Step S201: obtaining a target monitoring function preset for the object to be monitored.

[0047] Step S202: At the first change point, determine the code segment that changes the function call relationship of calling the target function.

[0048] Step S203: Determine the code segment as the second change point.

[0049] The target monitoring function may be one or more functions in the object to be monitored. For example, when the object to be monitored is an API, the target monitoring function may be at least one execution function in the API. In the embodiments of the present disclosure, there are no specific restrictions on the function type and number of target monitoring functions. Specifically, the target monitoring function may be pre-selected based on a priori values.

[0050] The following specifically takes the object to be monitored as a functional module in the target program as an example to explain in detail how to determine the code segment.

[0051] Assume that the target application contains six function modules m1, m2, m3, m4, m5, and m6, where function module m1 is the target to be monitored. m1 has a target monitoring function F1 (represented by m1(F1)), and its F1 function has a parameter p (represented by m1(F1:p)).

[0052] When the second code is: m6(F18: "This is a user's account") → m3(F3: p1) → m1(F1: p), the function call relationship described by the second code for F1 is: function F18 in m6 calls function parameter p1 of function F3 in m3, and the calling parameter is "This is a user's account"; function parameter p1 of function F3 in m3 calls function parameter p of function F1 in m1.

[0053] When the first code is: m6 (F18: "This is a user account") → m3 (F3: p1), the second change is: the call code to function F1 in m1 is deleted. At this time, the function call relationship changes to: function F3 in m3, the call to function F1 in m1 is deleted; the code segment is: code segment with a deletion mark: → m1 (F1: p), where this code segment carries the deletion mark.

[0054] When the first code adds a call code: m3(F4)→m1(F1:x), the second change is: a new call code to function F1 in m1: m3(F4)→m1(F1:x). At this time, the function call relationship changes to: a new function call to function F1 in m1; the code segment is: m3(F4)→m1(F1:x).

[0055] The above two changes in the function call relationship of the target function are both direct changes in the function call relationship.

[0056] Furthermore, when the first code is: m6(F18: "This is a test account") → m3(F3: p1) → m1(F1: p), the second change is: function F18 in m6 calls function F3 in m3, and the parameter of function parameter P1 changes from "This is a user account" to "This is a test account." At this point, the function call relationship changes as follows: function F18 in m6 calls function F3 in m3, and the parameter of function parameter p1 changes from "This is a user account" to "This is a test account." The code segment is the code segment where the call parameter "This is a test account" is marked for deletion: m6(F18: "This is a test account" "This is a test account"), where the call parameter "This is a test account" carries the deletion mark.

[0057] When the first code is: m6 (F18: "This is a user account") → m3 (F3: p1) → m1 (F1: liu), the second change point is: the function parameter P1 of function F3 in m3, which is called in function F1 in m1, is changed from p to liu. At this time, the function call relationship changes as follows: the function parameter P1 of function F3 in m3 is changed from calling function parameter p of function F1 in m1 to calling function parameter liu of function F1 in m1; the code segment is the code segment with the function parameter "p" marked for deletion: m1 (F1: pliu), where function p carries the deletion mark.

[0058] The above two changes in the function call relationship of the target function are both indirect changes in the function call relationship.

[0059] In order to enable relevant personnel to better monitor whether the call changes of the monitored object will have an adverse impact on the upgrade and iteration of the application based on the code changes related to the call changes, a monitoring user can be pre-set for the monitored object. After determining the second change situation, the second change situation is further sent to the computing device corresponding to the monitoring user. The specific implementation method is: first, obtain the preset monitoring user for the monitored object; then, send the second change situation to the computing device corresponding to the monitoring user.

[0060] By sending the second change situation to the computing device corresponding to the monitored user, not only can the monitored user be reminded to monitor the call changes of the monitored object based on the code changes related to the call changes to see whether they will have an adverse impact on the upgrade and iteration of the application, but the purpose of targeted monitoring of the call changes of the monitored object can also be achieved.

[0061] In order to enable the monitoring user to obtain and understand the second change more intuitively, so as to be able to more accurately monitor the call changes of the monitored object based on the code changes related to the call changes. In the embodiment of the present disclosure, the second change situation can be sent to the computing device corresponding to the monitoring user through the following steps. For details, please refer to Figure 3 , Figure 3 This is a flow chart of a method for sending a second change situation provided in an embodiment of the present disclosure. The steps include:

[0062] Step S301: Generate prompt information for the second change situation in a preset manner, where the prompt information is used to prompt the monitoring user of the second change situation.

[0063] Step S302: Send prompt information to the computing device.

[0064] The so-called preset method includes but is not limited to a method of highlighting code changes related to call changes, a method of underlining code changes related to call changes, a method of bolding code changes related to call changes, and a method of adding a mark box to code changes related to call changes.

[0065] The so-called implementation method of sending the prompt information to the computing device includes: sending the prompt information to the computing device logged in by the target account of the monitoring user. The target account includes but is not limited to an email account and a mobile phone account.

[0066] like Figure 4 As shown, an embodiment of the present disclosure provides a device for determining a code change, the device comprising:

[0067] A first change determination unit 401 is configured to determine a first change of a first code relative to a second code, where the first code and the second code are different versions of code compiled for a target application, and the first change indicates a code change between the first code and the second code;

[0068] The second change situation determination unit 402 is used to determine the second change situation related to the call change of the object to be monitored in the first change situation. The object to be monitored is a monitoring object preset for the target application. The call change is used to indicate the change in the call of the object to be monitored, and the second change situation is used to indicate the code change related to the call change.

[0069] In one embodiment, the first change situation determining unit 401 may further include:

[0070] a first change point determination subunit, configured to compare the first code with the second code and determine a first change point of the code between the first code and the second code;

[0071] The first change situation determining subunit is configured to determine the first change point as the first change situation.

[0072] In one embodiment, the second change situation determining unit 402 may further include:

[0073] A second change point determination subunit is configured to determine, from the first change point, a second change point associated with the call change, the second change point being used to indicate a change point of the call code between the first code and the second code, the call code being a code for calling the object to be monitored;

[0074] The second change situation determining subunit is configured to determine the second change point as the second change situation.

[0075] In one embodiment, the second change point determination subunit may further include:

[0076] The monitoring function obtaining subunit is used to obtain a target monitoring function preset for the object to be monitored;

[0077] a code segment determining subunit, configured to determine, at a first change point, a code segment that causes a function call relationship of calling a target function to change;

[0078] The third change point determination subunit is configured to determine the code segment as the second change point.

[0079] In one embodiment, the apparatus may further include:

[0080] A monitoring user obtaining unit, configured to obtain a monitoring user preset for the object to be monitored;

[0081] The second change situation sending unit is used to send the second change situation to the computing device corresponding to the monitoring user.

[0082] In one embodiment, the second change status sending unit may further include:

[0083] a prompt information generating subunit, configured to generate prompt information for the second change situation in a preset manner, wherein the prompt information is information for notifying the monitoring user of the second change situation;

[0084] The prompt information sending subunit is used to send prompt information to the computing device.

[0085] In the technical solutions disclosed herein, the acquisition, storage, and application of user personal information involved comply with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0086] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.

[0087] Figure 5 A schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0088] like Figure 5As shown, the device 500 includes a computing unit 501, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 502 or a computer program loaded from a storage unit 508 into a random access memory (RAM) 503. Various programs and data required for the operation of the device 500 can also be stored in the RAM 503. The computing unit 501, the ROM 502, and the RAM 503 are connected to each other via a bus 504. An input / output (I / O) interface 505 is also connected to the bus 504.

[0089] Various components in device 500 are connected to I / O interface 505, including: an input unit 506, such as a keyboard, mouse, etc.; an output unit 507, such as various types of displays, speakers, etc.; a storage unit 508, such as a magnetic disk, optical disk, etc.; and a communication unit 509, such as a network card, modem, wireless communication transceiver, etc. The communication unit 509 allows device 500 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0090] The computing unit 501 can be a variety of general-purpose and / or specialized processing components with processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units that run machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 501 performs the various methods and processes described above, such as the method for determining code changes. For example, in some embodiments, the method for determining code changes can be implemented as a computer software program that is tangibly contained in a machine-readable medium, such as the storage unit 508. In some embodiments, part or all of the computer program can be loaded and / or installed on the device 500 via the ROM 502 and / or the communication unit 509. When the computer program is loaded into the RAM 503 and executed by the computing unit 501, one or more steps of the method for determining code changes described above can be performed. Alternatively, in other embodiments, the computing unit 501 can be configured to perform the method for determining code changes by any other appropriate means (e.g., by means of firmware).

[0091] Various embodiments of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), system-on-chip systems (SOCs), programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0092] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. Such program code can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable code change determination device, so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0093] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in conjunction with an instruction execution system, device or equipment. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium can include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0094] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0095] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0096] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact through a communication network. The client-server relationship arises through computer programs running on the respective computers and having a client-server relationship with each other. The server may be a cloud server, a server in a distributed system, or a server integrated with a blockchain.

[0097] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved. This is not a limitation herein.

[0098] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.

Claims

1. A method for determining a code change, comprising: Determining a first change of a first code relative to a second code, where the first code and the second code are different versions of code compiled for a target application, and the first change indicates a code change between the first code and the second code; Determining, in the first change situation, a second change situation related to a call change of a to-be-monitored object, where the to-be-monitored object is a monitoring object preset for the target application, the call change being used to indicate a change in a call to the to-be-monitored object, and the second change situation being used to indicate a code change related to the call change; The object to be monitored includes a functional module in the target application, and in the first change situation, determining a second change situation related to a call change of the object to be monitored includes: In the first change scenario, determining a code change point that affects the call change of the functional module; The second change situation is determined based on the code change point that affects the call change of the functional module.

2. The method according to claim 1, wherein Determining a first change of the first code relative to the second code includes: Comparing the first code with the second code to determine a first change point between the first code and the second code; The first change point is determined as the first change situation.

3. The method according to claim 2, wherein: The step of determining the second change situation includes: Among the first change points, determining a second change point related to the call change, wherein the second change point is used to represent a change point of a call code between the first code and the second code, the call code being a code for calling the object to be monitored; The second change point is determined as the second change situation.

4. The method according to claim 3, wherein: The determining a second change point related to the call change includes: Obtaining a preset target monitoring function for the object to be monitored; In the first change point, determining a code segment that changes a function call relationship for calling the target monitoring function; The code segment is determined as the second change point.

5. The method according to any one of claims 1 to 4, wherein: The method further comprises: Obtaining a preset monitoring user for the object to be monitored; The second change condition is sent to a computing device corresponding to the monitoring user.

6. The method according to claim 5, wherein: The sending the second change condition to the computing device corresponding to the monitoring user includes: Generate prompt information for the second change in a preset manner, where the prompt information is used to notify the monitoring user of the second change; The prompt information is sent to the computing device.

7. A device for determining a code change, comprising: a first change determination unit, configured to determine a first change of a first code relative to a second code, the first code and the second code being different versions of codes compiled for a target application, the first change indicating a code change between the first code and the second code; a second change situation determining unit, configured to determine, in the first change situation, a second change situation related to a call change of a to-be-monitored object, wherein the to-be-monitored object is a monitoring object preset for the target application, the call change being used to indicate a change in a call to the to-be-monitored object, and the second change situation being used to indicate a code change related to the call change; Among them, the object to be monitored includes the functional module in the target application, and the second change situation determination unit is specifically used to determine the code change points that affect the call changes of the functional module in the first change situation; and determine the second change situation based on the code change points that affect the call changes of the functional module.

8. The device according to claim 7, wherein The first change situation determining unit includes: a first change point determination subunit, configured to compare the first code with the second code to determine a first change point between the first code and the second code; The first change situation determining subunit is configured to determine the first change point as the first change situation.

9. The device according to claim 8, wherein The second change situation determining unit includes: a second change point determination subunit, configured to determine, from among the first change points, a second change point associated with the call change, wherein the second change point is used to indicate a change point of a call code between the first code and the second code, the call code being a code for calling the object to be monitored; The second change situation determining subunit is configured to determine the second change point as the second change situation.

10. The device according to claim 9, wherein The second change point determination subunit includes: A monitoring function obtaining subunit, configured to obtain a target monitoring function preset for the object to be monitored; a code segment determining subunit, configured to determine, at the first change point, a code segment that causes a change in a function call relationship for calling the target monitoring function; The third change point determination subunit is configured to determine the code segment as the second change point.

11. The device according to any one of claims 7 to 10, wherein: The device further comprises: A monitoring user obtaining unit, configured to obtain a monitoring user preset for the object to be monitored; The second change situation sending unit is used to send the second change situation to the computing device corresponding to the monitoring user.

12. The device according to claim 11, wherein The second change condition sending unit includes: a prompt information generating subunit, configured to generate prompt information for the second change in a preset manner, wherein the prompt information is used to notify the monitoring user of the second change; The prompt information sending subunit is used to send the prompt information to the computing device.

13. An electronic device comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 6.

14. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 6.

15. A computer program product comprising a computer program / instructions, wherein: When the computer program / instructions are executed by a processor, the steps of the method according to claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Method and device for determining version difference and storage medium

    CN112099838A