CN110908904A - Method and device for debugging fast application and electronic equipment - Google Patents

Method and device for debugging fast application and electronic equipment Download PDF

Info

Publication number
CN110908904A
CN110908904A CN201911120455.6A CN201911120455A CN110908904A CN 110908904 A CN110908904 A CN 110908904A CN 201911120455 A CN201911120455 A CN 201911120455A CN 110908904 A CN110908904 A CN 110908904A
Authority
CN
China
Prior art keywords
debugging
fast application
information
module
fast
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201911120455.6A
Other languages
Chinese (zh)
Inventor
李建彬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xiaomi Mobile Software Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xiaomi Mobile Software Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN201911120455.6A priority Critical patent/CN110908904A/en
Publication of CN110908904A publication Critical patent/CN110908904A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging

Abstract

The disclosure relates to a method, a device and a system for debugging fast application. A method for debugging fast application is applied to a debugging kernel module, and comprises the following steps: receiving a debugging instruction of a debugging fast application sent by a debugging front end; acquiring debugging information of the fast application running on the fast application platform according to the debugging instruction; assembling the debugging information into debugging data for debugging the fast application; and sending the debugging data to a debugging front end for debugging the fast application. The debugging method and the debugging device are based on debugging during the running of the fast application, the debugging kernel serves as a bridge between the debugging front end and the fast application, so that the debugging front end can directly access the fast application and carry out debugging, and the debugging effect of the fast application is consistent with the running effect after debugging.

Description

