Transaction order processing method and transaction routing gateway
By configuring predefined routing rules in the transaction routing gateway, the routing rules management node can uniformly manage the routing of transaction orders, solving the problem of the transaction order processing system's dependence on local routing storage, reducing the risk of transaction failure, and improving system stability and processing capacity.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NETSUNION CLEARING CORP
- Filing Date
- 2024-10-28
- Publication Date
- 2026-04-28
AI Technical Summary
In existing technologies, transaction order processing systems rely heavily on local routing storage, which increases the risk of transaction order processing failures. In particular, when the data center fails, the loss of routing information or insufficient storage capacity can easily lead to transaction failures.
By configuring predefined routing rules in the transaction routing gateway, the routing rules management node can uniformly manage the routing of transaction orders, reducing the dependence on local routing storage and enabling flexible routing and data querying of transaction orders.
It effectively reduces the risk of transaction order processing failures, improves the overall stability and flexibility of the system, reduces the dependence on local storage, and can reasonably allocate transaction orders to multiple data centers for processing, alleviating order congestion and improving the system's processing capacity.
Smart Images

Figure CN121940341A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of transaction order processing, and more particularly to a method for processing transaction orders and a transaction routing gateway. Background Technology
[0002] In the realm of transactions, users can execute transfers by sending transaction orders. A transaction order can include the order amount, the account initiating the transfer, and the target account information.
[0003] For massive transaction orders, multiple data centers can flexibly process them based on their local equipment status. For example, under normal equipment conditions, after a transaction order passes through the transaction routing gateway, it is processed by the local transaction processing node, and the processing result can be stored in the local transaction database. If the local transaction processing node malfunctions, the transaction routing gateway can determine the node to process the transaction based on the equipment status of other data centers, thus routing the transaction order and storing the routing information in the local routing storage for order retrieval. While this method offers flexible transaction order processing, the routing information relies on the local routing storage; a failure in the routing storage may lead to transaction failures.
[0004] How to reduce the risk of transaction order processing failure is the technical problem that this application aims to solve. Summary of the Invention
[0005] The purpose of this application is to provide a method for processing transaction orders and a transaction routing gateway to reduce the risk of transaction order processing failure.
[0006] Firstly, a method for processing transaction orders is provided, including: Determine the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; Receive pending transaction orders, which carry transaction attribute information; If there is a target routing rule in the routing rules that matches the transaction attribute information of the transaction order to be processed, then the transaction processing node of the target routing rule is determined as the target transaction processing node that matches the transaction order to be processed. The transaction order is routed to the target transaction processing node to instruct the target transaction processing node to process the transaction order to be processed.
[0007] Secondly, a transaction routing gateway is provided, including: The first determining module determines the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; The receiving module receives pending transaction orders, which carry transaction attribute information. The second determining module, if there is a target routing rule in the routing rules that matches the transaction attribute information of the transaction order to be processed, then determines the transaction processing node of the target routing rule as the target transaction processing node that matches the transaction order to be processed; The processing module routes the transaction order to the target transaction processing node, instructing the target transaction processing node to process the transaction order to be processed.
[0008] Thirdly, an electronic device is provided, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the method of the first aspect.
[0009] Fourthly, a computer-readable storage medium is provided on which a computer program is stored, which, when executed by a processor, implements the steps of the method of the first aspect.
[0010] Fifthly, a computer program product is provided, comprising a non-transitory computer-readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps of the method of the first aspect.
[0011] In this embodiment, by determining the routing rules configured by the routing rule management node for the transaction routing gateway, the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; receiving the transaction order to be processed, which carries transaction attribute information; if there is a target routing rule in the routing rules that matches the transaction attribute information of the transaction order to be processed, then the transaction processing node of the target routing rule is determined as the target transaction processing node matching the transaction order to be processed; the transaction order is routed to the target transaction processing node to instruct the target transaction processing node to process the transaction order to be processed, thus realizing the routing processing of the transaction order to be processed according to the pre-configured routing rules. Since the routing rules are pre-configured by the routing rule management node, the routing of transaction orders can be effectively managed through the routing rule management node, which is beneficial for realizing data query of transaction orders, reducing the dependence on local routing storage in the data center, and effectively reducing the risk of transaction order processing failure. Attached Figure Description
[0012] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments of this application and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1a This is a logical diagram illustrating the processing of transaction orders.
[0013] Figure 1b This is one of the flowcharts illustrating a method for processing transaction orders according to an embodiment of this application.
[0014] Figure 1c Based on Figure 1b A logical diagram illustrating the method for processing transaction orders.
[0015] Figure 2 This is a second schematic flowchart illustrating a method for processing transaction orders according to an embodiment of this application.
[0016] Figure 3 This is the third flowchart illustrating a method for processing transaction orders according to an embodiment of this application.
[0017] Figure 4 This is the fourth flowchart illustrating a method for processing transaction orders according to an embodiment of this application.
[0018] Figure 5 This is the fifth flowchart illustrating a method for processing transaction orders according to an embodiment of this application.
[0019] Figure 6 This is a flowchart illustrating a method for processing transaction orders according to an embodiment of this application.
[0020] Figure 7 This is a schematic diagram of the structure of a transaction routing gateway according to an embodiment of this application. Detailed Implementation
[0021] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application. The drawing numbers in this application are only used to distinguish the various steps in the solution and are not used to limit the execution order of the various steps. The specific execution order is subject to the description in the specification.
[0022] For massive transaction orders, multiple data centers can be used in practice to process them. For example... Figure 1aAs shown, the data centers used for transaction order processing include Data Center A, Data Center B, and other data centers. Each data center is equipped with a transaction routing gateway to receive transaction orders through the traffic inlet. Under normal conditions in each data center, transaction orders are processed in the data center where the transaction routing gateway is located. If a transaction processing malfunction, database failure, or other anomaly occurs, the transaction routing gateway can route the received transaction orders to other data centers so that the orders can be processed by a data center that is functioning normally.
[0023] like Figure 1a As shown, when the transaction processing function in data center A malfunctions (shown as dotted shades in the figure), the transaction routing gateway in data center A will route the received transaction orders to the "Transaction Processing" module in data center B to process the transaction orders.
[0024] While this approach ensures that transaction orders can be processed normally even when some data centers experience malfunctions, the data related to processed transaction orders will be stored in the data center where the processing actually took place. In this example, the transaction order that originally flowed into data center A was actually processed by data center B, resulting in the transaction data of that order being stored in data center B, specifically in its transaction database.
[0025] For transaction orders routed to other data centers for processing, relevant information can be retrieved by storing routing information. For example, for a transaction order flowing into data center A and processed by data center B, the transaction serial number and the data center identifier of the route can be stored in the routing storage of data center A. Specifically, it could be stored as Key: Data Center A Order Number, Value: B. This records in data center A's routing storage that the transaction order was actually processed by data center B. Subsequently, if data center A receives a query request for the aforementioned transaction order, it can retrieve the transaction order's processing information from the routing storage based on the transaction order's serial number, and then query the transaction order data from data center B's transaction database (i.e., the transaction repository).
[0026] Although it is possible to query transaction order information by storing routing information locally, this solution is highly dependent on local routing storage. If the routing storage in the data center fails, the routing information of the transaction order will be lost, which will lead to the failure of order query or transaction order processing.
[0027] Furthermore, with a massive volume of transaction orders, if the transaction processing function of a data center malfunctions, a large number of transactions may need to be routed to other data centers for processing. The routing storage capacity of the malfunctioning data center is often limited, and expanding and maintaining this storage capacity typically requires significant human and material resources. Moreover, the expansion process may impact the transaction order processing function, making it difficult to guarantee the overall stability of the system.
[0028] To address the problems existing in the prior art, embodiments of this application provide a method for processing transaction orders, applied to a transaction routing gateway, such as... Figure 1b As shown, it includes the following steps: S11: Determine the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order.
[0029] In this example, the transaction routing gateway can receive routing rules configured for it by the routing rule management node, or see [link to relevant documentation]. Figure 1c The transaction routing gateway can also send query commands to the routing rule management node. Figure 1c (Indicated by dashed arrows), enabling the rule management node to feed back routing rules to the transaction routing gateway. These routing rules can be generated by the routing rule management node and stored in the rule base ( Figure 1c Once configured as rule storage and assigned to the transaction routing gateway, the rule can be stored in the local rule base by the transaction routing gateway.
[0030] In practical applications, there can be multiple routing rules. Each routing rule can include the transaction attribute information of the transaction order and its matching transaction processing node. The transaction attribute information can specifically include information such as transaction time, transaction user, and transaction amount.
[0031] When a routing rule contains multiple routing rules, these rules can be assigned priorities. For example, a high-priority routing rule might be: "If a transaction order's transaction time falls within time period 'a' and the transaction user is merchant X, its matching transaction processing node is node B." A low-priority routing rule might be: "If a transaction order's transaction user is merchant X, its matching transaction processing node is node C." Then, based on the high-priority routing rule, transaction orders with the transaction user being merchant X and whose transaction time falls within time period 'a' will be routed to node B for processing. Based on the low-priority routing rule, transaction orders with the transaction user being merchant X and whose transaction time falls outside time period 'a' will be routed to node C for processing.
[0032] S12: Receive pending transaction orders, which carry transaction attribute information.
[0033] The transaction routing gateway can receive pending transaction orders through the traffic ingress of its data center. These pending transaction orders can specifically be request messages carrying various information, such as data center information, order time, merchant or institution information, and order amount. This information is used by the transaction routing gateway to determine whether to route the pending transaction order and, if so, which node to route it to for processing.
[0034] S13: If there is a target routing rule in the routing rules that matches the transaction attribute information of the pending transaction order, then the transaction processing node of the target routing rule is determined as the target transaction processing node that matches the pending transaction order.
[0035] Based on the transaction attribute information in the pending transaction orders, the transaction routing gateway queries the pre-configured routing rules to see if there is a matching target routing rule.
[0036] In practical applications, the above matching query can be executed according to actual needs to determine the target routing rule. This solution provides an optional example for determining the target routing rule: First, extract all transaction attribute information from the pending transaction orders. This transaction attribute information includes, for example, transaction time information and transaction user information.
[0037] Next, the system checks if there are any pre-configured routing rules that correspond to both the transaction time and the corresponding user information. If they exist, the found routing rule is designated as the target routing rule. If not, the system checks if there are any routing rules that correspond to either the transaction time or the corresponding user information. If they exist, the found routing rule is designated as the target routing rule.
[0038] In addition, if multiple routing rules are found, the routing rule with the highest priority can be selected as the target routing rule according to the pre-defined priorities of the multiple routing rules.
[0039] S14: The transaction order is routed to the target transaction processing node to instruct the target transaction processing node to process the transaction order to be processed.
[0040] Based on the target routing rules determined in the above steps, the target transaction processing node is identified. This target transaction processing node is the node that actually performs the processing of the aforementioned pending transaction orders. For example, see... Figure 1c Suppose that the transaction routing gateway in data center A determines, based on the target routing rules, that the target transaction processing node is the transaction processing node in data center B. Then, the transaction routing gateway will route the aforementioned pending transaction order to the transaction processing node in data center B for processing. The solution provided in this application allows the transaction routing gateway to pre-obtain routing rules from the routing rule management node. These routing rules can be pre-configured for the transaction routing gateway by the routing rule management node. Subsequently, upon receiving a transaction order to be processed, the transaction routing gateway determines whether a matching target routing rule exists based on the transaction attribute information of the order. Once a target routing rule is determined, the transaction order is routed to the target transaction processing node for processing. This enables routing processing of transaction orders according to the pre-configured routing rules. Because the routing rules are pre-configured by the routing rule management node, effective management of transaction order routing can be achieved through this node. This facilitates data retrieval of transaction orders, reduces reliance on local routing storage in the data center, and effectively reduces the risk of transaction order processing failures.
[0041] Furthermore, the solution provided in this application can be applied to systems containing multiple data centers. The routing rule management node uniformly configures routing rules for the transaction routing gateways of multiple data centers, enabling unified scheduling and management of transaction order routing. For massive influxes of transaction orders, it can more rationally distribute them across multiple data centers for coordinated processing, helping to alleviate transaction order congestion and fully utilize the performance resources of multiple data centers. Additionally, this solution facilitates unified storage, modification, and backup of routing rules, and allows for expansion of routing rule storage. If a query is needed for a transaction order, the target transaction processing node can be determined according to the preset routing rules in the routing rule management node, and then the query can be performed in the transaction order database of the target transaction processing node.
[0042] In this solution, the routing rule management node can be located in a single data center, and backup nodes can be set up in multiple data centers. Alternatively, the routing rule management node can be located outside the data center with transaction processing capabilities for independent maintenance and management.
[0043] Optionally, the transaction attribute information of the transaction order includes transaction time information and / or transaction user information.
[0044] In practical applications, routing rules can contain only transaction time information, only transaction user information, or both. Additionally, routing rules can also include other information such as the data center identifier for the route to be executed and the transaction amount.
[0045] For example, if the plan is to isolate all transactions in data center A for a certain period of time, and the routing rules specify the isolation period as 17:00:00 on November 1, 2021 to 10:00:00 on November 3, 2021, the routing rules will route all transaction orders with transaction attributes in data center A to data center B, so that the transaction order processing can be performed through the transaction processing nodes in data center B.
[0046] For example, if the plan is to route transactions from merchant X to data center C, and the routing rules specify that the time period for executing the routing is greater than 2021-01-01 00:00:00, the routing rules will route transaction orders with the transaction attribute of merchant X to data center C.
[0047] The solution provided in this application can accurately determine the matching target routing rules based on the transaction attribute information carried by the transaction order to be processed, and then determine the target transaction processing node to perform processing on the transaction order. By setting routing rules, unified routing management of transaction orders can be flexibly achieved, which is beneficial to meeting the complex application requirements in practical applications.
[0048] Based on the solutions provided in the above embodiments, optionally, such as Figure 2 As shown, it also includes the following steps: S21: Receive an order query instruction, which carries the transaction attribute information of the order to be queried.
[0049] After a transaction order is processed, users can query the processing results and related information using an order query command. Typically, an order query command is sent to the data center that received the transaction order. This command carries transaction attribute information used to query the order, which may include the order number, transaction time, merchant or institution information, and order amount. Optionally, this transaction attribute information can be the same as the transaction attribute information carried in the original transaction order.
[0050] In this step, the transaction routing gateway receives the order query instruction and then performs preliminary parsing of the order query instruction to obtain transaction attribute information to facilitate subsequent querying of relevant information of the corresponding transaction order.
[0051] S22: Determine the query routing rule that matches the transaction attribute information of the order to be queried based on the routing rules configured for the transaction routing gateway by the routing rule management node.
[0052] Based on the transaction attribute information carried by the order query command, a matching routing rule is determined from the pre-configured routing rules. In practical applications, the target routing rule that matches the transaction attribute information of the order to be queried is similar to the target routing rule. In this step, the transaction attribute information of the order to be queried is used to query a matching routing rule. If a matching routing rule exists, it indicates that the order to be queried has already undergone routing processing according to the routing rule. In other words, the routing rule is the target routing rule matched when the order to be queried was processed.
[0053] S23: Query the transaction processing result of the order to be queried from the transaction order database of the transaction processing node of the routing rule to be queried.
[0054] For transaction orders that undergo routing processing, the processed data is stored in the transaction order database of the actual transaction processing node. In this example, this transaction order database is also referred to as the transaction library. The transaction processing node for the routing rule to be queried is the node that has pre-processed the order to be queried. The transaction processing result of the order to be queried is stored in the transaction library of the transaction processing node. Therefore, a query can be performed in this transaction library to find the transaction processing result of the order to be queried.
[0055] In practice, the transaction attribute information carried in the order query instruction can be used as search terms to perform a query in the transaction database, and the transaction processing results of the order to be queried can be found.
[0056] The solution provided in this application allows for querying the transaction processing results of a transaction order after processing the order itself, via an order query command. Based on the routing rules to be queried, the actual transaction processing node executing the order processing can be determined, thereby identifying the transaction database storing the transaction processing results and efficiently retrieving the transaction processing results of the order to be queried.
[0057] Based on the solutions provided in the above embodiments, optionally, such as Figure 3 As shown, before determining the transaction processing node of the target routing rule as the target transaction processing node matching the pending transaction order, the following steps are also included: S31: Obtain the running status of the transaction processing node of the target routing rule.
[0058] In the solution provided in this application embodiment, the routing rule management node configures routing rules for the transaction routing gateway, and the transaction routing gateway executes the routing according to the pre-configured routing rules. However, in practical applications, a failure of the target transaction processing node may occur, preventing the processing of transaction orders. Typically, the routing rule management node can monitor the operating status of each data center and adjust the routing rules in real time to ensure that transaction orders are routed to normally functioning transaction processing nodes for processing. However, for sudden failures, the routing rule management node needs to detect the failure, generate new routing rules, and configure the new routing rules for the transaction routing gateway; this series of steps consumes a certain amount of time. To reduce the impact on transaction orders, in this embodiment, before executing routing for a transaction order, the transaction routing gateway first obtains the operating status of the transaction processing node of the target routing rule to determine whether the transaction processing node can process the transaction order normally.
[0059] S32: If the transaction processing node of the target routing rule is in normal operation, then the transaction processing node of the target routing rule is determined as the target transaction processing node matching the transaction order to be processed.
[0060] If a transaction processing node is operating normally, it indicates that the transaction processing node can process transaction orders normally. The transaction processing node is then identified as the target transaction processing node, and the transaction order is routed to the normally operating transaction processing node, instructing the transaction processing node to process the transaction order.
[0061] S33: If the transaction processing node of the target routing rule is in an abnormal operating state, then the normally operating transaction processing node is determined as the target transaction processing node matching the pending transaction order.
[0062] If the transaction processing node pointed to by the target routing rule is in an abnormal operating state, the transaction routing gateway can obtain the operating status of other data centers and query whether there are normally operating transaction processing nodes that can be used to process transaction orders. This allows the pending transaction orders to be processed as soon as possible, avoiding significant negative impacts on transactions and improving the flexibility of transaction order processing.
[0063] For example, suppose a pending transaction order flows into the transaction routing gateway in data center A. According to the pre-configured routing rules, this order should be routed to the transaction processing node in data center C for processing. However, the transaction routing gateway in data center A detects a fault or communication line failure in data center C, preventing it from processing the transaction order. In other words, after following the pre-configured routing rules, the pending transaction order cannot be processed. In this case, the transaction routing gateway in data center A can determine an alternative target transaction processing node, such as the transaction processing node in data center B, and then route the pending transaction order to that node, ensuring it is processed correctly.
[0064] Based on the solutions provided in the above embodiments, optionally, such as Figure 4 As shown, if the transaction processing node of the target routing rule is in an abnormal operating state, the method further includes: S41: Generate routing information based on the normally operating transaction processing node and the pending transaction orders.
[0065] If routing is not executed according to the pre-configured target routing rules, pending transaction orders will be routed to a temporarily selected transaction processing node for processing. While this ensures that transaction orders are processed normally, it makes it difficult to query the order processing results afterwards. To address this, the solution provided in this application generates routing information based on the actually operating transaction processing node and the pending transaction order when routing is not executed according to the target routing rules. For example, assuming a pending transaction order flows in from data center A and is routed to a transaction processing node in data center B for processing, the generated routing information could be Key: Order number from data center A, Value: B.
[0066] S42: Store the routing information in the local routing storage of the transaction routing gateway.
[0067] The routing information generated in the above steps is stored in a local route, which is communicatively connected to the transaction routing gateway. In practical applications, if a user wants to query a transaction order, they can send an order query command to the transaction routing gateway to which the order flows. For example, if a user wants to query transaction orders flowing into the transaction routing gateway of data center A, they send an order query command carrying the transaction attribute information of the order to be queried to the transaction routing gateway of data center A. The transaction routing gateway of data center A then queries the transaction processing result from the transaction database of the transaction processing node that actually performs the processing.
[0068] In this solution, because the transaction processing node pointed to by the pre-configured target routing rule is abnormal, it cannot execute transaction order processing normally. Consequently, the node that actually executes the transaction order processing is not the transaction processing node pointed to by the target routing rule. In this step, the actual routing information of the transaction order is stored in the local routing storage of the transaction routing gateway. Thus, after the transaction routing gateway receives an order query instruction for a transaction order, it can find the actual transaction processing node that is executing the processing in the local routing storage, and then query the transaction processing result of the queried order from the transaction order database of the actual transaction processing node.
[0069] The solution provided in this application provides that for transaction orders that are not processed according to pre-configured routing rules, additional routing information is generated and stored in the local routing storage of the transaction routing gateway. This allows users to query the transaction processing results of the order through the transaction routing gateway. This solution effectively improves the flexibility of transaction order processing and stores the actual transaction processing nodes, enabling users to quickly query the transaction processing results.
[0070] Furthermore, since the routing rule management system has the function of configuring routing rules for each transaction routing gateway, once a data center experiences an anomaly, it can obtain the actual data center information where the anomaly occurred, and then generate new routing rules and configure them for each data center to process transaction orders through the normally operating data centers. Therefore, in practical applications, the number of transaction orders that are not processed according to the routing rules is relatively small, requiring only a small storage capacity to store the routing information. This reduces the pressure on the local routing storage of the transaction routing gateways, thereby improving the overall system's flexibility in processing transaction orders, reducing the routing storage load, and enhancing the overall system stability.
[0071] Based on the solutions provided in the above embodiments, optionally, such as Figure 5 As shown, before determining the query routing rule that matches the transaction attribute information of the order to be queried based on the routing rules configured by the routing rule management node for the transaction routing gateway, the process further includes: S51: Query the local routing storage according to the order query instruction.
[0072] After receiving an order query instruction, the transaction routing gateway can first perform preliminary parsing of the order query instruction to obtain the transaction attribute information of the order to be queried carried in the order query instruction. Then, based on the transaction attribute information, it can query the local routing storage to determine whether there is any related routing information.
[0073] S52: If target route information associated with the transaction attribute information exists in the local route storage, then query the transaction attribute information from the transaction order database of the transaction processing node pointed to by the target route information to obtain the query result.
[0074] If the associated target route information can be found in the local route storage, it indicates that the order being queried was not routed according to the pre-configured routing rules, but rather routed and processed according to the transaction processing node pointed to by the route information. Furthermore, the transaction attribute information can be queried from the transaction order database of the transaction processing node pointed to by the route information to obtain the processing result of the transaction order.
[0075] S53: If there is no target route information associated with the transaction attribute information in the local route storage, then the route rule to be queried that matches the transaction attribute information is determined according to the route rule management node configured for the transaction route gateway, and the transaction attribute information is queried from the transaction order database of the transaction processing node of the route rule to be queried to obtain the query result.
[0076] If the associated target route information cannot be found in the local route storage, it indicates that the order to be queried is routed according to the pre-configured route rules. In this case, it is only necessary to query the matching route rule to be queried based on the transaction attribute information, and then determine the transaction processing node to be processed based on the route rule to be queried. Then, query the transaction attribute information in the transaction order database of the transaction processing node to obtain the processing result of the transaction order.
[0077] The solution provided in this application allows the transaction routing gateway to accurately and quickly locate the actual transaction processing node that processes the queried order after receiving an order query instruction. This is achieved by first querying the local routing storage and then the pre-configured routing rules, ultimately retrieving the processing result of the order from the transaction order database of that node. This solution not only accurately retrieves the processing results of transaction orders processed according to the pre-configured routing rules but also accurately retrieves the processing results of transaction orders that were not processed according to the pre-configured routing rules due to faults or other reasons.
[0078] Based on the solutions provided in the above embodiments, optionally, such as Figure 6 As shown, the transaction attribute information of the pending transaction order includes the order transaction time, and the method further includes: S61: Receive a target routing rule update instruction, the target routing rule update instruction including a target transaction time matching condition, a target non-transaction time matching condition, and a target transaction processing node, wherein the target transaction time matching condition is greater than the target time.
[0079] Target routing rule update instructions can be generated by the routing rule management node based on actual conditions, and can be used to coordinate and allocate the processing of transaction orders. For example, if a failure occurs in data center B, a target routing rule can be generated to route transaction orders flowing into data center B to other normal data centers for processing. Alternatively, if data center B needs to undergo expansion or maintenance, thus temporarily suspending transaction order processing, a target routing rule can be generated to route transaction orders flowing into data center B to other normal data centers for processing.
[0080] For example, suppose the existing routing rule routes transactions made after 00:00 on January 1, 2021, to data center C. Now, the routing rule needs to be changed so that transactions after 00:00 on January 1, 2022, are routed to data center B. Then, the target routing rule update instruction would include the following matching conditions: target transaction time matching condition is that the order transaction time is greater than or equal to 00:00 on January 1, 2022; target non-transaction time matching condition is that the transaction time is greater than 00:00 on January 1, 2021; and the target transaction processing node is a transaction processing node in data center B. The target time is 00:00 on January 1, 2022.
[0081] S62: Obtain from the rule base the first routing rule whose non-trading time matching condition is the target non-trading time matching condition and has no end-of-trading time.
[0082] The rule base is a database used by the transaction routing gateway to store routing rules. It stores the routing rules for the current application and can also store routing rules applied in historical periods.
[0083] In this step, the first routing rule that matches the target non-trading time matching condition and has no trading time is retrieved from the rule base. For example, the target non-trading time matching condition is that the trading time is later than 00:00 on January 1, 2021. The first routing rule that meets this target non-trading time matching condition is retrieved from the rule base. There can be multiple first routing rules.
[0084] S63: Change the end transaction time of the first routing rule to the target time.
[0085] The end time of the first routing rule, which previously had no end time, has been changed to the target time, namely 00:00 on January 1, 2022. In other words, the first routing rule has been changed to require the transaction time to be greater than 00:00 on January 1, 2021, and less than 00:00 on January 1, 2022.
[0086] S64: Add a second routing rule, which routes transaction orders that meet the target transaction time matching condition and the target non-transaction time matching condition to the target transaction processing node.
[0087] In this step, a second routing rule is added to route transaction orders that meet the criteria of a transaction time greater than or equal to 00:00 on January 1, 2022, or a transaction time greater than 00:00 on January 1, 2021, to the transaction processing node in data center B.
[0088] The solution provided in this application can modify the transaction time matching conditions in the routing rules. If the first routing rule also includes other types of transaction attribute information such as merchant information and order amount, the modified routing rule will still retain the original transaction attribute information. Furthermore, the generated second routing rule can contain other types of transaction attribute information besides transaction time that were included in the first routing rule itself. For example, if the first routing rule includes merchant X, then the generated second routing rule will also include merchant X.
[0089] The solution provided in this application can effectively modify the original routing rules and generate a second routing rule based on the transaction time to connect with the modified first rule. On the one hand, it can ensure that incoming transaction orders can be routed normally; on the other hand, it can ensure that transactions before the routing rule change can be queried normally, and that routing can be performed according to the new routing rules after the target time.
[0090] The solution provided in this application enables routing processing of transaction orders according to pre-configured routing rules. Since the routing rules are pre-configured by the routing rule management node, effective management of transaction order routing can be achieved through this node. This facilitates data retrieval of transaction orders, reduces reliance on local routing storage in the data center, eliminates single points of failure, and effectively reduces the risk of transaction order processing failures. In practical applications, it effectively improves overall system stability, eliminates the need for frequent expansion, and ensures that regular expansion and maintenance do not affect the system's transaction order processing capabilities.
[0091] In order to solve the problems existing in the prior art, such as Figure 7 As shown in the figure, this application embodiment also provides a transaction routing gateway 70, including: The first determining module 71 determines the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; Receiving module 72 receives pending transaction orders, which carry transaction attribute information; The second determining module 73, if there is a target routing rule in the routing rules that matches the transaction attribute information of the transaction order to be processed, then determines the transaction processing node of the target routing rule as the target transaction processing node that matches the transaction order to be processed; The processing module 74 routes the transaction order to the target transaction processing node, so as to instruct the target transaction processing node to process the transaction order to be processed.
[0092] The transaction routing gateway provided in this application determines the routing rules configured by the routing rule management node. These routing rules include transaction processing nodes that match the transaction attribute information of a transaction order. The gateway receives a transaction order to be processed, which carries transaction attribute information. If a target routing rule exists that matches the transaction attribute information of the transaction order, the transaction processing node of that target routing rule is determined as the target transaction processing node matching the transaction order. The transaction order is then routed to the target transaction processing node, instructing it to process the order. This enables routing processing of transaction orders according to pre-configured routing rules. Since the routing rules are pre-configured by the routing rule management node, effective management of transaction order routing can be achieved through this node. This facilitates data querying of transaction orders, reduces reliance on local routing storage in the data center, and effectively reduces the risk of transaction order processing failures.
[0093] In this application, the modules in the apparatus provided can also implement the method steps provided in the method embodiments. Alternatively, the apparatus provided in this application may include other modules besides those described above to implement the method steps provided in the method embodiments. Furthermore, the apparatus provided in this application can achieve the technical effects achievable by the method embodiments.
[0094] Preferably, this application embodiment also provides an electronic device, including a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, it implements the various processes of the above-described method embodiment for processing transaction orders and achieves the same technical effect. To avoid repetition, it will not be described again here.
[0095] This application also provides a computer-readable storage medium storing a computer program. When executed by a processor, this computer program implements the various processes of the above-described method embodiments for processing transaction orders and achieves the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc.
[0096] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0097] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more blocks of the flowchart illustrations and / or one or more blocks of the block diagrams.
[0098] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0099] These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable apparatus, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0100] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0101] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0102] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0103] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0104] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0105] The above description is merely an embodiment of this application and is not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method for processing transaction orders, characterized in that, Applied to transaction routing gateways, including: Determine the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; Receive pending transaction orders, which carry transaction attribute information; If there is a target routing rule in the routing rules that matches the transaction attribute information of the transaction order to be processed, then the transaction processing node of the target routing rule is determined as the target transaction processing node that matches the transaction order to be processed. The transaction order is routed to the target transaction processing node to instruct the target transaction processing node to process the transaction order to be processed.
2. The method as described in claim 1, characterized in that, Also includes: Receive an order query instruction, wherein the order query instruction carries the transaction attribute information of the order to be queried; The routing rule to be queried is determined based on the routing rule configured for the transaction routing gateway by the routing rule management node, which matches the transaction attribute information of the order to be queried. Query the transaction processing result of the order to be queried from the transaction order database of the transaction processing node of the routing rule to be queried.
3. The method as described in claim 2, characterized in that, Before determining the transaction processing node of the target routing rule as the target transaction processing node matching the pending transaction order, the method further includes: Obtain the running status of the transaction processing node of the target routing rule; If the transaction processing node of the target routing rule is in normal operation, then the transaction processing node of the target routing rule is determined as the target transaction processing node matching the transaction order to be processed; If the transaction processing node of the target routing rule is in an abnormal operating state, then the normally operating transaction processing node will be determined as the target transaction processing node matching the pending transaction order.
4. The method as described in claim 3, characterized in that, If the transaction processing node of the target routing rule is in an abnormal operating state, the method further includes: Routing information is generated based on the normally operating transaction processing node and the pending transaction orders; The routing information is stored in the local routing storage of the transaction routing gateway.
5. The method as described in claim 4, characterized in that, Before determining the query routing rule that matches the transaction attribute information of the order to be queried based on the routing rules configured for the transaction routing gateway by the routing rule management node, the process also includes: Query the local routing storage according to the order query instruction; If the local routing storage contains target routing information associated with the transaction attribute information of the order to be queried, then the transaction attribute information is queried from the transaction order database of the transaction processing node pointed to by the target routing information to obtain the query result; If no target route information associated with the transaction attribute information exists in the local route storage, then a query route rule matching the transaction attribute information is determined according to the route rule management node's configuration of the transaction route gateway, and the transaction attribute information is queried from the transaction order database of the transaction processing node of the query route rule to obtain the query result.
6. The method according to any one of claims 1 to 5, characterized in that, The transaction attribute information of the transaction order includes transaction time information and / or transaction user information.
7. The method as described in claim 6, characterized in that, The transaction attribute information of the pending transaction order includes the order transaction time, and the method further includes: Receive a target routing rule update instruction, the target routing rule update instruction includes a target transaction time matching condition, a target non-transaction time matching condition, and a target transaction processing node, wherein the target transaction time matching condition is greater than the target time; Obtain a first routing rule from the rule base that matches the target non-trading time condition and has no end-of-trading time. Change the end transaction time of the first routing rule to the target time; Add a second routing rule, which routes transaction orders that meet the target transaction time matching condition and the target non-transaction time matching condition to the target transaction processing node.
8. A transaction routing gateway, characterized in that, include: The first determining module determines the routing rules configured by the routing rule management node for the transaction routing gateway, wherein the routing rules include transaction processing nodes that match the transaction attribute information of the transaction order; The receiving module receives pending transaction orders, which carry transaction attribute information. The second determining module determines the transaction processing node of the target routing rule as the target transaction processing node matching the transaction attribute information of the pending transaction order if there is a target routing rule in the routing rules that matches the transaction attribute information of the pending transaction order. The processing module routes the transaction order to the target transaction processing node, instructing the target transaction processing node to process the transaction order to be processed.
9. An electronic device, characterized in that, include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the method as described in any one of claims 1 to 7.