A process debugging method, device, apparatus and storage medium
By pre-storing a set of information in electronic devices, the container IP address and debugging port are automatically determined and configured, solving the problem of low efficiency in manual configuration in existing technologies, and achieving efficient remote process debugging and adaptability to container changes.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING DAJIA INTERNET INFORMATION TECH CO LTD
- Filing Date
- 2022-07-27
- Publication Date
- 2026-07-31
AI Technical Summary
In existing technologies, remote debugging methods that rely on developers manually configuring container IP addresses and debugging ports are inefficient and require reconfiguration when containers change, making it difficult to perform process debugging efficiently.
By retrieving the identifier of the target process from a pre-stored set of information, the IP address and debug port of the container are automatically determined, enabling automatic connection and debugging between electronic devices and containers.
It improves the efficiency of remote process debugging, avoids the time-consuming and labor-intensive manual configuration, automatically updates debugging information to adapt to container changes, and reduces the operating costs for developers.
Smart Images

Figure CN115168228B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, and in particular to a process debugging method, apparatus, device, and storage medium. Background Technology
[0002] To ensure the correct execution of processes within a container, developers typically need to debug the process to detect and correct any potential errors. When debugging, since the container's runtime environment often doesn't include debugging tools, developers usually establish a communication connection between their local environment (based on an integrated development environment, IDE) and the container via a socket using a protocol (such as a debug protocol). This allows them to remotely debug the process using debugging tools available in their local environment. This remote debugging approach typically requires configuring the container's internet protocol (IP) address and debug port within the IDE-based local environment to establish the communication connection between the local environment and the container.
[0003] In related technologies, configuring container IP addresses and debug ports in a local IDE-based environment primarily relies on developers obtaining the container's IP address and debug port and manually configuring them within the IDE. This manual configuration method is time-consuming, labor-intensive, and inefficient when remotely debugging a large number of processes. Furthermore, as the program code required by the process may be updated or upgraded, the IP address of the container deploying the process may change, and the container's debug port may also change. In this case, developers need to obtain the container's IP address and debug port again and manually configure them. Therefore, this method relying on manual configuration by developers is difficult to efficiently perform remote debugging of processes. Summary of the Invention
[0004] This disclosure provides a process debugging method, apparatus, device, and storage medium that can improve the efficiency of remote process debugging.
[0005] The technical solution of this disclosure is as follows:
[0006] According to a first aspect of the present disclosure, a process debugging method is provided, which can be applied to an electronic device. The method includes: obtaining a target identifier of a target process; determining first debugging information matching the target identifier from a pre-stored information set; the first debugging information including an Internet Protocol (IP) address and a debugging port of a first container; the first container being a container in which the target process is deployed; the pre-stored information set including multiple identifiers and multiple pieces of debugging information corresponding one-to-one with the multiple identifiers; and establishing a connection between the first debugging information and the first container to debug the target process in the first container.
[0007] Optionally, the first container is any container in a container set; each container in the container set includes a debug information acquisition service; the debug information acquisition service is generated in response to a first write operation; the debug information acquisition service is used to acquire the identifier of the process in each container and the debug information of each container, and instruct each container to send the identifier of the process in each container and the debug information of each container to the electronic device; before determining the first debug information matching the target identifier, the process debugging method further includes: receiving the target identifier and the first debug information of the target process sent by the first container; invoking a debug information maintenance service to store the debug information corresponding to the target identifier in the information set as the first debug information; the debug information maintenance service is generated in response to a second write operation; the debug information maintenance service is used to update the correspondence between the identifier of the process in each container and the debug information of each container in the information set.
[0008] Optionally, when the container deploying the target process is a second container, after calling the debug information maintenance service to store the debug information corresponding to the target identifier in the information set as the first debug information, the method further includes: receiving the target identifier and the second debug information sent by the second container; the second container is any container in the container set other than the first container; the second debug information includes the IP address and debug port of the second container; and calling the debug information maintenance service to replace the first debug information corresponding to the target identifier in the information set with the second debug information.
[0009] Optionally, when the container in which the target process is deployed is a second container, the process debugging method further includes: determining second debugging information that matches the target identifier in a pre-stored information set; and establishing a connection between the second container and the second container based on the second debugging information to debug the target process in the second container.
[0010] Optionally, before calling the debug information maintenance service to store the debug information corresponding to the target identifier in the information set as the first debug information, the method further includes: obtaining and storing the debug information maintenance service.
[0011] Optionally, the specific method for determining the first debugging information that matches the target identifier includes: invoking a debugging information matching service to determine the debugging information in the information set corresponding to the target identifier as the first debugging information; the debugging information matching service is generated in response to the third writing operation; the debugging information matching service is used to determine the debugging information corresponding to the identifier of the process in each container in the information set.
[0012] Optionally, before calling the debug information matching service to determine the debug information in the information set corresponding to the target identifier as the first debug information, the method further includes: obtaining and storing the debug information matching service.
[0013] Optionally, the debugging information acquisition service is an agent service. The agent service is used to obtain the identifier of each process in each container and the debugging information of each container when the process starts.
[0014] According to a second aspect of the present disclosure, a process debugging apparatus is provided, comprising: an acquisition unit and a determination unit. The acquisition unit is configured to acquire a target identifier of a target process; the determination unit is configured to determine, from a pre-stored information set, first debugging information matching the target identifier acquired by the acquisition unit; the first debugging information includes the IP address and debugging port of a first container; the first container deploys the target process; the pre-stored information set includes multiple identifiers and multiple pieces of debugging information corresponding one-to-one with the multiple identifiers; the determination unit is further configured to establish a connection with the first container based on the first debugging information, so as to debug the target process in the first container.
[0015] Optionally, the first container belongs to a container set; each container in the container set includes a debugging information acquisition service; the debugging information acquisition service is generated in response to a first writing operation; the debugging information acquisition service is used to acquire the identifier of the process in each container and the debugging information of each container, and instructs each container to send the identifier of the process in each container and the debugging information of each container to the electronic device; the process debugging device further includes: a receiving unit and a calling unit. The receiving unit is used to receive the target identifier of the target process and the first debugging information sent by the first container; the first container is any container in the container set; the target process is deployed in the first container; the calling unit is used to call the debugging information maintenance service to store the debugging information corresponding to the target identifier in the information set as the first debugging information; the debugging information maintenance service is generated in response to a second writing operation; the debugging information maintenance service is used to update the correspondence between the identifier of the process in each container and the debugging information of each container in the information set.
[0016] Optionally, the receiving unit is further configured to receive the target identifier and the second debugging information sent by the second container; the second container is any container in the container set other than the first container; the calling unit is further configured to call the debugging information maintenance service to replace the first debugging information corresponding to the target identifier in the information set with the second debugging information.
[0017] Optionally, the determining unit is further configured to determine second debugging information matching the target identifier from a pre-stored information set; the determining unit is further configured to establish a connection between the second container and the second container based on the second debugging information, so as to debug the target process in the second container.
[0018] Optionally, the acquisition unit is also used to acquire and store debugging information maintenance services.
[0019] Optionally, the determining unit is specifically used for: invoking the debugging information matching service to determine the debugging information in the information set corresponding to the target identifier as the first debugging information; the debugging information matching service is generated in response to the third writing operation; the debugging information matching service is used to determine the debugging information corresponding to the identifier of the process in each container in the information set.
[0020] Optionally, the acquisition unit is also used to acquire and store debug information matching services.
[0021] Optionally, the debugging information acquisition service is an agent service. The agent service is used to obtain the identifier of each process in each container and the debugging information of each container when the process starts.
[0022] According to a third aspect of the present disclosure, an electronic device is provided, which may include: a processor and a memory for storing processor-executable instructions; wherein the processor is configured to execute the instructions to implement any of the optional process debugging methods of the first aspect described above.
[0023] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which instructions are stored, such that when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is able to perform any of the optional process debugging methods of the first aspect described above.
[0024] According to a fifth aspect of the present disclosure, a computer program product is provided, the computer program product including computer instructions that, when executed on a processor of an electronic device, cause the electronic device to perform a process debugging method as described in any of the optional implementations of the first aspect.
[0025] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure.
[0026] The technical solutions provided by the embodiments of this disclosure have at least the following beneficial effects:
[0027] Based on any of the above aspects, in this disclosure, after the electronic device obtains the target identifier of the target process, since the pre-stored information set includes multiple identifiers and multiple debugging information corresponding one-to-one with the multiple identifiers, it can determine the first debugging information matching the target identifier from the pre-stored information set, namely, the IP address and debugging port of the first container where the target process is deployed. Therefore, the debugging result of the target process in the first container can be determined based on the first debugging information. In this way, when remotely debugging one or more processes, this disclosure allows the electronic device to automatically determine the IP address and debugging port of the first container, and automatically configure the first debugging information such as the IP address and debugging port of the first container to establish a communication connection with the first container, thereby debugging the target process in the first container and further determining the debugging result of the target process in the first container. Compared to general technologies that rely on manual configuration by developers, this disclosure avoids the time-consuming and labor-intensive problem of remotely debugging a large number of processes. Therefore, this disclosure can improve the efficiency of remotely debugging processes. Attached Figure Description
[0028] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure, and are not intended to unduly limit this disclosure.
[0029] Figure 1 A schematic diagram of the structure of a process debugging system provided in an embodiment of this disclosure is shown;
[0030] Figure 2 A schematic diagram of the structure of an electronic device provided in an embodiment of this disclosure is shown;
[0031] Figure 3 A flowchart illustrating a process debugging method provided in an embodiment of this disclosure is shown.
[0032] Figure 4 A schematic diagram of a configuration interface provided in an embodiment of this disclosure is shown;
[0033] Figure 5 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0034] Figure 6 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0035] Figure 7 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0036] Figure 8 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0037] Figure 9 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0038] Figure 10 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0039] Figure 11 A flowchart illustrating yet another process debugging method provided in an embodiment of this disclosure is shown;
[0040] Figure 12 A schematic diagram of the structure of a process debugging device provided in an embodiment of this disclosure is shown;
[0041] Figure 13 A schematic diagram of the structure of a terminal provided in an embodiment of this disclosure is shown;
[0042] Figure 14 A schematic diagram of the structure of a server provided in an embodiment of this disclosure is shown. Detailed Implementation
[0043] To enable those skilled in the art to better understand the technical solutions of this disclosure, the technical solutions in the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings.
[0044] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this disclosure are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this disclosure described herein can be implemented in orders other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.
[0045] It should also be understood that the term "comprising" indicates the presence of the described feature, whole, step, operation, element and / or component, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements and / or components.
[0046] The data disclosed herein may be data authorized by the user or fully authorized by all parties.
[0047] The following explanations of the relevant concepts involved in the embodiments of this disclosure are provided to facilitate understanding.
[0048] 1. Container
[0049] A container is a portable software unit that can be used to deploy one or more processes and can be easily moved and run on any operating system in any environment. After a process is deployed in a container, the container contains the complete runtime environment that supports the process, including the program code, all dependencies required by the program code, class libraries, other binaries, and configuration files.
[0050] 2. Process
[0051] A process is a running activity of program code to fulfill specific user needs. It is the basic unit of resource allocation and scheduling, and the foundation of the operating system structure. A process can be viewed as an entity of program code.
[0052] 3. Program code
[0053] Program code is a set of rules that represent information in a discrete form, consisting of characters, symbols, or signal elements. It is usually written by developers to meet the specific needs of users.
[0054] 4. Integrated Development Environment
[0055] An Integrated Development Environment (IDE) is an application that provides a program code development environment. It typically includes tools such as a code editor, compiler, debugger, and graphical user interface, integrating code writing, analysis, compilation, and debugging capabilities into a unified software development suite. Examples include Visual Studio (a relatively complete development toolset) and Delphi (an application development tool).
[0056] In general techniques, configuring container IP addresses and debug ports in a local IDE-based environment primarily relies on developers obtaining the container's IP address and debug port and manually configuring them within the IDE. This manual configuration method is time-consuming, labor-intensive, and inefficient when remotely debugging a large number of processes. Furthermore, as the program code required by the process may be updated or upgraded, the IP address of the container deploying the process may change, and the container's debug port may also change. In such cases, developers need to obtain the container's IP address and debug port again and manually configure them. Therefore, this method of relying on manual configuration by developers is difficult to efficiently perform remote debugging of processes.
[0057] Based on this, embodiments of this disclosure provide a process debugging method. After obtaining the target identifier of a target process, the electronic device, since the pre-stored information set includes multiple identifiers and multiple debugging information corresponding one-to-one with the multiple identifiers, can determine the first debugging information matching the target identifier from the pre-stored information set. This first information is the IP address and debugging port of the first container where the target process is deployed. Therefore, the debugging result of the target process in the first container can be determined based on the first debugging information. In this way, when remotely debugging one or more processes, this disclosure allows the electronic device to automatically determine the IP address and debugging port of the first container and automatically configure the first debugging information, such as the IP address and debugging port of the first container, to establish a communication connection with the first container, thereby debugging the target process in the first container and further determining the debugging result of the target process in the first container. Compared to general technologies that rely on manual configuration by developers, this disclosure avoids the time-consuming and labor-intensive problem of remotely debugging a large number of processes. Therefore, this disclosure can improve the efficiency of remote process debugging.
[0058] Figure 1 A schematic diagram of a process debugging system provided in this disclosure embodiment is shown below. Figure 1 As shown, the configuration system 100 may include an electronic device 101 and a container deployment device 102. The electronic device 101 and the container deployment device 102 can communicate with each other.
[0059] Figure 1 The electronic device 101 can be a terminal configured with an IDE, which can be used to provide a development environment for program code and tools such as debuggers for processes. The electronic device 101 can debug program code during development using tools such as debuggers, and can also debug remote processes (i.e., processes deployed on other devices).
[0060] In one possible embodiment, the electronic device 101 may also include or be connected to a database. Resource files such as information sets, debugging information maintenance services, and debugging information matching services in this disclosure may be stored in the database, as may resource files such as configuration files of processes in a set of containers including the first container and the second container.
[0061] Optionally, the electronic device 101 can be a mobile phone, tablet computer, desktop computer, laptop computer, handheld computer, notebook computer, ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), augmented reality (AR) / virtual reality (VR) device, etc., that can install and use content community applications. This disclosure does not impose any special restrictions on the specific form of the terminal. It can interact with the user through one or more methods such as keyboard, touchpad, touch screen, remote control, voice interaction, or handwriting device.
[0062] Figure 1 The container deployment device 102 can be a virtual machine (such as a Java Virtual Machine (JVM)) or a physical machine, used to deploy a collection of containers, such as the first and second containers in this disclosure. A container is a portable software unit that can be deployed in the container deployment device 102 based on Kubernetes (a container orchestration engine). When deployed, a container is typically configured with an IP address and multiple ports, including debug ports, data ports, and control ports. For example, the debug port is typically port 5005, which can be used to allow remote operators to perform various operations (such as query operations) on processes and files within the container.
[0063] In one possible approach, the container can establish a communication connection with the electronic device 101 via a socket using some protocol (such as a debugging protocol).
[0064] Optionally, the above Figure 1 In the process debugging system shown, electronic device 101 can communicate with at least one container deployed on container deployment device 102. This disclosure does not limit the number or type of containers.
[0065] The process debugging method provided in this disclosure can be applied to the aforementioned... Figure 1 Electronic device 101 in the application scenario shown.
[0066] Combination Figure 1 ,like Figure 2The diagram shown is a structural schematic of an electronic device provided in an embodiment of this disclosure. The electronic device 101 may be configured with a processing module 21, an input module 22, a display module 23, and a storage module 24. The processing module 21 may be used to support an IDE configured in the electronic device 101. The input module 22 may be a computer external input device such as a mouse and keyboard, used by developers to perform code writing operations, etc. The display module 23 may be a device such as a liquid crystal display screen, used to display code input by developers through the input module 22. The storage module 24 may be a device such as a memory, used to store resource files such as information sets, debugging information maintenance services, and debugging information matching services, and may also be used to store resource files such as configuration files of processes in a container set including a first container and a second container.
[0067] The process debugging method provided in the embodiments of this disclosure will be described in detail below with reference to the accompanying drawings.
[0068] like Figure 3 As shown, when a process debugging method is applied to an electronic device, the process debugging method may include:
[0069] S301, The electronic device acquires the target identifier of the target process.
[0070] The target process is the process that needs to be debugged. For example, when the target process encounters a runtime error, that is, an error that causes the target process to stop, the electronic device can receive the target identifier of the target process input by the developer in order to debug the target process.
[0071] In one possible way, combining Figure 2 When a developer needs to input the target identifier of a target process into an electronic device, they can perform a first click operation through the input module configured on the electronic device to determine the target identifier of the target process in the target process's configuration file. In response to this first click operation, the electronic device can read the target process's configuration file and display it on the configured display module. Accordingly, the developer can consult the target process's configuration file displayed on the electronic device's display module and determine the target identifier of the target process. Next, the developer can perform an identifier input operation through the input module configured on the electronic device to input the target identifier of the target process into the electronic device. In response to this identifier input operation, the electronic device can receive the target identifier of the target process input by the developer.
[0072] It should be noted that, in order to effectively distinguish multiple processes (including the target process), developers can set an identifier for each process in the configuration file of each process when writing the program code for each process in multiple processes, so as to uniquely identify each process.
[0073] In one possible approach, developers can generate an identifier for each process using a Universally Unique Identifier (UUID) function, or they can generate an identifier for each process using other methods that can generate unique identifiers, thereby setting an identifier for each process. This disclosure does not limit this approach.
[0074] In one possible example, such as Figure 4 The image shown is a configuration interface provided in this disclosure. This configuration interface can be called "Edit configuration settings". The default target identifier for the target process is A. After determining the target identifier for the target process to be A, the developer can... Figure 4 In the configuration interface shown, enter "A" in the input box corresponding to "Name". Accordingly, the electronic device can receive the target identifier "A" from the target process.
[0075] S302. The electronic device determines the first debugging information that matches the target identifier from the pre-stored information set.
[0076] The first debugging information includes the IP address and debugging port of the first container. The first container deploys the target process. The pre-stored information set includes multiple identifiers and multiple debugging information items corresponding one-to-one with each identifier.
[0077] Specifically, since the electronic device pre-stores an information set, which includes multiple identifiers and multiple debugging information corresponding to each identifier, after obtaining the target identifier of the target process, the electronic device can match the debugging information corresponding to the target identifier in the information set to determine the first debugging information. Subsequently, the electronic device can establish a communication connection between the first debugging information and the first container, thereby remotely debugging the target process in the first container.
[0078] In one possible example, drawing on the example in S301 above, the default IP address of the first container is 'a', and the debug port is 5005. After the developer inputs the target identifier A of the target process, they can perform a mode selection operation through the input module configured on the electronic device to select "Attach to remote JVM" as the "Debugger mode". In response to this mode selection operation, the electronic device can determine the "Debugger mode" as "Attach to remote JVM" and match the IP address 'a' and debug port 5005 of the first container corresponding to the target identifier in the information set.
[0079] Next, the electronic device can automatically configure the IP address 'a' of the first container in the input box corresponding to "host" and configure the debugging port 5005 of the first container in the input box corresponding to "port".
[0080] S303. The electronic device establishes a connection with the first container based on the first debugging information in order to debug the target process in the first container.
[0081] It's important to note that when developers determine the configuration file for each of multiple processes (including the target process), they can typically add a debugger for each process's configuration file. Thus, after identifying the first debugging information matching the target identifier and establishing a communication connection with the first container, the electronic device can send an instruction message to the first container instructing it to debug the target process, and monitor the debugging results output by the first container through the debugging port in real time. In response to this instruction message, the first container can debug the target process based on the debugger and output the debugging results of the target process through the debugging port. Correspondingly, the electronic device can monitor the debugging results of the target process within the first container.
[0082] In one possible example, referring to the example in S302 above, after the electronic device automatically completes the relevant configuration, the developer can input debugging parameters determined based on Java Development Kit (JDK) 9 or a higher version (e.g., JDK 10) through the electronic device's input module into the input box corresponding to "Command line arguments for remote JVM". These debugging parameters can be used to indicate port 5005 on the listening container. For example, the debugging parameters could be "-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005".
[0083] Next, developers can use the input modules configured on the electronic device to... Figure 4The "Debug" option in the first step executes a second click operation. In response to this second click, the electronic device can establish a communication connection with the first container based on the IP address and debug port of the first container in the first debug information, using debug parameters as specified. The first container can then copy and paste the debug parameters into the command line used to start the target process and debug the target process. In this way, the first container can output the debugging results of the target process through the debug port (i.e., port 5005) indicated in the debug parameters. Correspondingly, the electronic device can listen for the debugging results of the target process in the first container on port 5005.
[0084] The technical solution provided by the above embodiments brings at least the following beneficial effects: As shown in S301-S303, after the electronic device obtains the target identifier of the target process, since the pre-stored information set includes multiple identifiers and multiple debugging information corresponding one-to-one with the multiple identifiers, the first debugging information matching the target identifier can be determined from the pre-stored information set. That is, the IP address and debugging port of the first container where the target process is deployed. Thus, the debugging result of the target process in the first container can be determined based on the first debugging information. In this way, when remotely debugging one or more processes, this disclosure allows the electronic device to automatically determine the IP address and debugging port of the first container, and automatically configure the first debugging information such as the IP address and debugging port of the first container to establish a communication connection with the first container, thereby debugging the target process in the first container and further determining the debugging result of the target process in the first container. Compared with the general technology that relies on manual configuration by developers, this disclosure can avoid the time-consuming and labor-intensive problem of remotely debugging a large number of processes. Therefore, this disclosure can improve the efficiency of remote debugging of processes.
[0085] In one embodiment, combined with Figure 3 Before S302 mentioned above, that is, before the electronic device determines the first debugging information that matches the target identifier, such as Figure 5 As shown, the process debugging method provided in this disclosure also includes: S401-S402.
[0086] S401, The electronic device receives the target identifier and first debugging information of the target process sent by the first container.
[0087] The first container is any one of the containers in the container set.
[0088] It should be noted that when developers deploy processes within each container of a container set, they can add a debug information acquisition service to the configuration file of each process deployed within that container. This debug information acquisition service is used to obtain the identifier of each process within a container and the debug information of each container when the process starts or during execution, and instructs each container to send the identifier of each process and the debug information of each container to the electronic device.
[0089] Based on this, when the target process deployed in the first container starts, or during the execution of the target process deployed in the first container, the first container can execute a debugging information acquisition service to obtain the target identifier and first debugging information of the target process. Then, the first container can send the target identifier and first debugging information of the target process to the electronic device instructed by the debugging information acquisition service. Correspondingly, the electronic device can receive the target identifier and first debugging information of the target process sent by the first container.
[0090] In one possible approach, in conjunction with the description of the configuration identifier in S301, the first container can execute a debug information acquisition service to read the configuration file of the target process and determine the target identifier of the target process in the configuration file.
[0091] In one possible approach, the first container can execute a debug information acquisition service to read the command-line information of the target process launched by the first container, and determine the IP address and debug port of the first container from the command-line information of the target process. Specifically, the execution of a process within a container is typically to determine a return value (i.e., the execution result) and output this return value to other containers or physical devices, thereby satisfying the specific requirements corresponding to this return value. Furthermore, to achieve the redirection of this return value to other containers or physical devices, the container adds its own IP address and port information, as well as the IP address and port information of the other container or physical device, to the command-line information of the launching process. Based on this, the debug information acquisition service can obtain the container's IP address and port information from the command-line information of the launching process when the process in each container starts or during execution. In this way, the debug information acquisition service can determine the container's IP address and the debug port from the container's port information.
[0092] In one possible approach, the debug information retrieval service could be generated in response to the first write operation. Specifically, in conjunction with Figure 2Developers can perform a first writing operation through the input module configured on the electronic device, writing source code for implementing the debug information retrieval service. Correspondingly, the processing module configured on the electronic device receives the source code written by the developer and generates source code for implementing the debug information retrieval service. Next, developers can select a compiler through the input module configured on the electronic device and perform a compilation operation on the source code for implementing the debug information retrieval service. In response to this compilation operation, the processing module configured on the electronic device can compile the source code for implementing the debug information retrieval service into a process. Subsequently, when deploying the process in each container, developers can deploy the compiled debug information retrieval service as the process's configuration file in each container.
[0093] In one possible approach, the debugging information retrieval service could be an agent service. The agent service is a code block deployed in the process's configuration file. At runtime, this code block can be viewed as an independent thread residing within the process, used to retrieve the identifier of each process in each container and the debugging information for each container when the process starts.
[0094] S402. The electronic device calls the debugging information maintenance service and stores the debugging information corresponding to the target identifier in the information set as the first debugging information.
[0095] Specifically, to facilitate obtaining the initial debugging information of the target process and enabling remote debugging of the target process, the electronic device can invoke the debugging information maintenance service to determine whether the information set stores debugging information corresponding to the target identifier. When it is determined that the information set does not store debugging information corresponding to the target identifier, the electronic device can invoke the debugging information maintenance service to store the debugging information corresponding to the target identifier in the information set as the initial debugging information.
[0096] It should be noted that the debug information maintenance service is generated in response to the second write operation. The debug information maintenance service is used to update the correspondence between the process identifier in each container and the debug information of each container in the information set.
[0097] It should be understood that the specific implementation of the debugging information maintenance service generated based on the second writing operation can be found in the detailed description of the debugging information acquisition service generated based on the first writing operation in S401, and will not be repeated here.
[0098] In one possible approach, the developer could pre-execute a second programming operation on a device other than the electronic device to obtain the debug information maintenance service, and then send the debug information maintenance service to the electronic device via that other device. Accordingly, the electronic device could acquire and store the debug information maintenance service to facilitate the invocation of the debug information maintenance service to perform corresponding storage actions.
[0099] In one possible example, the target identifier of target process B is preset to be b, and target process B is deployed in the first container m at time 1. Then, when target process B starts at time 1, the first container m can execute a debugging information acquisition service to determine the identifier of target process B and the debugging information of the first container m (i.e., the IP address and debugging port of the first container m), and send the identifier of target process B and the debugging information of the first container m to the electronic device. Correspondingly, the electronic device can receive the target identifier b and the debugging information of the first container m.
[0100] Next, the electronic device can invoke the debugging information maintenance service to determine whether the information set stores debugging information corresponding to the target identifier b. When it is determined that the information set does not store debugging information corresponding to the target identifier b, the electronic device can invoke the debugging information maintenance service to store the corresponding debugging information of the target identifier b and the first container m in the information set. In this way, the information set will store the correspondence between the debugging information of the target identifier b and the first container m at time 1.
[0101] The technical solution provided by the above embodiments brings at least the following beneficial effects: As shown in S401-S402, before the electronic device determines the first debugging information matching the target identifier, it can obtain the identifiers of multiple processes and the debugging information of the container set, and can call the debugging information maintenance service to store the identifiers of multiple processes and the debugging information of the container set in the corresponding information set. In this way, the electronic device can maintain the information set in advance, and when remote debugging of the target process is required, the first debugging information matching the target identifier can be easily determined in the information set.
[0102] In one embodiment, when the target process is deployed in a second container, such as Figure 6 As shown, the process debugging method provided in this disclosure also includes: S501-S502.
[0103] S501, The electronic device receives the target identifier and the second debugging information sent by the second container.
[0104] The second container is any container in the container set other than the first container.
[0105] Specifically, when the program code in the target process is updated or upgraded, in order to avoid interrupting the operation of the target process, developers usually deploy the target process in a new container (i.e., a second container) first, and then clear all data related to the target process in the first container. In this case, as the container deploying the target process changes from the first container to the second container, the debugging information corresponding to the target identifier of the target process also changes from the IP address and debugging port of the first container to the IP address and debugging port of the second container.
[0106] Next, when the target process in the second container starts, or during the execution of the target process deployed in the first container, the second container can execute the debug information acquisition service to read the configuration file at the time of process startup, thereby obtaining the target identifier and second debug information of the target process. Then, the second container can send the target identifier and second debug information of the target process to the electronic device indicated by the debug information acquisition service. Correspondingly, the electronic device can receive the target identifier and second debug information of the target process sent by the second container.
[0107] S502. The electronic device calls the debugging information maintenance service to replace the first debugging information corresponding to the target identifier in the information set with the second debugging information.
[0108] Specifically, after receiving the target identifier and second debugging information of the target process sent by the second container, in order to facilitate debugging of the target process in the second container, the electronic device can call the debugging information maintenance service to determine whether the information set stores debugging information corresponding to the target identifier. When it is determined that the information set stores the first debugging information corresponding to the target identifier, the electronic device can call the debugging information maintenance service to clear the first debugging information corresponding to the target identifier in the information set and store the debugging information corresponding to the target identifier as the second debugging information, thereby replacing the first debugging information corresponding to the target identifier in the information set with the second debugging information.
[0109] In one possible example, referring to the example in S402, the target process B is presumably deployed in the second container n at time 2. Here, time 2 is the time following time 1. Then, when the target process B starts at time 2, the second container n can execute a debugging information acquisition service to determine the identifier of the target process B and the debugging information of the second container n (i.e., the IP address and debugging port of the second container n), and send the identifier of the target process B and the debugging information of the second container n to the electronic device. Correspondingly, the electronic device can receive the target identifier b and the debugging information of the second container n.
[0110] Next, the electronic device can invoke the debugging information maintenance service to determine whether the information set stores debugging information corresponding to the target identifier b. When it is determined that the information set stores debugging information for the first container m corresponding to the target identifier b, the electronic device can invoke the debugging information maintenance service to clear the debugging information for the first container m corresponding to the target identifier b from the information set, and store the debugging information for the target identifier b and the second container n in the information set accordingly. In this way, the information set will store the correspondence between the debugging information of the target identifier b and the second container n at time 2.
[0111] The technical solution provided by the above embodiments brings at least the following beneficial effects: As shown in S501-S502, after the electronic device stores the target identifier and first debugging information of the process in the first container in the information set, when the target process is deployed in the second container, the electronic device can receive the target identifier and second debugging information sent by the second container, and call the debugging information maintenance service to update the debugging information corresponding to the target identifier in the information set to the second debugging information. In this way, the electronic device can realize the dynamic updating of the debugging information corresponding to the process in the information set. No matter how the debugging information of the container where the process is deployed changes, only the process identifier needs to be configured to realize remote debugging of the process. That is, after the container where the process is deployed changes, without modifying the relevant configuration of the IDE on the electronic device, the electronic device can automatically configure the IP address and debugging port of the latest container after the change, and establish a communication connection with the latest container, which greatly reduces the operating cost of developers. Therefore, this disclosure can avoid the time-consuming and labor-intensive problem caused by the general technology requiring developers to re-obtain and manually configure the updated container's IP address and debugging port, and can improve the efficiency of remote debugging of processes.
[0112] In one feasible example, when the container deploying the target process is a second container, such as... Figure 7 As shown, the process debugging method provided in this disclosure also includes: S601-S602.
[0113] S601. The electronic device determines the second debugging information that matches the target identifier from the pre-stored information set.
[0114] It should be understood that the specific implementation of the electronic device determining the second debugging information matching the target identifier from the pre-stored information set in S601 can be found in the description of the electronic device determining the first debugging information matching the target identifier from the pre-stored information set in S302. Further details will not be provided here.
[0115] S602. The electronic device establishes a connection between the second container and the second container based on the second debugging information in order to debug the target process in the second container.
[0116] It should be understood that, regarding the specific implementation of S602, whereby the electronic device establishes a connection between itself and the second container based on the second debugging information to debug the target process in the second container, the description in S303, whereby the electronic device establishes a connection between itself and the first container based on the first debugging information to debug the target process in the first container, can be found elsewhere. Further details will not be provided here.
[0117] The technical solution provided by the above embodiments brings at least the following beneficial effects: As shown in S601-S602, when the container for deploying the target process is a second container, if debugging of the target process is required, the electronic device can determine the second debugging information corresponding to the target identifier in the information set, and establish a connection between the second container based on the second debugging information to debug the target process in the second container. In this way, although the container for deploying the target process has changed, the developer only needs to input the target identifier of the target process on the electronic device to achieve remote debugging of the process. Therefore, this disclosure can avoid the time-consuming and labor-intensive problem caused by the developer having to re-obtain and manually configure debugging information after the container for deploying the process has changed, and can improve the efficiency of remote debugging of the process.
[0118] In one feasible example, combining Figure 5 Before S401 mentioned above, that is, before the electronic device calls the debugging information maintenance service to store the debugging information corresponding to the target identifier in the information set as the first debugging information, such as Figure 8 As shown, the process debugging method provided in this disclosure also includes: S701.
[0119] S701, Maintenance service for electronic devices to acquire and store debugging information.
[0120] Specifically, developers can perform a second writing operation through the input module of the electronic device. In response to the second writing operation, the electronic device can receive a debug information maintenance service and store the debug information maintenance service in a first preset location, so as to call the debug information maintenance service to perform corresponding update actions on the information set.
[0121] Optionally, the first preset location can be a database for storing information sets, or other locations preset by the developers to facilitate the invocation of debugging information maintenance services.
[0122] In one possible approach, after generating the debug information maintenance service on the electronic device, the developer can perform a first program storage operation on the electronic device to store the debug information maintenance service in a first preset location. In response to this first program storage operation, the electronic device can store the debug information maintenance service in the preset location to achieve pre-configuration of the debug information maintenance service.
[0123] The technical solution provided by the above embodiments brings at least the following beneficial effects: As shown in S701, before receiving the target identifier and first debugging information of the target process sent by the first container, the electronic device can acquire and store the debugging information maintenance service to complete the pre-configuration of the debugging information maintenance service. In this way, after receiving the target identifier and first debugging information of the target process sent by the first container, the electronic device can call the debugging information maintenance service to dynamically maintain the information set in a timely manner.
[0124] In one feasible example, combining Figure 3 In S302 above, when the electronic device determines the first debugging information that matches the target identifier, such as Figure 9 As shown, this disclosure provides an optional implementation method, specifically including: S801.
[0125] S801. The electronic device calls the debugging information matching service and determines the debugging information in the information set that corresponds to the target identifier as the first debugging information.
[0126] The debug information matching service is generated in response to a third-party write operation. This service is used to determine the debug information corresponding to the identifier of the process in each container from the information set.
[0127] It should be understood that the specific implementation of the debugging information matching service generated based on the third writing operation can be found in the detailed description of the debugging information acquisition service generated based on the first writing operation in S401, and will not be repeated here.
[0128] Specifically, after obtaining the target identifier of the target process, in order to establish a communication connection with the first container, the electronic device can call the debugging information matching service to match the debugging information corresponding to the target identifier in the information set, and determine the debugging information corresponding to the target identifier as the first debugging information.
[0129] The technical solution provided by the above embodiments brings at least the following beneficial effects: As can be seen from S801 above, a specific implementation method for an electronic device to determine the first debugging information matching the target identifier is given. After obtaining the target identifier of the target process, the electronic device can call the debugging information matching service to automatically determine the first debugging information matching the target identifier, thereby improving the efficiency of remote debugging of the process.
[0130] In one feasible example, combining Figure 9 Before S801 mentioned above, that is, before the electronic device calls the debugging information matching service to determine the debugging information corresponding to the target identifier in the information set as the first debugging information, such as Figure 10 As shown, the process debugging method provided in this disclosure also includes: S901.
[0131] S901, Electronic device acquires and stores debugging information matching service.
[0132] Specifically, developers can perform a third writing operation through the input module of the electronic device. In response to the third writing operation, the electronic device can receive a debug information matching service and store the debug information matching service in a second preset location, so as to call the debug information matching service to determine the first debug information that matches the target identifier.
[0133] Optionally, the second preset location can be a database in the IDE used to store debugging tools, or other locations preset by the developers to facilitate the invocation of debugging information matching services.
[0134] In one possible approach, after generating the debug information matching service on the electronic device, the developer can perform a second program storage operation on the electronic device to store the debug information matching service in a second preset location. In response to this second program storage operation, the electronic device can store the debug information matching service in the second preset location to achieve pre-configuration of the debug information matching service.
[0135] The technical solution provided by the above embodiments brings at least the following beneficial effects: As can be seen from S901 above, before calling the debugging information matching service and determining the debugging information corresponding to the target identifier in the information set as the first debugging information, the electronic device can acquire and store the debugging information matching service to complete the pre-configuration of the debugging information matching service. In this way, when it is necessary to determine the first debugging information that matches the target identifier of the acquired target process, the electronic device can automatically call the debugging information matching service to quickly determine the first debugging information that matches the target identifier.
[0136] In one possible example, such as Figure 11The diagram illustrates a flowchart of a process debugging method provided in this disclosure. When the target process starts, a first container can load a debugging information acquisition service to obtain the target identifier of the target process and the first debugging information of the first container. The first debugging information includes the IP address and debugging port of the first container. Then, the first container can report the target identifier and the first debugging information to an electronic device according to the instructions of the debugging information acquisition service. Subsequently, when remote debugging of the target process is required, the developer can perform an input operation to input the target identifier on an electronic device configured with an IDE. In response to this input operation, the electronic device can receive the target identifier of the target process and call a debugging information matching service to determine the first debugging information matching the target identifier. Specifically, the electronic device can call the debugging information matching service to determine the first debugging information matching the target identifier from an information set. In this way, the electronic device can establish a communication connection with the first container based on the first debugging information, thereby realizing remote debugging of the target process.
[0137] It is understood that, in actual implementation, the terminal / server described in the embodiments of this disclosure may include one or more hardware structures and / or software modules for implementing the aforementioned corresponding process debugging methods. These execution hardware structures and / or software modules may constitute an electronic device. Those skilled in the art should readily recognize that, based on the algorithmic steps of the various examples described in conjunction with the embodiments disclosed herein, this disclosure can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this disclosure.
[0138] Based on this understanding, the present disclosure also provides a process debugging device. Figure 12 A schematic diagram of the structure of the process debugging apparatus provided in an embodiment of this disclosure is shown. Figure 12 As shown, the process debugging device may include: an acquisition unit 1001 and a determination unit 1002.
[0139] The acquisition unit 1001 is used to acquire the target identifier of the target process; the determination unit 1002 is used to determine, in a pre-stored information set, the first debugging information that matches the target identifier acquired by the acquisition unit 1001; the first debugging information includes the IP address and debugging port of the first container; the first container deploys the target process; the pre-stored information set includes multiple identifiers and multiple pieces of debugging information corresponding one-to-one with the multiple identifiers; the determination unit 1002 is also used to establish a connection with the first container based on the first debugging information, so as to debug the target process in the first container.
[0140] Optionally, the first container belongs to a container set; each container in the container set includes a debugging information acquisition service; the debugging information acquisition service is generated in response to the first writing operation; the debugging information acquisition service is used to acquire the identifier of the process in each container and the debugging information of each container, and instruct each container to send the identifier of the process in each container and the debugging information of each container to the electronic device; the process debugging device further includes: a receiving unit 1003 and a calling unit 1004. The receiving unit 1003 is used to receive the target identifier of the target process and the first debugging information sent by the first container; the first container is any container in the container set; the target process is deployed in the first container; the calling unit 1004 is used to call the debugging information maintenance service to store the debugging information corresponding to the target identifier in the information set as the first debugging information; the debugging information maintenance service is generated in response to the second writing operation; the debugging information maintenance service is used to update the correspondence between the identifier of the process in each container and the debugging information of each container in the information set.
[0141] Optionally, the receiving unit 1003 is further configured to receive the target identifier and the second debugging information sent by the second container; the second container is any container in the container set other than the first container; the calling unit 1004 is further configured to call the debugging information maintenance service to replace the first debugging information corresponding to the target identifier in the information set with the second debugging information.
[0142] Optionally, the determining unit 1002 is further configured to determine second debugging information matching the target identifier in a pre-stored information set; the determining unit 1002 is further configured to establish a connection between the second container and the second container based on the second debugging information, so as to debug the target process in the second container.
[0143] Optionally, the acquisition unit 1001 is also used to acquire and store debugging information maintenance services.
[0144] Optionally, the determining unit 1002 is specifically used to: call the debugging information matching service to determine the debugging information in the information set corresponding to the target identifier as the first debugging information; the debugging information matching service is generated in response to the third writing operation; the debugging information matching service is used to determine the debugging information in the information set corresponding to the identifier of the process in each container.
[0145] Optionally, the acquisition unit 1001 is also used to acquire and store the debugging information matching service.
[0146] Optionally, the debugging information acquisition service is an agent service. The agent service is used to obtain the identifier of each process in each container and the debugging information of each container when the process starts.
[0147] As described above, the embodiments of this disclosure can divide the server into functional modules according to the above method examples. The integrated modules can be implemented in hardware or as software functional modules. Furthermore, it should be noted that the module division in these embodiments is illustrative and represents only one logical functional division; in actual implementation, other division methods may be used. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into a single processing module.
[0148] Regarding the process debugging device in the above embodiments, the specific methods of each module's operation and its beneficial effects have been described in detail in the foregoing method embodiments, and will not be repeated here.
[0149] This disclosure also provides a terminal, which may be a user terminal such as a mobile phone or a computer. Figure 13 A schematic diagram of the structure of a terminal provided in an embodiment of this disclosure is shown. This terminal, which may be a process debugging device, may include at least one processor 61, a communication bus 62, a memory 63, and at least one communication interface 64.
[0150] Processor 61 may be a processor (central processing unit, CPU), microprocessor unit, ASIC, or one or more integrated circuits for controlling the execution of programs according to the present disclosure.
[0151] The communication bus 62 may include a path for transmitting information between the aforementioned components.
[0152] Communication interface 64 uses any transceiver-like device for communicating with other devices or communication networks, such as servers, Ethernet, radio access networks (RAN), wireless local area networks (WLAN), etc.
[0153] Memory 63 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital versatile optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto. Memory may exist independently and be connected to the processing unit via a bus. Memory may also be integrated with the processing unit.
[0154] The memory 63 stores the application code that executes the present invention, and its execution is controlled by the processor 61. The processor 61 executes the application code stored in the memory 63 to implement the functions of the method of the present invention.
[0155] In a specific implementation, as one example, processor 61 may include one or more CPUs, for example... Figure 13 CPU0 and CPU1 in the CPU.
[0156] In a specific implementation, as one example, the terminal may include multiple processors, for example... Figure 13 Processors 61 and 65 are included. Each of these processors may be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. A processor here may refer to one or more devices, circuits, and / or processing cores used to process data (e.g., computer program instructions).
[0157] In a specific implementation, as one embodiment, the terminal may further include an input device 66 and an output device 67. The input device 66 and output device 67 communicate and can accept user input in various ways. For example, the input device 66 may be a mouse, keyboard, touchscreen device, or sensing device. The output device 67 communicates with the processor 61 and can display information in various ways. For example, the output device 61 may be a liquid crystal display (LCD), a light emitting diode (LED) display device, etc.
[0158] Those skilled in the art will understand that Figure 13 The structure shown does not constitute a limitation on the terminal and may include more or fewer components than shown, or combine certain components, or use different component arrangements.
[0159] This disclosure also provides a server. Figure 14 A schematic diagram of the server structure provided in an embodiment of this disclosure is shown. This server can be a process debugging device. The server can vary significantly due to differences in configuration or performance, and may include one or more processors 71 and one or more memories 72. The memory 72 stores at least one instruction, which is loaded and executed by the processor 71 to implement the process debugging methods provided in the various method embodiments described above. Of course, the server may also have wired or wireless network interfaces, a keyboard, and input / output interfaces for input / output. The server may also include other components for implementing device functions, which will not be elaborated here.
[0160] This disclosure also provides a computer-readable storage medium including instructions stored thereon, which, when executed by a processor of a computer device, enable the computer to perform the process debugging method provided in the embodiments described above. For example, the computer-readable storage medium may be a memory 63 including instructions, which may be executed by a processor 61 of a terminal to complete the method. As another example, the computer-readable storage medium may be a memory 72 including instructions, which may be executed by a processor 71 of a server to complete the method. Optionally, the computer-readable storage medium may be a non-transitory computer-readable storage medium, such as a ROM, RAM, CD-ROM, magnetic tape, floppy disk, or optical data storage device.
[0161] This disclosure also provides a computer program product including computer instructions that, when executed on an electronic device, cause the electronic device to perform the above-described actions. Figure 3 ,as well as Figures 5 to 11 The process debugging method shown in any of the attached figures.
[0162] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the following claims.
[0163] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.
Claims
1. A process debugging method characterized by, Applied to electronic devices, including: Obtain the target identifier of the target process; In a pre-stored set of information, first debugging information matching the target identifier is determined; the first debugging information includes the Internet Protocol IP address and debugging port of the first container; the first container is a container that deploys the target process; the pre-stored set of information includes multiple identifiers and multiple pieces of debugging information corresponding one-to-one with the multiple identifiers; A connection is established between the first debugging information and the first container to debug the target process in the first container; When the container deploying the target process is a second container, the process debugging method further includes: The system receives the target identifier and the second debugging information sent by the second container; the second container is any container in the container set other than the first container; the second debugging information includes the IP address and debugging port of the second container. Invoke the debugging information maintenance service to replace the first debugging information in the information set corresponding to the target identifier with the second debugging information; From the pre-stored set of information, determine the second debugging information that matches the target identifier; A connection is established between the second container and the second debugging information to debug the target process in the second container.
2. The process debugging method according to claim 1, characterized by, The first container is any one of the containers in the container set; each container in the container set includes a debug information acquisition service; the debug information acquisition service is generated in response to the first writing operation; The debugging information acquisition service is used to acquire the identifier of the process in each container and the debugging information of each container, and instruct each container to send the identifier of the process in each container and the debugging information of each container to the electronic device; Before determining the first debugging information matching the target identifier, the process debugging method further includes: Receive the target identifier of the target process and the first debugging information sent by the first container; The debugging information maintenance service is invoked to store the debugging information corresponding to the target identifier in the information set as the first debugging information; the debugging information maintenance service is generated in response to the second writing operation; the debugging information maintenance service is used to update the correspondence between the process identifier in each container and the debugging information of each container in the information set.
3. The process debugging method according to claim 2, characterized by, Before invoking the debugging information maintenance service and storing the debugging information corresponding to the target identifier in the information set as the first debugging information, the method further includes: The debugging information maintenance service is used to acquire and store the information.
4. The process debugging method according to any one of claims 1 to 2, characterized by, The determination of the first debugging information matching the target identifier includes: The debugging information matching service is invoked to determine the debugging information in the information set corresponding to the target identifier as the first debugging information; the debugging information matching service is generated in response to the third writing operation; the debugging information matching service is used to determine the debugging information corresponding to the identifier of the process in each container in the information set.
5. The process debugging method according to claim 4, characterized by, Before invoking the debugging information matching service and determining the debugging information in the information set corresponding to the target identifier as the first debugging information, the method further includes: Obtain and store the debugging information matching service.
6. The process debugging method according to any one of claims 2 to 3, characterized by, The debugging information acquisition service is an agent service; the agent service is used to acquire the identifier of the process in each container and the debugging information of each container when the process in each container starts.
7. A process debugging apparatus characterized by comprising: include: Acquisition unit, determination unit, receiving unit, and invocation unit; The acquisition unit is used to acquire the target identifier of the target process; The determining unit is configured to determine, from a pre-stored information set, first debugging information that matches the target identifier obtained by the obtaining unit; the first debugging information includes the IP address and debugging port of the first container; the first container deploys the target process; the pre-stored information set includes multiple identifiers and multiple pieces of debugging information corresponding one-to-one with the multiple identifiers; The determining unit is further configured to determine the debugging result of the target process in the first container based on the first debugging information; The receiving unit is configured to receive the target identifier and the second debugging information sent by the second container when the container deploying the target process is the second container; the second container is any container in the container set other than the first container; the second debugging information includes the IP address and debugging port of the second container; The calling unit is used to call the debugging information maintenance service to replace the first debugging information corresponding to the target identifier in the information set with the second debugging information; The determining unit is further configured to determine, in the pre-stored information set, second debugging information matching the target identifier; and establish a connection between the second debugging information and the second container to debug the target process in the second container.
8. An electronic device, comprising: The electronic device includes: processor; Memory used to store the processor's executable instructions; The processor is configured to execute the instructions to implement the process debugging method as described in any one of claims 1-6.
9. A computer-readable storage medium having stored thereon instructions, the computer-readable storage medium comprising: When the instructions in the computer-readable storage medium are executed by the processor of the electronic device, the electronic device is able to perform the process debugging method as described in any one of claims 1-6.
10. A computer program product comprising instructions, characterized in that, When the instructions are executed on the processor of the electronic device, the electronic device causes the electronic device to perform the process debugging method as described in any one of claims 1-6.