Method and device for debugging fast application and electronic equipment
Technical Field
The present disclosure relates to the field of computers, and in particular, to a method for debugging fast application, a device for debugging fast application, and an electronic device.
Background
In the related technology, the quick application is a program which is written by a developer into a set of JS codes and can run on multiple ends of Android, IOS, WebView and the like based on a mobile phone hardware platform. The developer can write a form similar to conventional HTML to develop the program. The program can be divided into a component tree (DOM), a style (CSS), and a logic (JS code) from a data perspective; the file system can be divided into a configuration file (manifest. json), a global file (app. js) and a page file (page) from the composition, and an automatic compilation project (rpk) file is formed after packaging, and the packaged file is an application program of the fast application.
At present, a developer cannot test the performance of a fast application platform and cannot check a debugging result in real time when debugging the fast application.
Disclosure of Invention
In order to overcome the problems in the related art, the present disclosure provides a method for debugging a fast application, a device for debugging a fast application, and an electronic device.
According to a first aspect of the embodiments of the present disclosure, a method for debugging a fast application is provided, where the method is applied to a debugging kernel module, and the method for debugging a fast application includes: receiving a debugging instruction of a debugging fast application sent by a debugging front end; debugging information of the fast application running on the fast application platform is obtained according to the debugging instruction; assembling the acquired debugging information into debugging data for debugging the fast application; and sending the debugging data to a debugging front end for debugging the fast application.
In an embodiment, assembling debug information into debug data for debugging fast applications includes: the debug information is assembled into debug data for debugging the fast application based on the network protocol.
In one embodiment, the debug information includes: at least one of execution information of the fast application platform, view rendering information of the fast application, or page structure information of the fast application.
In one embodiment, acquiring running information of the fast application running on the fast application platform includes: acquiring running information of the fast application running on the fast application platform in a bridging mode by debugging a V8 bridging module of the kernel module; the debugging information is assembled into debugging data used for debugging the fast application, including: and assembling the running information of the fast application platform into debugging data for debugging the fast application.
In one embodiment, obtaining view rendering information of a fast application running on a fast application platform includes: acquiring view rendering information of a fast application running on a fast application platform in a bridging manner by debugging a platform bridging module of a kernel module; the debugging information is assembled into debugging data used for debugging the fast application, including: the view rendering information is assembled into debug data for debugging the fast application.
In one embodiment, acquiring page structure information of a fast application running on a fast application platform includes: acquiring page structure information of fast application running on a fast application platform by debugging a page structure management module of a kernel module; the debugging information is assembled into debugging data used for debugging the fast application, including: and assembling the page structure information into debugging data for debugging the fast application.
In one embodiment, assembling page structure information into debug data for debugging fast applications includes: and after locking the acquired page structure information, assembling the page structure information into debugging data for debugging the fast application.
In one embodiment, receiving a debug instruction of a debug application sent by a debug front end includes: establishing connection with a debugging front end through an interactive protocol; and receiving a debugging instruction of the debugging fast application sent by the debugging front end based on the connection.
According to a second aspect of the embodiments of the present disclosure, there is provided an apparatus for debugging a fast application, which is applied to a debugging kernel module, the apparatus for debugging a fast application including: the connection module is used for receiving a debugging instruction of the debugging fast application sent by the debugging front end; the acquisition module is used for acquiring debugging information which is required to run on the fast application platform according to the debugging instruction; the assembling module is used for assembling the debugging information into debugging data for debugging the fast application; and the sending module is used for sending the debugging information to the debugging front end and assembling the application information into the debugging information.
In one embodiment, the debug information includes: at least one of execution information of the fast application platform, view rendering information of the fast application, or page structure information of the fast application.
In an embodiment, the obtaining module obtains the running information of the fast application running on the fast application platform by the following method: acquiring running information of the fast application running on the fast application platform in a bridging mode by debugging a V8 bridging module of the kernel module; the assembly module assembles the debug information into debug data for the debug application in the following manner: and assembling the running information of the fast application platform into debugging data for debugging the fast application.
In an embodiment, the obtaining module obtains the view rendering information of the fast application running on the fast application platform by the following method: acquiring view rendering information of a fast application running on a fast application platform in a bridging manner by debugging a platform bridging module of a kernel module; the assembly module assembles the debug information into debug data for the debug application in the following manner: the view rendering information is assembled into debug data for debugging the fast application.
In an embodiment, the obtaining module obtains the page structure information of the fast application running on the fast application platform by the following method: acquiring page structure information of fast application running on a fast application platform by debugging a page structure management module of a kernel module; the assembly module assembles the debug information into debug data for the debug application in the following manner: and assembling the page structure information into debugging information for debugging the fast application.
In one embodiment, the assembly module assembles the page structure information into debug data for the debug fast application in the following manner: and after locking the acquired page structure information, assembling the page structure information into debugging data for debugging the fast application.
In an embodiment, the receiving module receives a debugging instruction of the debug application sent by the debugging front end in the following manner: establishing connection with a debugging front end through an interactive protocol; and receiving a debugging instruction of the debugging fast application sent by the debugging front end based on the connection.
According to a third aspect of the embodiments of the present disclosure, there is provided an electronic apparatus, wherein the electronic apparatus includes: a memory to store instructions; and the processor is used for calling any one of the methods for debugging the quick application.
According to a fourth aspect of the embodiments of the present disclosure, there is provided a non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer-executable instructions, and when executed by a processor, the computer-executable instructions perform any one of the above methods for debugging a fast application.
The technical scheme provided by the embodiment of the disclosure can have the following beneficial effects: the debugging kernel is used as an interactive bridge between the fast application and the debugging front end, so that the debugging front end can debug in the process of debugging the operation of the fast application, and the debugging effect of the fast application is consistent with the operation effect after debugging.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention.
FIG. 1 is a flow diagram illustrating a method of debugging a fast application in accordance with an exemplary embodiment.
FIG. 2 is a system interaction diagram illustrating a method of debugging a fast application in accordance with an exemplary embodiment.
FIG. 3 is a block diagram illustrating an apparatus for debugging a fast application in accordance with an example embodiment.
FIG. 4 is a block diagram illustrating another system for debugging a fast application in accordance with an illustrative embodiment.
Fig. 5 is a block diagram illustrating an apparatus for debugging a fast application in accordance with an example embodiment.
FIG. 6 is a block diagram illustrating an apparatus for debugging a fast application in accordance with an example embodiment.
Detailed Description
Exemplary embodiments will be described herein in detail with reference to the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the invention, as detailed in the appended claims.
At present, a developer debugs a fast application in a manner that the fast application is simulated at a terminal by means of an H5 page, then the simulated page is debugged by a debugging front end, and then debugging data is converted into the fast application to check a debugging effect. By the method, the debugging efficiency is low, and the data in the running process of the fast application cannot be debugged. The terminal may include: note-books and desktop computers are not limited in this disclosure.
According to the method for debugging the fast application, based on the data of the fast application during the operation of the fast application platform, the debugging front end can access the fast application through the debugging kernel, and the data of the fast application during the operation is obtained, so that the fast application is debugged.
FIG. 1 illustrates a flow chart of a method of debugging a fast application according to an exemplary embodiment of the present disclosure.
As shown in fig. 1, a method 10 for debugging a fast application according to an exemplary embodiment of the present disclosure is applied to debugging a kernel module. In this disclosure, both the debugging kernel module and the fast application platform belong to the back end of the fast application, and run in the mobile terminal, for example: mobile terminals such as mobile phones and tablets. The debugging front end belongs to the front end of the fast application and runs on a desktop terminal of a developer. The debugging kernel is positioned at the position of a bridge in debugging, is arranged between the debugging front end and the fast application platform, and bears the function of fast application debugging. The method 10 of debugging a fast application comprises the following working processes.
In step S11, a debug instruction of the debug cache application sent by the debug front end is received.
In the embodiment of the disclosure, the debugging front end sends the debugging instruction of the debugging fast application to the debugging kernel module according to the debugging requirement. The debugging kernel module starts the function of the debugging fast application according to the received debugging instruction, is convenient to acquire debugging information corresponding to the debugging instruction, and is beneficial to the debugging front end to effectively debug the fast application.
In one embodiment, the debugging kernel module establishes connection with the debugging front end through an interaction protocol, so that data exchange between the debugging kernel module and the debugging front end is facilitated. And the debugging kernel module receives a debugging request sent by the debugging front end according to the connection established between the debugging kernel module and the debugging front end. The interaction protocol may include: hypertext transfer protocol (HTTP), Transmission Control Protocol (TCP), and the like, but are not limited in this disclosure.
In step S12, debug information of the fast application running on the fast application platform is obtained according to the debug instruction.
In the embodiment of the present disclosure, the content of the debug instruction may include debug information that needs to be acquired by the debug front end or debug information that needs to be acquired by the debug front end and a relevant format of the debug information. And the debugging kernel acquires debugging information of the fast application running on the fast application platform according to the debugging instruction of the debugging front end. The debugging information of the fast application is acquired based on the running of the fast application, and the performance and running state of each part of the fast application can be effectively detected, so that the fast application is effectively debugged, and the effect of the release version of the debugged fast application is the same as the debugging version of the fast application. In an embodiment, the running change of the fast application in the fast application platform is synchronized to the debugging kernel module in real time, so that the debugging of the debugging front end according to the obtained debugging data is more accurate, and the debugging result is more effective.
In an optional embodiment, based on the running state of the fast application, the debugging information called by the debugging front end through the debugging instruction may include at least one of the following information: the method comprises the steps of running information of a fast application platform, view rendering information of the fast application and page structure information of the fast application. The running information of the fast application platform can comprise: and obtaining the running information according to the information such as the running time, the memory, the thread and the like of the fast application platform. View rendering information for fast applications may include: and rendering information of the fast application in the running process, namely page effects displayed by the fast application. The page structure information of the fast application can include: a web page text object (DOM), a web page cascading style (CSS), and the like.
In an alternative embodiment, the fast application may be developed in the JavaScript (JS) language and run on the engine. According to a debugging instruction which is sent by a debugging front end and used for acquiring the running information of the fast application platform, the debugging kernel module acquires the running information of the fast application running platform through a JS local interface of the fast application running platform in a bridging mode by using a JS engine bridging module. The information of the fast application during operation is acquired, the debugging front end is facilitated to find the problems of the fast application during operation, developers can conveniently debug the fast application according to the operation problems, and the debugging efficiency is improved. The JS engine can be a V8 engine, and the JS local interface can be a J2V8 interface. In an implementation scenario, the debugging front end needs to debug the JS code information of the fast application running, and the debugging kernel module acquires the JS code information through the JS engine bridge module according to a debugging instruction for acquiring the running information of the fast application platform, which is sent by the debugging front end.
In another optional embodiment, according to a debugging instruction sent by the debugging front end for acquiring view rendering information of the fast application, the debugging kernel module acquires, in a bridge manner, view rendering information of the fast application running on the fast application platform by using the platform bridge module. By calling view rendering information during the running of the fast application, the real effect displayed during the running of the fast application is acquired, the fast comparison with the expected effect is facilitated, and the debugging efficiency is improved. In an implementation scenario, if the debugging front end needs to debug the view rendering information of the fast application, a debugging instruction for debugging the view rendering information of the fast application is sent to the debugging kernel module, and the debugging kernel module obtains the view page rendering information of the current running of the fast application through the platform bridge module according to the debugging instruction.
In another optional embodiment, according to a debugging instruction sent by the debugging front end for acquiring the page structure information of the fast application, the debugging kernel module acquires the page structure information of the fast application running on the fast application platform by using the page structure management module. By calling page structure information during the running of the fast application, a developer is helped to observe the page structure change during the running of the fast application, and the features or functions which need to be realized during the running of the fast application platform are debugged according to the preset effect. In an implementation scenario, if the debugging front end needs to debug the page structure information of the fast application, a debugging instruction for debugging the page structure information of the fast application is sent to the debugging kernel module, and the debugging kernel module obtains the page structure information of the current running of the fast application through the page structure management module according to the debugging instruction.
In step S13, the debug information is assembled into debug data for debugging the fast application.
In the embodiment of the present disclosure, the debugging core module assembles the acquired debugging information, so that the assembled debugging data is suitable for the debugging front end, so that the debugging front end can debug according to the acquired debugging data.
In an optional embodiment, the acquired debugging information is assembled and assembled according to a network protocol predefined by the debugging kernel module, so that the assembled debugging data is suitable for the debugging front end. The network protocol may include: CDP (device discovery) protocol, TCP/IP (communication transport) protocol, etc. For example: the debugging front end needs to debug the view rendering information of the fast application, but the debugging format is a picture, the debugging kernel module obtains the view rendering information of the fast application according to the debugging instruction, and the obtained debugging rendering information is assembled into a screenshot of the fast application, so that the debugging front end can conveniently debug according to the screenshot.
In an optional embodiment, the debugging kernel module assembles the page structure information into debugging data for debugging the fast application after locking the obtained page structure information according to the page structure information obtained by the debugging instruction, so that loss of part of interactive data of the fast application and function abnormality caused by the page structure information of the fast application during operations such as querying and modifying the page structure information of the fast application by the debugging front end are avoided.
In step S14, debug data is sent to the debug front end for debugging the flash application.
In the embodiment of the disclosure, the debugging kernel module sends the assembled debugging data to the debugging front end, so that the debugging front end carries out debugging according to the acquired debugging data, and then the debugging front end finishes debugging the fast application.
In an optional embodiment, the debugging front end copies the page structure information of the fast application in advance to obtain copy structure information consistent with the page structure information of the fast application for maintenance. According to the debugging instruction of the page structure information of the debugging fast application, the debugging kernel module sends the debugging instruction to the debugging front end, the debugging front end debugs the copy structure information according to the page structure information of the fast application, and when the page structure information of the fast application is debugged, the normal operation of the fast application is not influenced, so that the debugging time is saved, and the debugging cost is saved.
Through the embodiment, the debugging kernel module acquires the debugging information of the fast application running on the fast application platform according to the debugging instruction of the debugging front end, and assembles the debugging information into the debugging data suitable for the debugging front end, so that the debugging front end can directly debug the fast application. In the debugging process, the debugging front end, the fast application platform and the fast application all participate in the debugging of the fast application, so that the debugging content is more comprehensive, and the debugging effect is consistent with the effect of the debugged release mode and the debugging mode.
In an optional embodiment, the fast application includes a debugging management module for managing and controlling the debugging kernel module. When the fast application is debugged, the debugging function of the debugging kernel module is started through the debugging management module, and the fast application is debugged by adopting the method for debugging the fast application.
Based on one inventive concept, the present disclosure also provides a system interaction diagram of an exemplary method of debugging a fast application.
FIG. 2 illustrates the exemplary debug fast application method system interaction diagram 20. As shown in FIG. 2, the method and system interaction 20 of the debug cache application includes the following steps.
In step S21, the platform acquires proxy server information.
In the embodiment of the present disclosure, after the terminal completes the application program compilation of the fast application, the browser of the terminal is used as a proxy server of the debugging front end. And when the fast application is started based on the fast application platform, sending the proxy server information to the fast application platform.
In step S22, the fast application platform initializes.
In the embodiment of the present disclosure, the fast application platform initializes while acquiring the proxy server information, and sets the running environment of the current fast application to a default state.
In step S23, the debug kernel module is started.
In the embodiment of the disclosure, after the fast application is started, the debugging kernel module is started through the debugging management module according to the debugging request of the user, so that the connection between the debugging kernel module and the debugging front end is conveniently established, and the fast application information is sent to the debugging front end.
In an optional embodiment, when the fast application is not debugged, the empty debugging kernel module is started to initialize through the debugging management module, and the interactive information is not processed, so that the fast application can normally run.
In step S231, the JS thread is started.
In the embodiment of the disclosure, when the fast application is started based on the fast application platform, the JS thread of the fast application when the fast application is operated is started and initialized, so that the fast application can be operated on the fast application platform conveniently.
In step S24, the debug kernel module initializes.
In the embodiment of the disclosure, after the debugging kernel module is started, the debugging kernel module initializes itself, so that the current state of the debugging kernel module is suitable for the debugging front end to debug the running fast application.
In step S241, a debug kernel is registered.
In the embodiment of the disclosure, after the debugging kernel module is initialized, the self registration information is sent to the fast application platform for registration, so that the fast application can manage the debugging kernel module through the debugging management module in the fast application according to the acquired registration information of the debugging kernel. When debugging is convenient, the debugging front end can interact with the fast application through the debugging kernel module, and the debugging information of the fast application is obtained.
In step S25, the fast application platform sends the JS thread information to the debugging kernel.
In the embodiment of the disclosure, after the JS thread is initialized, the debugging kernel module acquires JS thread information which is fast applied to the fast application platform to run, so that the debugging front end can conveniently debug the JS thread.
In step S26, the JS engine bridge module initializes.
In the embodiment of the disclosure, after the debugging kernel module acquires JS thread information of the fast application, the debugging kernel module initializes the JS engine bridge module, and initializes a debugging interface of the JS engine such as a troubleshooting interface or a configuration interface of the JS engine. And preparing JS thread information of the front-end debugging fast application.
In step S242, the debug kernel information is provided to the proxy server.
In the embodiment of the present disclosure, after the debugging kernel module initializes by asynchronously waiting for the JS engine bridge module, the debugging kernel module initializes a debugging frame, where the debugging frame is, for example: stetho framework. The debugging kernel module monitors the corresponding port of the application by starting the network server module, and sends the network server address of the debugging kernel module to the debugging front end through the proxy server, so that the connection between the debugging front end and the debugging kernel is conveniently established. The network server, for example: and an Http server.
In step S27, the debug front end is started.
In the embodiment of the disclosure, the proxy server starts the debugging front end through the debugging kernel module according to the debugging request received by the fast application, and accesses the network server module of the debugging kernel, so that the debugging front end and the debugging kernel module are linked, and the debugging kernel is convenient to debug corresponding debugging information according to the debugging instruction of the debugging front end.
In step S271, a debug preparation signal is transmitted.
In the embodiment of the disclosure, after the debug front end is connected to the debug kernel, the debug front end sends a debug preparation signal to the debug kernel through a corresponding network protocol, so as to perform debug confirmation on the debug kernel module, and the debug kernel module is convenient to acquire debug information according to a debug instruction sent by the debug front end.
In step S272, the page structure management module initializes.
In the embodiment of the disclosure, the debugging kernel module initializes the page structure management module according to the received debugging preparation signal sent by the debugging front end, so that the debugging kernel module can conveniently acquire the page structure information when the fast application runs according to the debugging instruction sent by the debugging front end.
In an embodiment, when the page structure management module is initialized, other debugging modules for debugging functions in the debugging kernel module are also debugged correspondingly, so that the debugging front end can be debugged smoothly in the process of debugging the fast application through the debugging kernel.
Through the embodiment, when the fast application runs on the fast application platform, the debugging front end debugs the fast application through the debugging kernel module, so that all debugging data obtained by the debugging front end through the debugging kernel module come from data when the fast application runs. When the fast application is debugged, each change of the fast application in operation is synchronized to the debugging kernel module according to the monitoring of the network server module, and the operation change of the fast application is fed back to the debugging front end by the debugging kernel, so that the debugging front end can adjust in real time according to the operation state of the fast application, and the expected effect can be quickly achieved. The debugging mode and the publishing mode of the fast application are ensured to obtain consistent effect.
Fig. 3 is a block diagram illustrating an apparatus 100 for debugging a fast application according to an example embodiment. Referring to fig. 3, the apparatus includes:
the receiving module 110 is configured to receive a debugging instruction of the debug application sent by the debug front end.
The obtaining module 120 is configured to obtain, according to the debugging instruction, debugging information of the fast application running on the fast application platform;
an assembling module 130 for assembling the debugging information into debugging data for debugging the fast application.
The sending module 140 is configured to send the debugging information to the debugging front end, and is configured to assemble the application information into the debugging information.
In an alternative embodiment, assembly module 130 assembles the debug information into debug data for the debug application in the following manner: the debug information is assembled into debug data for debugging the fast application based on the network protocol.
In an alternative embodiment, the debug information includes: at least one of execution information of the fast application platform, view rendering information of the fast application, or page structure information of the fast application.
In an optional embodiment, the obtaining module 120 obtains the running information of the fast application running on the fast application platform by the following method: and acquiring running information of the fast application running on the fast application platform in a bridging manner by debugging the V8 bridging module of the kernel module. The assembly module 130 assembles the debug information into debug data for the debug application in the following manner: and assembling the running information of the fast application platform into debugging data for debugging the fast application.
In an alternative embodiment, the obtaining module 120 obtains the view rendering information of the fast application running on the fast application platform by the following method: and acquiring view rendering information of the fast application running on the fast application platform in a bridging mode by debugging a platform bridging module of the kernel module. The assembly module 130 assembles the debug information into debug data for the debug application in the following manner: the view rendering information is assembled into debug data for debugging the fast application.
In an optional embodiment, the obtaining module 120 obtains the page structure information of the fast application running on the fast application platform by the following method: and acquiring the page structure information of the fast application running on the fast application platform by debugging the page structure management module of the kernel module. The assembly module 130 assembles the debug information into debug data for the debug application in the following manner: and assembling the page structure information into debugging information for debugging the fast application.
In an alternative embodiment, the assembly module 130 assembles the page structure information into debug data for the debug flash application in the following manner: and after locking the acquired page structure information, assembling the page structure information into debugging data for debugging the fast application.
In an alternative embodiment, the receiving module 110 receives the debug instruction of the debug cache application sent by the debug front end by the following method: establishing connection with a debugging front end through an interactive protocol; and receiving a debugging instruction of the debugging fast application sent by the debugging front end based on the connection.
Based on one inventive concept, this disclosure also provides another exemplary system 200 block diagram for debugging a fast application. Referring to fig. 4, the system includes:
the fast application platform 210, the debugging kernel 220, the debugging front end 230 and the PC-side proxy server 240, wherein the fast application 210 comprises: a debug management module 211; the debug kernel 220 includes: platform bridge module 221, V8 bridge module 222, CD P protocol processing module 223, httpserver224, and DOM tree management module 225.
And the fast application platform 210 is used for running the fast application.
The debugging management module 211 is configured to register and manage a debugging kernel, and initialize an empty debugging module when the debugging kernel is not started, so as to ensure that a program can be normally executed.
The platform bridge module 221 is used as a bridge for debugging the kernel, and is responsible for communication of the platform and initialization of other debugging modules.
And the V8 bridging module 222 is used for initializing the debugging interface of the V8.
The CDP protocol processing module 223 is used as a communication protocol processing module of the debugging front end.
httpserver224, which is a Web server for the debugging kernel, processes the requests of the debugger front end.
And the DOM tree management module 225 is used for taking charge of the construction and synchronization of the DOM tree of the debugging end.
And the PC side proxy server 240 is used for recording the address of the debugging kernel and starting the debugging front end.
Fig. 5 is a block diagram illustrating an apparatus 300 for debugging a fast application, according to an example embodiment. For example, the apparatus 300 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 5, the apparatus 300 may include one or more of the following components: a processing component 302, a memory 304, a power component 306, a multimedia component 308, an audio component 310, an input/output (I/O) interface 312, a sensor component 314, and a communication component 316.
The processing component 302 generally controls overall operation of the device 300, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing components 302 may include one or more processors 320 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 302 can include one or more modules that facilitate interaction between the processing component 302 and other components. For example, the processing component 302 may include a multimedia module to facilitate interaction between the multimedia component 308 and the processing component 302.
The memory 304 is configured to store various types of data to support operations at the device 300. Examples of such data include instructions for any application or method operating on device 300, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 304 may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
Power components 306 provide power to the various components of device 300. The power components 306 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for the apparatus 300.
The multimedia component 308 includes a screen that provides an output interface between the device 300 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 308 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the device 300 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 310 is configured to output and/or input audio signals. For example, audio component 310 includes a Microphone (MIC) configured to receive external audio signals when apparatus 300 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 304 or transmitted via the communication component 316. In some embodiments, audio component 310 also includes a speaker for outputting audio signals.
The I/O interface 312 provides an interface between the processing component 302 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 314 includes one or more sensors for providing various aspects of status assessment for the device 300. For example, sensor assembly 314 may detect an open/closed state of device 300, the relative positioning of components, such as a display and keypad of apparatus 300, the change in position of apparatus 300 or a component of apparatus 300, the presence or absence of user contact with apparatus 300, the orientation or acceleration/deceleration of apparatus 300, and the change in temperature of apparatus 300. Sensor assembly 314 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 314 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 314 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 316 is configured to facilitate wired or wireless communication between the apparatus 300 and other devices. The device 300 may access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 316 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 316 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 300 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 304 comprising instructions, executable by the processor 320 of the apparatus 300 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
A non-transitory computer readable storage medium, wherein instructions of the storage medium, when executed by a processor of a mobile terminal, enable the mobile terminal to perform a method for debugging a fast application, the method comprising the method for debugging a fast application according to any of the embodiments disclosed in the above.
Fig. 6 is a block diagram illustrating an apparatus 400 for debugging a fast application in accordance with an example embodiment. For example, the apparatus 400 may be provided as a server. Referring to fig. 6, apparatus 400 includes a processing component 422, which further includes one or more processors, and memory resources, represented by memory 432, for storing instructions, such as applications, that are executable by processing component 422. The application programs stored in memory 432 may include one or more modules that each correspond to a set of instructions. Further, processing component 422 is configured to execute instructions to perform a method of debugging a fast application to which any of the disclosed embodiments relates.
The apparatus 400 may also include a power component 426 configured to perform power management of the apparatus 400, a wired or wireless network interface 450 configured to connect the apparatus 400 to a network, and an input output (I/O) interface 458. The apparatus 400 may operate based on an operating system stored in the memory 432, such as Windows Server, MacOS XTM, UnixTM, LinuxTM, FreeBSDTM, or the like.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the invention and including such departures from the present disclosure as come within known or customary practice within the art to which the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the invention being indicated by the following claims.
It will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.

