A business update method, apparatus, device and its storage medium
By updating component configuration files through configuration, the problem of frequent code modifications caused by complex business logic is solved, enabling rapid business updates and convenient maintenance.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA PING AN PROPERTY INSURANCE CO LTD
- Filing Date
- 2024-10-25
- Publication Date
- 2026-05-26
AI Technical Summary
In existing technologies, when the business logic is complex, a large amount of code needs to be modified and the version needs to be redeployed, resulting in untimely business response and making maintenance and management difficult.
A configuration-based update component is adopted. By parsing business update commands and building configuration files, business updates are achieved, avoiding the need to modify business code. Updates are performed using configuration files.
It enables rapid business update response and facilitates subsequent maintenance, avoiding the need to modify a large amount of code and redeploy versions.
Smart Images

Figure CN119473347B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of research and development design technology, and is applied to the scenario of updating business branch processing logic, and particularly to a business update method, device, equipment and its storage medium. Background Technology
[0002] In conventional development, business logic is mostly defined by "if...then...otherwise..." statements. This leads to a large amount of "if...then...otherwise..." conditional logic code in scenarios with complex business logic, which is not conducive to business maintenance.
[0003] Moreover, when adjustments are needed to the judgment logic, it often requires modifying a large amount of code and redeploying the code version, which takes a long time and results in untimely business response, which is not conducive to business management. Summary of the Invention
[0004] The purpose of this application is to provide a business update method, apparatus, device and storage medium to solve the problem that updating the existing branch processing structure often requires modifying a large amount of code and re-releasing the code version, which takes a long time and results in untimely business response, which is not conducive to business maintenance and management.
[0005] To address the aforementioned technical problems, this application provides a service update method, which employs the following technical solution:
[0006] A business update method includes the following steps:
[0007] Receive service update instructions issued by the target service update terminal;
[0008] Parse the business update instruction to obtain the target update item;
[0009] Based on the preset configurable update components and the target update items, the service is updated in response to the service update instruction.
[0010] Furthermore, before executing the step of receiving the service update instruction issued by the target service update terminal, the method further includes:
[0011] Analyze the target business source code to obtain all the business logic judgment conditions contained in the target business source code, as well as the branch execution interface corresponding to each of the business logic judgment conditions;
[0012] All business logic judgment conditions contained in the target business source code are distinguished and marked.
[0013] Based on the branch execution interfaces corresponding to all business logic judgment conditions, the business processing code involved in all branch execution interfaces is modularized and organized to obtain the execution code blocks corresponding to each branch execution interface.
[0014] Based on the distinguishing markers and the branch execution interfaces corresponding to all business logic judgment conditions, the branch processing methods are encapsulated for the execution code blocks corresponding to all branch execution interfaces.
[0015] Based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each business logic judgment condition, a configuration file is constructed with data tuple-form fields as configuration items. Each configuration item in the configuration file contains at least one data tuple-form field. Each data tuple-form field contains at least one target distinguishing marker, the judgment field in the business logic judgment condition corresponding to the target distinguishing marker, and the call address of the encapsulated branch processing method corresponding to the target distinguishing marker.
[0016] The configuration file is deployed as a reference configuration file to the preset configuration update component.
[0017] Furthermore, the step of encapsulating the branch processing method for the execution code block corresponding to each branch execution interface by combining the distinguishing marker and the branch execution interface corresponding to each of the business logic judgment conditions specifically includes:
[0018] Based on the branch execution interfaces corresponding to each of the business logic judgment conditions, and the distinguishing markers of each of the business logic judgment conditions, identify the branch execution interfaces corresponding to each of the distinguishing markers.
[0019] Based on the branch execution interface corresponding to each of the distinguishing markers, the execution code block corresponding to each branch execution interface is encapsulated into a branch processing method, and the corresponding distinguishing marker is set for each of the encapsulated branch processing methods.
[0020] Furthermore, after executing the step of constructing a configuration file with data tuple-style fields as configuration items based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each business logic judgment condition, the method further includes:
[0021] Based on the pre-defined business execution logic document, determine whether there is a hierarchical execution relationship between any branch execution interfaces;
[0022] If there is a hierarchical execution relationship between the branch execution interfaces, then the branch execution interfaces with the hierarchical execution relationship are selected.
[0023] Based on the branch execution interface with hierarchical execution relationship, determine the configuration items with hierarchical association relationship;
[0024] All hierarchical relationships between configuration items are added to the configuration file as supplementary configuration information.
[0025] Furthermore, the step of parsing the business update instruction to obtain the target update item specifically includes:
[0026] The business update instruction is parsed to obtain the business logic judgment conditions that need to be updated in the target update item, as well as the branch execution interface call relationship that needs to be updated in the target update item.
[0027] Furthermore, the step of performing a service update in response to the service update instruction based on the preset configuration update component and the target update item includes:
[0028] Identify the business logic judgment conditions that need to be updated in the target update items;
[0029] Based on the business logic judgment conditions that need to be updated, the first configuration item to be updated is found in the reference configuration file of the configuration update component;
[0030] The first configuration item to be updated is parsed to obtain the corresponding data tuple field.
[0031] The data tuple-form fields are parsed to identify the judgment fields in the business logic judgment conditions that need to be updated.
[0032] Identify the latest judgment field used to replace the judgment field in the target update item;
[0033] Replace the judgment field in the data tuple form field with the latest judgment field to obtain the configuration item after updating the first configuration item to be updated.
[0034] Furthermore, the step of performing a service update in response to the service update instruction based on the preset configuration update component and the target update item also includes:
[0035] Identify the branch execution interface that needs to be updated in the target update item;
[0036] The second configuration item to be updated is found in the reference configuration file of the configuration update component according to the branch execution interface that needs to be updated;
[0037] The second configuration item to be updated is parsed to obtain the corresponding data tuple field;
[0038] The data tuple field is parsed to identify the call address of the branch processing method corresponding to the branch execution interface that needs to be updated;
[0039] Identify the latest call address used to replace the call address in the target update item;
[0040] Replace the call address in the data tuple field with the latest call address to obtain the updated configuration item for the second configuration item to be updated.
[0041] To address the aforementioned technical problems, this application also provides a service update apparatus, which employs the following technical solution:
[0042] A service update device, comprising:
[0043] The service update instruction receiving module is used to receive service update instructions issued by the target service update terminal.
[0044] The business update instruction parsing module is used to parse the business update instruction to obtain the target update item;
[0045] The business update response module is used to perform business updates in response to the business update instruction based on the preset configurable update components and the target update items.
[0046] To address the aforementioned technical problems, this application also provides a computer device that employs the following technical solution:
[0047] A computer device includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the business update method described above.
[0048] To address the aforementioned technical problems, this application also provides a computer-readable storage medium, employing the technical solution described below:
[0049] A computer-readable storage medium storing computer-readable instructions, which, when executed by a processor, implement the steps of the business update method described above.
[0050] Compared with the prior art, the embodiments of this application have the following main advantages:
[0051] The business update method described in this application embodiment receives a business update instruction issued by a target business update terminal; parses the business update instruction to obtain the target update item; and performs a business update in response to the business update instruction based on a preset configurable update component and the target update item. This achieves that when updating a business, if branch processing steps are involved, branch processing adjustments can be implemented in a configurable manner. This avoids modifying a large amount of business code and re-releasing the version, and also enables rapid business update response and facilitates subsequent business maintenance and management. Attached Figure Description
[0052] To more clearly illustrate the solutions in this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0053] Figure 1 This is an exemplary system architecture diagram to which this application can be applied;
[0054] Figure 2 This is a flowchart of one embodiment of the business update method according to this application;
[0055] Figure 3 This is a flowchart of a specific embodiment of the business update method described in this application, which involves constructing a configuration file based on the business source code.
[0056] Figure 4 yes Figure 3 A flowchart of a specific embodiment of step 304 shown;
[0057] Figure 5 This is a flowchart of a specific embodiment of the business update method described in this application, which involves supplementing the configuration information in the configuration file;
[0058] Figure 6 yes Figure 2 A flowchart of a specific embodiment of step 203 shown;
[0059] Figure 7 yes Figure 2 A flowchart of another specific embodiment of step 203 shown;
[0060] Figure 8 This is a schematic diagram of a structure of an embodiment of the service update apparatus according to this application;
[0061] Figure 9 yes Figure 8 The diagram shows a specific embodiment of the service update response module 803.
[0062] Figure 10 This is a schematic diagram of the structure of one embodiment of the computer device according to this application. Detailed Implementation
[0063] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein in the specification of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having," and any variations thereof, in the specification, claims, and foregoing drawings of this application, are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the specification, claims, or foregoing drawings of this application are used to distinguish different objects, not to describe a particular order.
[0064] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0065] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
[0066] like Figure 1 As shown, system architecture 100 may include terminal device 101, network 102, and server 103. Terminal device 101 may be a laptop 1011, tablet 1012, or mobile phone 1013. Network 102 is used as a medium to provide a communication link between terminal device 101 and server 103. Network 102 may include various connection types, such as wired, wireless communication links, or fiber optic cables.
[0067] Users can use terminal device 101 to interact with server 103 via network 102 to receive or send messages, etc. Various communication client applications can be installed on terminal device 101, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social media platform software, etc.
[0068] Terminal device 101 can be various electronic devices with a display screen and support web browsing. In addition to laptops 1011, tablets 1012, or mobile phones 1013, terminal device 101 can also be e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III), MP4 players (Moving Picture Experts Group Audio Layer IV), laptops, and desktop computers.
[0069] Server 103 can be a server that provides various services, such as a backend server that provides support for the pages displayed on terminal device 101.
[0070] It should be noted that the service update method provided in this application embodiment is generally executed by the server, and correspondingly, the service update device is generally located in the server.
[0071] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.
[0072] Continue to refer to Figure 2 A flowchart of an embodiment of a service update method according to this application is shown. The service update method includes the following steps:
[0073] Step 201: Receive the service update instruction issued by the target service update terminal.
[0074] In this embodiment, the target business update terminal includes a business server terminal. Generally, after the business server terminal performs targeted updates to the business logic code, it issues a business update instruction to the server so that the server can complete the business update and adjustment as soon as possible.
[0075] In this embodiment, the business logic code update refers more specifically to updating the branch processing logic involving judgment, which generally includes updating the judgment conditions and updating the branch processing interface.
[0076] In this embodiment, receiving generally refers to the service update processor receiving a service update instruction issued by the target service update terminal. Then, the service update processor performs a service update according to the service update instruction and deploys the service update result to the server, thereby completing the service update adjustment.
[0077] Step 202: Parse the business update instruction to obtain the target update item.
[0078] In this embodiment, it is understood that the business update instruction includes not only an update processing instruction, but also relevant information for obtaining the target update item. For example, the target update item may be organized into a structured form or structured document, and the storage address information of the structured form or structured document may be received along with the business update instruction. Then, the target update item may be obtained through parsing. Of course, it is not excluded that the data in the structured form or structured document may be directly transmitted fields. When the business update instruction is received, the transmitted fields may also be directly received, and then the target update item may be obtained through parsing.
[0079] Step 203: Based on the preset configuration update components and the target update item, respond to the service update instruction and perform a service update.
[0080] In this embodiment, by combining a preset configurable update component, the service is updated, realizing service updates in a configurable manner. This avoids the need to modify a large amount of business logic code when releasing a new service update. Service updates can be achieved simply by modifying the configuration file. This ensures both rapid response after the service update and that future maintenance only requires maintaining the configuration file, thus avoiding maintenance difficulties.
[0081] In this embodiment, a business update instruction issued by the target business update terminal is received; the instruction is parsed to obtain the target update item; and a business update is performed in response to the instruction based on a preset configurable update component and the target update item. This enables the adjustment of branch processing steps in a configurable manner when updating business processes, avoiding the need to modify a large amount of business code and re-release the version, while also enabling rapid business update response and facilitating subsequent business maintenance and management.
[0082] Continue to refer to Figure 3 In some optional implementations, a step of building a configuration file based on the business source code is included before step 201. Figure 3 This is a flowchart of a specific embodiment of the business update method described in this application, which involves building a configuration file based on the business source code, and includes the following steps:
[0083] Step 301: Parse the target business source code to obtain all the business logic judgment conditions contained in the target business source code, as well as the branch execution interface corresponding to each of the business logic judgment conditions.
[0084] By parsing the target business source code, all business logic judgment conditions contained in the target business source code, as well as the branch execution interfaces corresponding to each business logic judgment condition, are obtained. This facilitates the subsequent construction of configuration files based on all business logic judgment conditions contained in the target business source code and the branch execution interfaces corresponding to each business logic judgment condition.
[0085] Step 302: Differentiate and mark all business logic judgment conditions contained in the target business source code;
[0086] By distinguishing and marking all the business logic judgment conditions contained in the target business source code, different configuration items can be identified in the completed configuration file.
[0087] Step 303: Based on the branch execution interfaces corresponding to all business logic judgment conditions, modularize the business processing code involved in all branch execution interfaces to obtain the execution code blocks corresponding to each branch execution interface.
[0088] By modularizing the business processing code involved in all branch execution interfaces, the execution code blocks corresponding to each branch execution interface are obtained, which facilitates the modularization of the entire business source code and makes subsequent business updates and maintenance management easier.
[0089] Step 304: Combining the distinguishing markers and the branch execution interfaces corresponding to all business logic judgment conditions, encapsulate the branch processing methods for the execution code blocks corresponding to all branch execution interfaces.
[0090] By encapsulating the execution code blocks corresponding to each branch execution interface into branch processing methods, the corresponding encapsulated methods can be directly called when executing branch steps, and the corresponding encapsulated methods can be directly updated when updating branch steps, which facilitates business updates and management and maintenance.
[0091] Step 305: Based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each business logic judgment condition, construct a configuration file with data tuple-form fields as configuration items. Each configuration item in the configuration file contains at least one data tuple-form field, and each data tuple-form field contains at least one target distinguishing marker, the judgment field in the business logic judgment condition corresponding to the target distinguishing marker, and the call address of the encapsulated branch processing method corresponding to the target distinguishing marker.
[0092] Specifically, for example: the target business source code contains a branch processing structure, which includes a first judgment condition and a second judgment condition. When the judgment result meets the first judgment condition, the corresponding first branch execution interface is executed; when the judgment result meets the second judgment condition, the corresponding second branch execution interface is executed. It can be understood that when the first or second branch execution interface is called, what is actually executed is the branch processing method encapsulated in the interface. Assuming the difference marker for the first judgment condition is con_A, the difference marker for the second judgment condition is con_B, and the judgment field is "whether the comparison value is greater than 5", if the comparison value is greater than 5, the corresponding first branch execution interface is executed; if the comparison value is not greater than 5, the corresponding second branch execution interface is executed. The call address of the branch processing method corresponding to the first branch execution interface is address a, and the call address of the branch processing method corresponding to the second branch execution interface is address b. Then, based on the branch processing structure, two configuration items are constructed: ("con_A", "whether the comparison value is greater than 5", "a") and ("con_B", "whether the comparison value is greater than 5", "b").
[0093] By parsing and processing the target business source code, a configuration file is constructed based on the branch processing structure involved in the business source code, with data tuple fields as configuration items. This allows for direct updates to the corresponding configuration items in the configuration file when updating the branch processing structure involved in the business source code. The business update is achieved by replacing the source code update method with the configuration file update method, avoiding the modification of a large amount of business code and facilitating business maintenance and management.
[0094] Step 306: Deploy the configuration file as a reference configuration file to the preset configuration update component.
[0095] By deploying the configuration file as a reference configuration file into the preset configuration update component, subsequent business updates can be performed directly using the configuration update component.
[0096] Continue to refer to Figure 4 In some optional implementations, Figure 4 yes Figure 3 A flowchart of a specific embodiment of step 304 shown includes the following steps:
[0097] Step 401: Based on the branch execution interfaces corresponding to each of the business logic judgment conditions and the distinction markers of each of the business logic judgment conditions, identify the branch execution interfaces corresponding to each of the distinction markers.
[0098] Step 402: Based on the branch execution interface corresponding to each of the differentiating markers, encapsulate the branch processing method for each of the execution code blocks corresponding to each of the branch execution interfaces, and set the corresponding differentiating marker for each of the encapsulated branch processing methods.
[0099] Specifically, by identifying the branch execution interfaces corresponding to all the distinguishing markers, the execution code blocks corresponding to all the branch execution interfaces are encapsulated into branch processing methods, and corresponding distinguishing markers are set for all the encapsulated branch processing methods. This facilitates the construction of the correspondence between the distinguishing markers, the judgment fields, and the call addresses of the branch processing methods, thereby facilitating the construction of the data tuple-form fields, which is more based on evidence and scientific.
[0100] Continue to refer to Figure 5 In some optional implementations, step 305 includes a step of supplementing the configuration information in the configuration file. Figure 5 This is a flowchart of a specific embodiment of the business update method described in this application, which supplements the configuration information in the configuration file, and includes the following steps:
[0101] Step 501: Based on the preset business execution logic document, determine whether there is a hierarchical execution relationship between any branch execution interfaces;
[0102] Specifically, it determines whether there are multi-level branches. If there are no branches and the execution interfaces have a hierarchical execution relationship, then step 306 is executed directly. Of course, since business execution logic is generally quite complex, there are multi-level branches in most cases. Therefore, the case of directly executing step 306 is rare, and it will not be explained in detail here.
[0103] Step 502: If there is a hierarchical execution relationship between the branch execution interfaces, then filter out the branch execution interfaces that have a hierarchical execution relationship.
[0104] Step 503: Based on the branch execution interface with hierarchical execution relationship, determine the configuration items with hierarchical association relationship;
[0105] Step 504: Add the hierarchical relationships between all configuration items to the configuration file as additional configuration information.
[0106] By using a pre-defined business execution logic document, it is determined whether there is a hierarchical execution relationship between any branch execution interfaces. Based on the branch execution interfaces with hierarchical execution relationships, configuration items with hierarchical associations are identified. The hierarchical associations between all configuration items are added to the configuration file as additional configuration information to ensure that the configuration file fully integrates with the business logic. This allows for adjustments to branch processing steps when the business is updated, based on the additional configuration information. The branch processing adjustments are implemented according to the configuration file, avoiding the need to modify a large amount of business code and facilitating business maintenance and management.
[0107] In this embodiment, the step of parsing the business update instruction to obtain the target update item specifically includes: parsing the business update instruction to obtain the business logic judgment conditions that need to be updated in the target update item, and obtaining the branch execution interface call relationship that needs to be updated in the target update item.
[0108] Specifically, it should be understood that the target update item may only include updating a certain business logic judgment condition, or only include updating a certain branch execution interface call relationship, or it may simultaneously update the logic judgment condition and the branch execution interface call relationship in a configuration item, or it may simultaneously update a batch of business logic judgment conditions and update multiple branch execution interface call relationships, depending on the actual business update requirements.
[0109] Continue to refer to Figure 6 In some optional implementations, Figure 6 yes Figure 2 A flowchart of a specific embodiment of step 203 shown includes the following steps:
[0110] Step 601: Identify the business logic judgment conditions that need to be updated in the target update item;
[0111] Step 602: Based on the business logic judgment conditions that need to be updated, find the first configuration item to be updated from the reference configuration file of the configuration update component;
[0112] Step 603: Parse the first configuration item to be updated to obtain the corresponding data tuple field;
[0113] Step 604: Parse the data tuple format field to identify the judgment field in the business logic judgment condition that needs to be updated;
[0114] Step 605: Identify the latest judgment field in the target update item used to replace the judgment field;
[0115] Step 606: Replace the judgment field in the data tuple form field with the latest judgment field to obtain the configuration item after updating the first configuration item to be updated.
[0116] By identifying the target update items, when it is determined that the judgment field needs to be updated, the corresponding configuration items are updated using steps 601 to 606 above. This allows the business to be executed directly based on the configuration item update results during subsequent business execution, avoiding the need to modify a large amount of business code and facilitating subsequent business maintenance and management.
[0117] Continue to refer to Figure 7 In some optional implementations, Figure 7 yes Figure 2 A flowchart of another specific embodiment of step 203 shown includes the following steps:
[0118] Step 701: Identify the branch execution interface that needs to be updated in the target update item;
[0119] Step 702: Based on the branch execution interface to be updated, find the second configuration item to be updated from the reference configuration file of the configuration update component;
[0120] Step 703: Parse the second configuration item to be updated to obtain the corresponding data tuple field;
[0121] Step 704: Parse the data tuple field to identify the call address of the branch processing method corresponding to the branch execution interface that needs to be updated;
[0122] Step 705: Identify the latest call address used to replace the call address in the target update item;
[0123] Step 706: Replace the call address in the data tuple form field with the latest call address to obtain the updated configuration item for the second configuration item to be updated.
[0124] Similarly, by identifying the target update items, when it is determined that the branch execution interface needs to be updated, the corresponding configuration items are updated using steps 701 to 706 above. This allows the business to be executed directly based on the configuration item update results during subsequent business execution, avoiding the need to modify a large amount of business code and facilitating subsequent business maintenance and management.
[0125] In this embodiment, the first configuration item to be updated and the second configuration item to be updated specifically refer to updating different fields in the data tuple format field. Specifically, the first configuration item to be updated refers to updating the judgment field in the configuration item of the reference configuration file, and the second configuration item to be updated refers to updating the call address of the branch processing method in the configuration item of the reference configuration file.
[0126] This application receives a business update instruction issued by a target business update terminal; parses the business update instruction to obtain the target update item; and performs a business update in response to the business update instruction based on a preset configurable update component and the target update item. This enables the use of a configurable approach to adjust branch processing steps during business updates, avoiding the need to modify extensive business code and re-release versions, while also enabling rapid business update responses and facilitating subsequent business maintenance and management.
[0127] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.
[0128] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0129] In this embodiment, a business update instruction is received from the target business update terminal; the instruction is parsed to obtain the target update item; and a business update is performed in response to the instruction based on a preset configurable update component and the target update item. This enables the adjustment of branch processing steps in a configurable manner during business updates, avoiding the need to modify a large amount of business code and re-release the version, while also enabling rapid business update response and facilitating subsequent business maintenance and management.
[0130] Further reference Figure 8 As a response to the above Figure 2 To implement the method shown, this application provides an embodiment of a service update device, which is similar to... Figure 2 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.
[0131] like Figure 8 As shown, the service update device 800 described in this embodiment includes: a service update instruction receiving module 801, a service update instruction parsing module 802, and a service update response module 803. Wherein:
[0132] The service update instruction receiving module 801 is used to receive service update instructions issued by the target service update terminal.
[0133] The business update instruction parsing module 802 is used to parse the business update instruction to obtain the target update item;
[0134] The business update response module 803 is used to perform business updates in response to the business update instruction based on the preset configurable update components and the target update item.
[0135] Continue to refer to Figure 9 , Figure 9 yes Figure 8 The diagram shows a specific embodiment of the service update response module 803, which includes a first response submodule 901 and a second response submodule 902.
[0136] The first response submodule 901 is configured to: identify the business logic judgment conditions that need to be updated in the target update item; locate the first configuration item to be updated from the reference configuration file of the configuration update component based on the business logic judgment conditions to be updated; parse the first configuration item to be updated to obtain the corresponding data tuple form field; parse the data tuple form field to identify the judgment field in the business logic judgment conditions to be updated; identify the latest judgment field in the target update item used to replace the judgment field; and replace the judgment field in the data tuple form field with the latest judgment field to obtain the configuration item after updating the first configuration item to be updated.
[0137] The second response submodule 902 is configured to: identify the branch execution interface that needs to be updated in the target update item; locate the second configuration item to be updated from the reference configuration file of the configuration update component based on the branch execution interface to be updated; parse the second configuration item to be updated to obtain the corresponding data tuple form field; parse the data tuple form field to identify the call address of the branch processing method corresponding to the branch execution interface to be updated; identify the latest call address used to replace the call address in the target update item; and replace the call address in the data tuple form field with the latest call address to obtain the configuration item after updating the second configuration item to be updated.
[0138] This application receives a business update instruction issued by a target business update terminal; parses the business update instruction to obtain the target update item; and performs a business update in response to the business update instruction based on a preset configurable update component and the target update item. This enables the use of a configurable approach to adjust branch processing steps during business updates, avoiding the need to modify extensive business code and re-release versions, while also enabling rapid business update responses and facilitating subsequent business maintenance and management.
[0139] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing related hardware through computer-readable instructions. These computer-readable instructions can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the methods described above. The aforementioned storage medium can be a non-volatile storage medium such as a magnetic disk, optical disk, or read-only memory (ROM), or random access memory (RAM).
[0140] It should be understood that although the steps in the flowcharts of the accompanying figures are shown sequentially as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the accompanying figures may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the sub-steps or stages of other steps.
[0141] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 10 , Figure 10 This is a basic structural block diagram of the computer device in this embodiment.
[0142] The computer device 10 includes a memory 10a, a processor 10b, and a network interface 10c, which are interconnected via a system bus. It should be noted that... Figure 10Only a computer device 10 with component memory 10a, processor 10b, and network interface 10c is shown. However, it should be understood that it is not required to implement all the components shown, and more or fewer components may be implemented instead. Those skilled in the art will understand that the computer device described herein is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions. Its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.
[0143] The computer device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device can interact with the user via a keyboard, mouse, remote control, touchpad, or voice control.
[0144] The memory 10a includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 10a may be an internal storage unit of the computer device 10, such as the hard disk or memory of the computer device 10. In other embodiments, the memory 10a may also be an external storage device of the computer device 10, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc. Of course, the memory 10a may include both internal storage units and external storage devices of the computer device 10. In this embodiment, the memory 10a is typically used to store the operating system and various application software installed on the computer device 10, such as computer-readable instructions for a business update method. In addition, the memory 10a can also be used to temporarily store various types of data that have been output or will be output.
[0145] In some embodiments, the processor 10b may be a central processing unit (CPU), controller, microcontroller, microprocessor, or other data processing chip. The processor 10b is typically used to control the overall operation of the computer device 10. In this embodiment, the processor 10b is used to execute computer-readable instructions stored in the memory 10a or to process data, such as executing computer-readable instructions for the business update method.
[0146] The network interface 10c may include a wireless network interface or a wired network interface, which is typically used to establish communication connections between the computer device 10 and other electronic devices.
[0147] The computer device proposed in this embodiment belongs to the field of research and development design technology and is applied in the scenario of updating business branch processing logic. This application receives a business update instruction issued by the target business update terminal; parses the business update instruction to obtain the target update item; and, based on a preset configurable update component and the target update item, responds to the business update instruction to perform a business update. This achieves that when updating a business, if it involves updating branch processing steps, branch processing adjustments can be implemented in a configurable manner. This avoids modifying a large amount of business code and re-releasing the version, and also enables rapid business update response and facilitates subsequent business maintenance and management.
[0148] This application also provides another embodiment, namely, providing a computer-readable storage medium storing computer-readable instructions that can be executed by a processor to cause the processor to perform the steps of the business update method described above.
[0149] The computer-readable storage medium proposed in this embodiment belongs to the field of research and development design technology and is applied in the scenario of updating business branch processing logic. This application receives a business update instruction issued by the target business update terminal; parses the business update instruction to obtain the target update item; and, based on a preset configurable update component and the target update item, responds to the business update instruction to perform a business update. This achieves that when updating a business, if it involves updating branch processing steps, branch processing adjustments can be implemented in a configurable manner. This avoids modifying a large amount of business code and re-releasing the version, and also enables rapid business update response and facilitates subsequent business maintenance and management.
[0150] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0151] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, the purpose of providing these embodiments is to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.
Claims
1. A business update method, characterized in that, Includes the following steps: Receiving a service update instruction issued by the target service update terminal, wherein, before executing the step of receiving the service update instruction issued by the target service update terminal, the method further includes: Analyze the target business source code to obtain all the business logic judgment conditions contained in the target business source code, as well as the branch execution interface corresponding to each of the business logic judgment conditions; All business logic judgment conditions contained in the target business source code are distinguished and marked. Based on the branch execution interfaces corresponding to all business logic judgment conditions, the business processing code involved in all branch execution interfaces is modularized and organized to obtain the execution code blocks corresponding to each branch execution interface. Based on the distinguishing markers and the branch execution interfaces corresponding to all business logic judgment conditions, the branch processing methods are encapsulated for the execution code blocks corresponding to all branch execution interfaces. Based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each business logic judgment condition, a configuration file is constructed with data tuple-form fields as configuration items. Each configuration item in the configuration file contains at least one data tuple-form field. Each data tuple-form field contains at least one target distinguishing marker, the judgment field in the business logic judgment condition corresponding to the target distinguishing marker, and the call address of the encapsulated branch processing method corresponding to the target distinguishing marker. The configuration file is deployed as a reference configuration file to a preset configuration update component; Parse the business update instruction to obtain the target update item; Based on the preset configurable update components and the target update items, in response to the service update instruction, a service update is performed.
2. The business update method according to claim 1, characterized in that, The step of encapsulating the branch processing method for the execution code block corresponding to each branch execution interface by combining the distinguishing marker and the branch execution interface corresponding to each of the business logic judgment conditions specifically includes: Based on the branch execution interfaces corresponding to each of the business logic judgment conditions, and the distinguishing markers of each of the business logic judgment conditions, identify the branch execution interfaces corresponding to each of the distinguishing markers. Based on the branch execution interface corresponding to each of the distinguishing markers, the execution code block corresponding to each branch execution interface is encapsulated into a branch processing method, and the corresponding distinguishing marker is set for each of the encapsulated branch processing methods.
3. The business update method according to claim 1, characterized in that, After executing the step of constructing a configuration file with data tuple-style fields as configuration items based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each of the business logic judgment conditions, the method further includes: Based on the pre-defined business execution logic document, determine whether there is a hierarchical execution relationship between any branch execution interfaces; If there is a hierarchical execution relationship between the branch execution interfaces, then the branch execution interfaces with the hierarchical execution relationship are selected. Based on the branch execution interface with hierarchical execution relationship, determine the configuration items with hierarchical association relationship; All hierarchical relationships between configuration items are added to the configuration file as supplementary configuration information.
4. The business update method according to claim 1, characterized in that, The step of parsing the business update instruction to obtain the target update item specifically includes: The business update instruction is parsed to obtain the business logic judgment conditions that need to be updated in the target update item, as well as the branch execution interface call relationship that needs to be updated in the target update item.
5. The business update method according to claim 4, characterized in that, The step of performing a service update in response to the service update instruction based on the preset configuration update component and the target update item includes: Identify the business logic judgment conditions that need to be updated in the target update items; Based on the business logic judgment conditions that need to be updated, the first configuration item to be updated is found in the reference configuration file of the configuration update component; The first configuration item to be updated is parsed to obtain the corresponding data tuple field. The data tuple-form fields are parsed to identify the judgment fields in the business logic judgment conditions that need to be updated. Identify the latest judgment field used to replace the judgment field in the target update item; Replace the judgment field in the data tuple form field with the latest judgment field to obtain the configuration item after updating the first configuration item to be updated.
6. The business update method according to claim 4, characterized in that, The step of performing a service update in response to the service update instruction based on the preset configurable update component and the target update item further includes: Identify the branch execution interface that needs to be updated in the target update item; The second configuration item to be updated is found in the reference configuration file of the configuration update component according to the branch execution interface that needs to be updated; The second configuration item to be updated is parsed to obtain the corresponding data tuple field; The data tuple field is parsed to identify the call address of the branch processing method corresponding to the branch execution interface that needs to be updated; Identify the latest call address used to replace the call address in the target update item; Replace the call address in the data tuple field with the latest call address to obtain the updated configuration item for the second configuration item to be updated.
7. A service update device, characterized in that, include: A service update instruction receiving module is used to receive service update instructions issued by a target service update terminal. Prior to receiving the service update instructions issued by the target service update terminal, the module further includes: Analyze the target business source code to obtain all the business logic judgment conditions contained in the target business source code, as well as the branch execution interface corresponding to each of the business logic judgment conditions; All business logic judgment conditions contained in the target business source code are distinguished and marked. Based on the branch execution interfaces corresponding to all business logic judgment conditions, the business processing code involved in all branch execution interfaces is modularized and organized to obtain the execution code blocks corresponding to each branch execution interface. Based on the distinguishing markers and the branch execution interfaces corresponding to all business logic judgment conditions, the branch processing methods are encapsulated for the execution code blocks corresponding to all branch execution interfaces. Based on the distinguishing marker, all business logic judgment conditions, and the branch execution interface corresponding to each business logic judgment condition, a configuration file is constructed with data tuple-form fields as configuration items. Each configuration item in the configuration file contains at least one data tuple-form field. Each data tuple-form field contains at least one target distinguishing marker, the judgment field in the business logic judgment condition corresponding to the target distinguishing marker, and the call address of the encapsulated branch processing method corresponding to the target distinguishing marker. The configuration file is deployed as a reference configuration file to a preset configuration update component; The business update instruction parsing module is used to parse the business update instruction to obtain the target update item; The business update response module is used to perform business updates in response to the business update instruction based on the preset configurable update components and the target update items.
8. A computer device, characterized in that, The system includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the service update method as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the service update method as described in any one of claims 1 to 6.