Civil aviation e-commerce system, civil aviation e-commerce system debugging method, civil aviation e-commerce system debugging device and storage medium
By introducing rule matching, rule analysis and persistence modules into the civil aviation e-commerce system, the problem of debugging session logs not being persisted is solved, and the persistent storage and management of logs are realized, and the development efficiency and system maintainability are improved.
Patent Information
- Application Number
- CN202411846095.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-13
- Publication Date
- 2025-04-04
AI Technical Summary
The debugging session logs of existing civil aviation e-commerce systems cannot be persisted, resulting in log loss during system restart or memory cleaning, which cannot meet the needs of complex business scenarios, increasing the difficulty for developers when reproducing and analyzing debugging sessions.
A civil aviation e-commerce system was designed, including a rule matching module, a rule analysis module and a persistence module. The rule matching module is on the client side, and the rule analysis and persistence module is on the server side. By collecting and storing the debugging session logs, users are allowed to download and delete historical logs.
It realizes persistent storage of debugging session logs, avoids log loss, improves developers' efficiency when reproducing and analyzing debugging sessions, and reduces the risk of mutual interference and log error deletion among developers.
Smart Images

Figure CN119759738A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of front-end debugging, and in particular to a civil aviation e-commerce system and a debugging method, device and storage medium for the civil aviation e-commerce system. Background Art
[0002] In modern civil aviation e-commerce systems, debugging sessions are an important tool for tracking the execution of business processes. The core components of debugging sessions include message pairs and specific business rules. Message pairs are the format for data exchange between modules or third-party interfaces, usually displayed in XML format, including input requests and output responses. Specific business rules involve the logic and conditions executed by the system when processing these message pairs. The debugging session displays this information comprehensively, allowing developers to clearly understand the execution status and results of each step. The debugging session log records all data interactions and business rule applications from input requests to output responses, allowing developers to observe and analyze the execution details of business processes in real time. The debugging session log is mainly stored in the system memory and displayed through a graphical debugging interface, which is convenient for developers to monitor and debug in real time.
[0003] However, the existing debugging session log management method has some significant shortcomings, mainly the problem that the debugging session log cannot be persisted:
[0004] The current debugging session logs are mainly stored in the system memory, which means that once the system is restarted or the memory is cleared, all unsaved debugging sessions will be lost. In addition, the memory storage method also limits the number and size of debugging session logs, which cannot meet the needs of complex business scenarios. This problem further makes it difficult for developers to reproduce previous debugging sessions when facing special scenarios, and developers lack access to historical debugging sessions and cannot compare and analyze by referring to past data. In this case, developers can only rely on existing data for analysis, which increases the complexity of problem solving. It is not conducive to troubleshooting and solving problems. Summary of the invention
[0005] The present invention aims to solve at least one of the technical problems in the above-mentioned technologies to a certain extent, and proposes a civil aviation e-commerce system for debugging session persistence, comprising:
[0006] Rule matching module, rule analysis module and persistence module;
[0007] The rule matching module is set on the client side, and the rule analysis module and the persistence module are set on the server side; wherein,
[0008] The rule matching module is configured as follows:
[0009] When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and
[0010] In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
[0011] Furthermore, the client is a browser; the rule matching module includes: a browser with a script mounter installed and a debugging session log collection script.
[0012] Furthermore, the rule matching module is configured to: after receiving the debugging instruction sent by the user, load the graphical interface through jQuery technology; wherein,
[0013] The graphical interface is configured to respond to a user's log collection instruction; the graphical interface includes a text input box and a click button.
[0014] Furthermore, the rule matching module is configured to: after responding to the user's collection instruction through the graphical interface, verify whether the response to the collection instruction is successful based on whether there is an activated debugging session log message pair on the current web page.
[0015] Furthermore, the graphical interface is configured to: visually output the debugging session log upload status and the debugging session log download status.
[0016] Furthermore, the civil aviation e-commerce system with persistent debugging session further includes: a log processing module disposed on the client;
[0017] The rule matching module is configured as follows:
[0018] The rule analysis module is used to query whether there is a debugging session log to be uploaded in the persistence module. If not, the debugging session log to be uploaded is screened by the log processing module.
[0019] Furthermore, the rule matching module is configured as follows:
[0020] After downloading the historical debugging session log corresponding to the download instruction from the persistence module, a deletion command is sent to the persistence module, so that the persistence module deletes the historical debugging session log stored in the persistence module.
[0021] The present application also proposes a civil aviation e-commerce system debugging method based on the above-mentioned debugging session persistence, comprising:
[0022] Using the rule matching module, the following method is executed:
[0023] When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and
[0024] In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
[0025] The present application also proposes a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed by a processor, it is at least used to implement the above-mentioned civil aviation e-commerce system debugging method.
[0026] The present application also proposes a computer program product, which is stored in a computer-readable storage medium. When the computer program product is executed by a processor, it is at least used to implement the civil aviation e-commerce system debugging method mentioned above.
[0027] Compared with the prior art, the present invention has the following beneficial effects:
[0028] 1. Strong scalability. This application adopts the design of browser plug-ins, allowing users to easily and conveniently expand and upgrade the functions of the system.
[0029] 2. Strong maintainability. This application uses the separation of client and server, which enables us to better maintain the system. The client is responsible for interacting with users, while the server is responsible for processing business logic and data storage. This separation of client and server helps to achieve the goals of clear responsibilities, easy management and iterative optimization, and also helps to deploy and expand in different environments and platforms.
[0030] 3. Strong portability and compatibility: The client is developed in the form of a browser plug-in and has wide applicability. This means that users can use this solution seamlessly on different mainstream operating systems (such as Windows, macOS, Linux, etc.) and browsers (such as Chrome, Firefox, Edge, etc.), ensuring the best user experience.
[0031] 4. Improve debugging efficiency and reduce risks: Each developer can independently name the corresponding debugging session log and save it separately in the server for persistent storage. Developers can download the debugging session log from the server on demand, and then the server will delete the corresponding debugging session log, which effectively reduces mutual interference between developers, reduces the risk of accidental deletion of debugging session logs, and improves efficiency.
[0032] Other features and advantages of the present invention will be described in the following description, and partly become apparent from the description, or be understood by practicing the present invention. The purpose and other advantages of the present invention can be realized and obtained by the structures particularly pointed out in the written description and the accompanying drawings. The technical scheme of the present invention is further described below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings:
[0034] Figure 1 A schematic diagram of a civil aviation e-commerce system with persistent debugging session provided in an embodiment;
[0035] Figure 2 A workflow diagram of a civil aviation e-commerce system with persistent debugging session provided in an embodiment;
[0036] Figure 3 A schematic diagram of a computer-readable storage medium is provided for an embodiment. DETAILED DESCRIPTION
[0037] The present invention is described below in conjunction with the accompanying drawings. The preferred embodiments described herein are only used to illustrate and explain the present invention and are not used to limit the present invention.
[0038] The civil aviation e-commerce system is a complex system involving multiple business modules. In order to achieve the collaborative work between the various business modules, many processes need to be processed within the system. These processes include but are not limited to the ticket booking process, meal purchase process, insurance purchase process, seat purchase process, ticket change process, ticket refund process, insurance refund process, meal refund process, and luggage refund process. Among these processes, the ticket booking process may be the most basic and common.
[0039] The ticket booking process usually includes the following sub-processes: query flight information, select flight and class, fill in passenger information, select payment method, pay ticket fee, confirm payment result and receive e-ticket, etc. For example, the change process may include sub-processes such as selecting a new flight, adjusting class, paying change fee, etc. The refund process may include sub-processes such as selecting refund type, determining refund fee, selecting payment method, receiving refund money, etc.
[0040] In short, each process in the civil aviation e-commerce system involves multiple sub-processes, and there will be many message flows between these sub-processes.
[0041] In order to improve development efficiency and team collaboration, an effective solution is to use debugging session persistence technology, which means that the development team can organize and save the debugging information of each process in advance so that it can be viewed and analyzed when needed.
[0042] To this end, the present invention provides a civil aviation e-commerce system for debugging session persistence, comprising:
[0043] Rule matching module, rule analysis module and persistence module;
[0044] The rule matching module is set on the client side, and the rule analysis module and the persistence module are set on the server side; wherein,
[0045] The rule matching module is configured as follows:
[0046] When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and
[0047] In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
[0048] Furthermore, the client is a browser; the rule matching module includes: a browser with a script mounter installed and a debugging session log collection script.
[0049] According to some embodiments of the present application, the system provided by the present invention includes: a client rule matching module, which mainly performs domain name matching rule processing, collects corresponding debugging session logs, i.e., debugging session logs, verifies whether relevant debugging session log message pairs have been activated, and generates relevant DOM elements such as a file name input box and a session log download button; a client log processing module, which is mainly used to retrieve relevant debugging session logs for activated debugging session log message pairs, parse relevant DOM element tags or hyperlinks, and uniformly package and send them to the server; a server-side rule analysis module, which is mainly used to verify whether the server already has a pre-downloaded debugging session log file, parse the session log packaged by the client, multi-threadedly process hyperlink tags, and generate HTML pages; a server-side log persistence module, which is mainly used to persist the debugging session log and provide log download services.
[0050] According to other embodiments of the present application, Figure 1 As shown, the system provided by the present invention includes: a rule matching module and a log processing module of the browser client, and a rule analysis module and a persistence module of the server. Among them, the rule matching module is a greasemonkey plug-in and a debug log collection script, which is used to dynamically obtain the debug session log from the target web page. The log processing module is used to process the obtained debug session log, and upload the debug session log to the server after being processed by the browser client. The rule analysis module is used to verify whether the pre-downloaded debug session log already exists in the persistence module. If it does not exist or partially exists, the log processing module is notified to analyze the debug session log to be uploaded, and filter the debug session log that does not exist on the server side for uploading. After receiving the debug session log sent by the client, the rule analysis module on the server side transmits it to the persistence module for storage.
[0051] It should be noted here that the Treasure Monkey plug-in is a user script manager for web browsers, supporting multiple browsers such as Chrome, Firefox, and Safari. Users can load and execute custom JavaScript scripts through the Treasure Monkey plug-in, thereby achieving automated operations, modifying page content, adding functions, etc. when accessing web pages. Treasure Monkey plug-ins are widely used in various scenarios, including ad blocking, interface optimization, data crawling, etc.
[0052] Furthermore, the rule matching module is configured to: after receiving the debugging instruction sent by the user, load the graphical interface through jQuery technology; wherein,
[0053] The graphical interface is configured to respond to a user's log collection instruction; the graphical interface includes a text input box and a click button.
[0054] Furthermore, the rule matching module is configured to: after responding to the user's collection instruction through the graphical interface, verify whether the response to the collection instruction is successful based on whether there is an activated debugging session log message pair on the current web page.
[0055] It should be noted here that the message pair is the format of data exchange between modules or between third-party interfaces, including input requests and output responses. The activation of the message pair indicates that data exchange between modules or between modules and third-party interfaces is successfully established.
[0056] Furthermore, the graphical interface is configured to: visually output the debugging session log upload status and the debugging session log download status.
[0057] According to some embodiments of the present application, the rule matching module periodically obtains the debugging session log of the XML structure from the domain name containing specific keywords. For example, the rule matching module scans the page at runtime. When the domain name containing the word "Debug" appears in the page, the text input box is dynamically loaded and the download log session rule button is clicked through the jQuery technology, that is, when the client detects that the current web page contains important log information when browsing the web page, in order to facilitate the business personnel to view and analyze these logs, the plug-in will pop up a prompt box in the upper right corner of the browser, displaying the following page. On this page, the system will automatically generate a log file storage name with a unique identifier, and the business personnel can choose to rename it as needed. The business personnel only need to click the download button to download the debug log file to the local server for further analysis and processing by the business personnel.
[0058] When a business person opens a web page in a browser, if the web page contains a valid debug log, the business person can easily download the required file or resource by clicking the download button. However, in some cases, the browser may not contain any valid debug log. In this case, if the business person tries to click the download button, the system will pop up a friendly prompt window to inform the business person that the download service is currently unavailable. This prompt window will explain the reason in detail, such as lack of required permissions, file non-existence, or network connection problems.
[0059] When the browser contains a valid debug log and the business personnel tries to click the download button to download, the system will automatically detect this operation and trigger a prompt window. The purpose of this prompt window is to clearly inform the business personnel that the system is downloading the debug log file, so that the business personnel understand this process and realize that this is not an abnormal behavior of the system to avoid misunderstanding. Specifically, when the business personnel tries to click the download button, the system will check whether the current browser contains a valid debug log. If the debug log is found, the system will immediately pop up a prompt window to explain the ongoing operation to the business personnel. This window usually contains some key information, such as the name of the file being downloaded, the file size, and the estimated download time.
[0060] When the server successfully downloads the debugging session, the system will automatically pop up a clear and easy-to-understand prompt window to help business personnel more comprehensively understand the current system status and operation progress. The main purpose of this prompt window is to clearly show the current session information to business personnel, such as session status and amount of data downloaded, so that business personnel can make corresponding judgments and decisions based on this information. At the same time, the prompt window also provides a simple operation interface, allowing the client to download the log to the local environment.
[0061] Furthermore, the civil aviation e-commerce system with persistent debugging session further includes: a log processing module disposed on the client;
[0062] The rule matching module is configured as follows:
[0063] The rule analysis module is used to query whether there is a debugging session log to be uploaded in the persistence module. If not, the debugging session log to be uploaded is screened by the log processing module.
[0064] Furthermore, the rule matching module is configured as follows:
[0065] After downloading the historical debugging session log corresponding to the download instruction from the persistence module, a deletion command is sent to the persistence module, so that the persistence module deletes the historical debugging session log stored in the persistence module.
[0066] According to some embodiments of the present application, the workflow of the civil aviation e-commerce system for debugging session persistence provided by the present application is as follows: Figure 2 As shown, including:
[0067] (1) The user opens the session debugging interface. The session here refers to a real-time session that tracks the execution of the business process. It is mainly stored in the memory and includes the message pairs involved in the execution of the relevant business process, specific business rules, etc. The debugging interface displays the real-time session in the memory in the form of a graphical interface. After the debugging interface is opened, the client rule matching module verifies the specific domain name information. If the verification is successful, the text input box is dynamically loaded through jQuery technology and the download log session rule button is clicked. The user clicks the file name input box to enter the file name and clicks the download button. After that, the client verifies whether there is an activated session log message pair. If there is no activated session log message pair in the session debugging interface, an error message is returned and the process ends. If there is an activated message pair, a log query request is initiated to the server. According to the information returned by the server, the log processing module interface is called to prepare for debugging session log processing.
[0068] (2) For the activated session log message pairs, the client log processing module retrieves the relevant log session, that is, the debugging session log, parses the relevant DOM element tags or hyperlinks therein, and packages them and sends them to the server.
[0069] (3) The server-side rule analysis module verifies whether the server already has the pre-downloaded debugging session log. If so, it returns the corresponding debugging session log to the client. If not, it parses the debugging session log, marks the HTML hyperlink, starts multi-threading to obtain the DOM element information for each hyperlink, and generates the corresponding HTML file.
[0070] (4) The persistence module receives the debugging session log sent by the rule analysis module, feeds back a message to the client indicating that the log has been persisted successfully, and receives a command from the user through the client asking whether to download the log. If the user chooses to download the log to the client and successfully executes the operation, the server deletes the log that the client has downloaded.
[0071] The present application also proposes a civil aviation e-commerce system debugging method based on the above-mentioned debugging session persistence, comprising:
[0072] Using the rule matching module, the following method is executed:
[0073] When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and
[0074] In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
[0075] According to some embodiments of the present application, in some public test environments, many developers need to share the same test system for development and testing. Due to work needs, these developers may activate multiple sessions to meet their respective needs. In this case, the test system will record a large amount of debugging session information at the same time, which makes it more difficult to find and analyze problems. For example, developer A books a flight based on the verification scenario, July 1, 2024, Hong Kong, China-Taipei, China. The system returns a list of flights that meet the conditions according to the query conditions, and the session debugging system of the architecture generates a debugging session A in memory. Developer B books a flight based on the verification scenario, July 15, 2024, Hong Kong, China-Beijing, China. The system returns a list of flights that meet the conditions according to the query conditions, and the session debugging system of the architecture generates a debugging session B in memory. By analogy, there may be many debugging sessions in the system at the same time, because the names of the debugging sessions are not significantly different, so if developers want to find their own sessions, the process will be very difficult and time-consuming. Moreover, developers may choose to clear these no longer needed sessions, or clear all sessions to ensure that they can find their own debugging sessions more quickly and improve work efficiency. At this time, if other developers are debugging, their debugging session logs may be accidentally deleted.
[0076] Through the civil aviation e-commerce system with debug session persistence provided by this application, each developer can independently name the corresponding debug session log and save it separately in the server for persistent storage. Developers can download the debug session log from the server on demand, and the server will then delete the corresponding debug session log, effectively reducing mutual interference between developers, reducing the risk of accidental deletion of debug session logs, and improving efficiency.
[0077] like Figure 3 As shown, the present application also proposes a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed by a processor, it is at least used to implement the above-mentioned civil aviation e-commerce system debugging method.
[0078] The present application also proposes a computer program product, which is stored in a computer-readable storage medium. When the computer program product is executed by a processor, it is at least used to implement the civil aviation e-commerce system debugging method mentioned above.
[0079] Compared with the prior art, the beneficial effects of this application are:
[0080] 1. Strong scalability. This application adopts the design of browser plug-ins, allowing users to easily and conveniently expand and upgrade the functions of the system.
[0081] 2. Strong maintainability. This application uses the separation of client and server, which enables us to better maintain the system. The client is responsible for interacting with users, while the server is responsible for processing business logic and data storage. This separation helps to achieve the goals of clear responsibilities, easy management and iterative optimization, and also facilitates deployment and expansion in different environments and platforms.
[0082] 3. Strong portability and compatibility: The client is developed in the form of a browser plug-in and has wide applicability. This means that users can use this solution seamlessly on different mainstream operating systems (such as Windows, macOS, Linux, etc.) and browsers (such as Chrome, Firefox, Edge, etc.), ensuring the best user experience.
[0083] It is obvious that a person skilled in the art may make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.
Claims
1. A civil aviation e-commerce system with persistent debugging session, characterized in that: include: Rule matching module, rule analysis module and persistence module; The rule matching module is set on the client side, and the rule analysis module and the persistence module are set on the server side; wherein, The rule matching module is configured as follows: When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
2. The civil aviation e-commerce system with persistent debugging session as claimed in claim 1, characterized in that: The client is a browser; the rule matching module includes: a browser with a script mounter installed and a debugging session log collection script.
3. The civil aviation e-commerce system with persistent debugging session as claimed in claim 2, characterized in that: The rule matching module is configured to: after receiving the debugging instruction sent by the user, load the graphical interface through jQuery technology; wherein, The graphical interface is configured to respond to a user's log collection instruction; the graphical interface includes a text input box and a click button.
4. The civil aviation e-commerce system with persistent debugging session as claimed in claim 3, characterized in that: The rule matching module is configured to: after responding to the user's collection instruction through the graphical interface, verify whether the response to the collection instruction is successful based on whether there is an activated debugging session log message pair on the current webpage.
5. The civil aviation e-commerce system with persistent debugging session as claimed in claim 4, characterized in that: The graphical interface is configured to: visually output the debugging session log upload status and the debugging session log download status.
6. The civil aviation e-commerce system with persistent debugging session as claimed in claim 2, characterized in that: Also includes: A log processing module provided on the client; The rule matching module is configured as follows: The rule analysis module is used to query whether there is a debugging session log to be uploaded in the persistence module. If not, the debugging session log to be uploaded is screened by the log processing module.
7. The civil aviation e-commerce system with persistent debugging session as claimed in claim 1, characterized in that: The rule matching module is configured as follows: After downloading the historical debugging session log corresponding to the download instruction from the persistence module, a deletion command is sent to the persistence module, so that the persistence module deletes the historical debugging session log stored in the persistence module.
8. A method for debugging a civil aviation e-commerce system based on the system according to any one of claims 1 to 7, characterized in that: include: Using the rule matching module, the following method is executed: When receiving a collection instruction sent by a user or the domain name of the current webpage contains a target keyword, collecting the debugging session log of the current webpage, and sending the debugging session log to the persistence module for storage through the rule analysis module; and In response to a download instruction sent by a user, a historical debugging session log corresponding to the download instruction is downloaded from the persistence module.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program or instruction, and when the computer program or instruction is executed by the processor, it is at least used to implement the method of claim 8.
10. A computer program product, the computer program product being stored in a computer-readable storage medium, characterized in that: When the computer program product is executed by a processor, it is used to at least implement the method of claim 8.