Claims (18)

1. A method for debugging a fast application is applied to a debugging kernel module, and comprises the following steps:
receiving a debugging instruction of a debugging fast application sent by a debugging front end;
according to the debugging instruction, the debugging information of the fast application running on the fast application platform is obtained;
assembling the debugging information into debugging data for debugging the fast application;
and sending the debugging data to the debugging front end for debugging the fast application.
2. The method for debugging a fast application according to claim 1, wherein said assembling the debugging information into debugging data for debugging the fast application comprises:
and assembling the debugging information into debugging data for debugging the fast application based on a network protocol.
3. The method of debugging a fast application according to claim 2, wherein said debugging information comprises: at least one of running information of the fast application platform, view rendering information of the fast application, or page structure information of the fast application.
4. The method for debugging a fast application according to claim 3,
acquiring the running information of the fast application running on a fast application platform, including: acquiring the running information of the fast application running on a fast application platform in a bridging manner through a V8 bridging module of the debugging kernel module;
the debugging information is assembled into debugging data for debugging the fast application, and the debugging data comprises the following steps: and assembling the running information of the fast application platform into debugging data for debugging the fast application.
5. The method for debugging a fast application according to claim 3,
acquiring the view rendering information of the fast application running on a fast application platform, including: acquiring view rendering information of the fast application running on a fast application platform by the fast application in a bridging mode through a platform bridging module of the debugging kernel module;
the debugging information is assembled into debugging data for debugging the fast application, and the debugging data comprises the following steps: assembling the view rendering information into debugging data for debugging the fast application.
6. The method for debugging a fast application according to claim 3,
acquiring the page structure information of the fast application running on the fast application platform, including: acquiring the page structure information of the fast application running on a fast application platform through a page structure management module of the debugging kernel module;
the debugging information is assembled into debugging data for debugging the fast application, and the debugging data comprises the following steps: and assembling the page structure information into debugging data for debugging the fast application.
7. The method for debugging a flash application according to claim 6, wherein assembling the page structure information into debugging data for debugging the flash application comprises:
and after locking the acquired page structure information, assembling the page structure information into debugging data for debugging the fast application.
8. The method for debugging fast application according to any one of claims 1-7, wherein the receiving of the debugging instruction of the debugging fast application sent by the debugging front end comprises:
establishing connection with the debugging front end through an interactive protocol;
and receiving a debugging instruction of the debugging fast application sent by the debugging front end based on the connection.
9. An apparatus for debugging a fast application, applied to a debugging kernel module, the apparatus for debugging a fast application comprising:
the debugging module is used for receiving a debugging instruction of the debugging fast application sent by the debugging front end;
the acquisition module is used for acquiring the debugging information which is required to run on the fast application platform according to the debugging instruction;
an assembling module for assembling the debugging information into debugging data for debugging the fast application;
and the sending module is used for sending the debugging information to the debugging front end and assembling the application information into the debugging information.
10. The apparatus of claim 9, wherein the assembling module assembles the debugging information into debugging data for debugging the fast application by:
and assembling the debugging information into debugging data for debugging the fast application based on a network protocol.
11. The apparatus for debugging a fast application according to claim 10, wherein the debugging information comprises: at least one of running information of the fast application platform, view rendering information of the fast application, or page structure information of the fast application.
12. The apparatus for debugging a fast application of claim 11,
the acquisition module acquires the running information of the fast application running on the fast application platform in the following way:
acquiring the running information of the fast application running on a fast application platform in a bridging manner through a V8 bridging module of the debugging kernel module;
the assembling module assembles the debugging information into debugging data for debugging the fast application by adopting the following modes:
and assembling the running information of the fast application platform into debugging data for debugging the fast application.
13. The apparatus for debugging a fast application of claim 11,
the acquisition module acquires the view rendering information of the fast application running on the fast application platform in the following way:
acquiring view rendering information of the fast application running on a fast application platform by the fast application in a bridging mode through a platform bridging module of the debugging kernel module;
the assembling module assembles the debugging information into debugging data for debugging the fast application by adopting the following modes:
assembling the view rendering information into debugging data for debugging the fast application.
14. The apparatus for debugging a fast application of claim 11,
the acquisition module acquires the page structure information of the fast application running on the fast application platform in the following way:
acquiring the page structure information of the fast application running on a fast application platform through a page structure management module of the debugging kernel module;
the assembling module assembles the debugging information into debugging data for debugging the fast application by adopting the following modes:
and assembling the page structure information into debugging information for debugging the fast application.
15. The apparatus for debugging a flash application according to claim 14 wherein the assembling module assembles the page structure information into debugging data for debugging the flash application by:
and after locking the acquired page structure information, assembling the page structure information into debugging data for debugging the fast application.
16. The apparatus for debugging a fast application according to any of claims 9-15, wherein the receiving module receives the debugging instruction of the debugging fast application sent by the debugging front-end in the following manner:
establishing connection with the debugging front end through an interactive protocol;
and receiving a debugging instruction of the debugging fast application sent by the debugging front end based on the connection.
17. An electronic device, wherein the electronic device comprises:
a memory to store instructions; and
a processor for invoking the memory-stored instructions to perform the method of debugging a fast application of any of claims 1-8.
18. A non-transitory computer-readable storage medium storing computer-executable instructions that, when executed by a processor, perform a method of debugging a fast application as recited in any of claims 1-8.
CN201911120455.6A 2019-11-15 2019-11-15 Method and device for debugging fast application and electronic equipment Pending CN110908904A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911120455.6A CN110908904A (en) 2019-11-15 2019-11-15 Method and device for debugging fast application and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911120455.6A CN110908904A (en) 2019-11-15 2019-11-15 Method and device for debugging fast application and electronic equipment

Publications (1)

Publication Number Publication Date
CN110908904A true CN110908904A (en) 2020-03-24

Family

ID=69817369

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911120455.6A Pending CN110908904A (en) 2019-11-15 2019-11-15 Method and device for debugging fast application and electronic equipment

Country Status (1)

Country Link
CN (1) CN110908904A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113760762A (en) * 2021-09-08 2021-12-07 北京房江湖科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110004790A1 (en) * 2007-12-21 2011-01-06 Albert Rossmann Asynchrony Debugging Using Web Services Interface
US20130091494A1 (en) * 2011-10-11 2013-04-11 Andrew M. Sowerby Suspending and Resuming a Graphics Application Executing on a Target Device for Debugging
CN107728999A (en) * 2017-11-14 2018-02-23 苏州奇松软件有限公司 A kind of App, the method and system of small routine interface simulation
US20180210811A1 (en) * 2015-09-25 2018-07-26 Huawei Technologies Co., Ltd. Debugging method, multi-core processor and debugging device
CN109117361A (en) * 2018-06-21 2019-01-01 腾讯科技(深圳)有限公司 A kind of remote debugging method of small routine, relevant device and system
CN110032512A (en) * 2019-03-28 2019-07-19 腾讯科技(深圳)有限公司 A kind of adjustment method of small routine, relevant device and terminal

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110004790A1 (en) * 2007-12-21 2011-01-06 Albert Rossmann Asynchrony Debugging Using Web Services Interface
US20130091494A1 (en) * 2011-10-11 2013-04-11 Andrew M. Sowerby Suspending and Resuming a Graphics Application Executing on a Target Device for Debugging
US20180210811A1 (en) * 2015-09-25 2018-07-26 Huawei Technologies Co., Ltd. Debugging method, multi-core processor and debugging device
CN107728999A (en) * 2017-11-14 2018-02-23 苏州奇松软件有限公司 A kind of App, the method and system of small routine interface simulation
CN109117361A (en) * 2018-06-21 2019-01-01 腾讯科技(深圳)有限公司 A kind of remote debugging method of small routine, relevant device and system
CN110032512A (en) * 2019-03-28 2019-07-19 腾讯科技(深圳)有限公司 A kind of adjustment method of small routine, relevant device and terminal

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113760762A (en) * 2021-09-08 2021-12-07 北京房江湖科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium
CN113760762B (en) * 2021-09-08 2024-03-08 贝壳找房(北京)科技有限公司 Method for simulating operating environment of applet, electronic device and storage medium

Similar Documents

Publication Publication Date Title
EP2998899A1 (en) Method and apparatus for running application program
CN110874217B (en) Interface display method and device for quick application and storage medium
CN110781080B (en) Program debugging method and device and storage medium
CN105808305B (en) Static resource loading method and device
CN107423218B (en) Application testing method, device and terminal
CN109117144B (en) Page processing method, device, terminal and storage medium
CN109347916B (en) Game interaction method and device and computer readable storage medium
CN110740131A (en) Data processing method and device, electronic equipment and storage medium
CN110795354A (en) Information processing method, device and storage medium
CN109684112B (en) Program file operation method, device, terminal and storage medium
CN106612149B (en) Radio frequency circuit testing method, device and system and mobile terminal
CN109976872B (en) Data processing method and device, electronic equipment and storage medium
CN106790683B (en) Network data display method and device based on mobile terminal
CN109901886B (en) Page language switching method, system, device and computer readable storage medium
CN110908904A (en) Method and device for debugging fast application and electronic equipment
CN111079040B (en) Resource sniffing method, device, terminal, server and storage medium
CN109491655B (en) Input event processing method and device
CN111596980B (en) Information processing method and device
CN111338961B (en) Application debugging method and device, electronic equipment and storage medium
CN110221813B (en) Application data connection establishment method and device, storage medium and electronic equipment
CN113407879A (en) Data reporting method, device and readable medium
CN111597106A (en) Point burying management method and device
CN110647351B (en) Source code map file restoration method, device and storage medium
CN112486617A (en) Ciphertext data processing architecture, method, device and machine readable medium
CN111290944A (en) Script generation method, device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination