CN111857888A - Transaction processing method and device - Google Patents

Transaction processing method and device Download PDF

Info

Publication number
CN111857888A
CN111857888A CN202010664289.2A CN202010664289A CN111857888A CN 111857888 A CN111857888 A CN 111857888A CN 202010664289 A CN202010664289 A CN 202010664289A CN 111857888 A CN111857888 A CN 111857888A
Authority
CN
China
Prior art keywords
transaction
request
type
determining
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010664289.2A
Other languages
Chinese (zh)
Other versions
CN111857888B (en
Inventor
徐冬冬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Construction Bank Corp
Original Assignee
China Construction Bank Corp
CCB Finetech Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Construction Bank Corp, CCB Finetech Co Ltd filed Critical China Construction Bank Corp
Priority to CN202010664289.2A priority Critical patent/CN111857888B/en
Publication of CN111857888A publication Critical patent/CN111857888A/en
Application granted granted Critical
Publication of CN111857888B publication Critical patent/CN111857888B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/448Execution paradigms, e.g. implementations of programming paradigms
    • G06F9/4488Object-oriented
    • G06F9/449Object-oriented method invocation or resolution
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/903Querying
    • G06F16/90335Query processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/76Adapting program code to run in a different environment; Porting

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a transaction processing method and device, and relates to the technical field of computers. One embodiment of the method comprises: obtaining a transaction request, the transaction request including at least one characteristic field; determining a transaction type corresponding to the transaction request according to the at least one characteristic field; determining a target transaction execution component from different types of transaction execution components according to the transaction types; sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request. The embodiment realizes receiving and processing of transactions of different transaction types through the unified interface, reduces the development difficulty, avoids redundant development work and improves the development efficiency.

Description

Transaction processing method and device
Technical Field
The invention relates to the technical field of computers, in particular to a transaction processing method and device.
Background
In financial transactions, a variety of transaction types are typically involved, such as transfers, collections, loans, and the like. In the prior art, different transaction types need to correspond to different transaction interfaces, that is, different transaction interfaces are used to receive transaction requests corresponding to different transaction types respectively.
In the process of implementing the invention, the inventor finds that at least the following problems exist in the prior art:
different transaction types are respectively provided with different transaction interfaces, developers of the transaction interfaces need to pay attention to specific transaction scenes, development difficulty is increased, and redundant development work is easy to occur.
Disclosure of Invention
In view of this, embodiments of the present invention provide a transaction processing method and apparatus, which implement providing a uniform interface for different types of transactions, and after obtaining a transaction request through the uniform interface, call different transaction execution assemblies according to different transaction types to execute different types of transactions, thereby implementing receiving and processing transactions of different transaction types through the uniform interface, so that developers of the transaction interface do not need to pay attention to a specific transaction scenario, reducing development difficulty, avoiding redundant development work, and improving development efficiency.
To achieve the above object, according to an aspect of an embodiment of the present invention, there is provided a transaction processing method.
The transaction processing method of the embodiment of the invention comprises the following steps: obtaining a transaction request, the transaction request including at least one characteristic field;
Determining a transaction type corresponding to the transaction request according to the at least one characteristic field;
determining a target transaction execution component from different types of transaction execution components according to the transaction types;
sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
Optionally, the determining, according to the at least one characteristic field, a transaction type corresponding to the transaction request includes:
determining a field value of the characteristic field;
when the field value is matched with any transaction type in a type corresponding table, determining the transaction type matched with the field value as the transaction type corresponding to the transaction request; wherein the type correspondence table includes field values corresponding to a plurality of transaction types, respectively.
Optionally, when a transaction type matching the field value does not exist in the type correspondence table, the determining, according to the at least one characteristic field, the transaction type corresponding to the transaction request includes:
determining a payee account and a payer account corresponding to the transaction request according to the characteristic field;
And determining the transaction type corresponding to the transaction request according to the types of the payee account and the payer account.
Optionally, the sending the transaction request to the target transaction execution component to cause the target transaction to execute the transaction requested by the transaction request includes:
and generating a transaction task corresponding to the transaction request, and storing the transaction task into a cache queue corresponding to the target transaction execution component, so that the target transaction execution component extracts and executes the transaction task from the cache queue to execute the transaction requested by the transaction request.
Optionally, the method further comprises:
and determining whether the transaction tasks in the cache queue are successfully executed or not by adopting a polling mechanism, deleting the successfully executed transaction tasks from the cache queue, and storing the transaction tasks which are not successfully executed into the cache queue again.
Optionally, the method further comprises:
sending the transaction request and the transaction type to the target transaction execution component so that the target transaction execution component invokes a transaction processing procedure corresponding to the transaction type to execute the transaction requested by the transaction request.
Optionally, after executing the transaction requested by the transaction request, further comprising:
correspondingly recording the serial number corresponding to the transaction request and transaction information;
and carrying out statistical analysis according to the recorded transaction information.
To achieve the above object, according to still another aspect of an embodiment of the present invention, a transaction processing apparatus is provided.
The transaction processing device of the embodiment of the invention comprises: the system comprises a request acquisition module, a type determination module and a transaction execution module; wherein the content of the first and second substances,
the request acquisition module is used for acquiring a transaction request, and the transaction request comprises at least one characteristic field;
the type determining module is used for determining the transaction type corresponding to the transaction request according to the at least one characteristic field;
the transaction execution module is used for determining a target transaction execution component from different types of transaction execution components according to the transaction types; sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
To achieve the above object, according to still another aspect of an embodiment of the present invention, there is provided an electronic device for processing a transaction.
An electronic device for processing a transaction according to an embodiment of the present invention includes: one or more processors; a storage device for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to implement a transaction processing method of an embodiment of the present invention.
To achieve the above object, according to still another aspect of embodiments of the present invention, there is provided a computer-readable storage medium.
A computer-readable storage medium of an embodiment of the present invention has stored thereon a computer program that, when executed by a processor, implements a transaction processing method of an embodiment of the present invention.
One embodiment of the above invention has the following advantages or benefits: the method comprises the steps of obtaining a transaction request through a uniform interface, determining a transaction type corresponding to the transaction request according to a characteristic field in the transaction request, and utilizing a target transaction execution component corresponding to the transaction type to execute a requested transaction. Therefore, the transaction of different transaction types is received and processed through the uniform interface, developers of the transaction interface do not need to pay attention to specific transaction scenes, the development difficulty is reduced, redundant development work is avoided, and the development efficiency is improved.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram of the main steps of a transaction processing method according to an embodiment of the invention;
FIG. 2 is a logic diagram of determining transaction types in a transaction processing method according to an embodiment of the invention;
FIG. 3 is a schematic diagram of a connection between a transaction processing device and a transaction execution component according to an embodiment of the invention;
FIG. 4 is a schematic diagram of the major modules of a transaction processing device according to an embodiment of the present invention;
FIG. 5 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 6 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
It should be noted that the embodiments of the present invention and the technical features of the embodiments may be combined with each other without conflict.
Fig. 1 is a schematic diagram of the main steps of a transaction processing method according to an embodiment of the present invention.
As shown in fig. 1, a transaction processing method according to an embodiment of the present invention mainly includes the following steps:
step S101: a transaction request is obtained, the transaction request including at least one characteristic field.
The transaction request may be a request for different financial services, that is, the transaction corresponding to the transaction request may be various types of transactions such as payment settlement, transfer, collection, loan and receipt. The characteristic field included in the transaction request may be a field that is pre-agreed by the request input terminal and the transaction processing device provided by the embodiment of the present invention.
Step S102: and determining the transaction type corresponding to the transaction request according to the at least one characteristic field.
After the transaction processing device provided by the embodiment of the invention acquires the transaction request through the uniform interface, the characteristic field is analyzed from the transaction request, and then the field value of the characteristic field can be determined; when the field value is matched with any transaction type in a type corresponding table, determining the transaction type matched with the field value as the transaction type corresponding to the transaction request; wherein the type correspondence table includes field values corresponding to a plurality of transaction types, respectively.
For example, the characteristic field may be a pre-agreed transfer channel code, which is carried in the transaction request. In an embodiment of the present invention, the transfer channel code may be "tfrChnlCd," and after the transfer channel code is parsed from the transaction request, a field value corresponding to the transfer channel code is determined. Then, the transaction type corresponding to the field value is determined by utilizing a pre-configured type corresponding table. Wherein, the type correspondence table can be recorded in the form shown in the following table 1:
TABLE 1
Figure BDA0002579778820000061
According to the transaction type and the field value recorded in table 1, the transaction type corresponding to the transaction request can be determined. For example, when tfrchlcd is cecupop, it indicates that the transaction type corresponding to the transaction request is cross-generation, and then the transaction processing apparatus provided in the embodiment of the present invention may call the target transaction execution component corresponding to the cross-generation to execute the transaction requested by the transaction request. For another example, when tfrchlcd is cesccrd, it indicates that the transaction type corresponding to the transaction request is that the business card executes a payment transaction, and then the transaction processing apparatus provided in the embodiment of the present invention may call the target transaction execution component corresponding to the business card executing the payment transaction to execute the transaction requested by the transaction request. In addition, when tfrchlcd is JLWJ, it is described that the transaction type corresponding to the transaction request is single-transaction collection, and then the transaction processing apparatus according to the embodiment of the present invention may invoke the target transaction execution component corresponding to the single-transaction collection to execute the transaction requested by the transaction request. Finally, when tfrchlcd is equal to ECTIP, it is described that the transaction type corresponding to the transaction request is branch transaction, and then the transaction processing apparatus provided in the embodiment of the present invention may invoke the target transaction execution component corresponding to the branch transaction to execute the transaction requested by the transaction request.
In addition, when the transaction type matched with the field value does not exist in the type corresponding table, determining a payee account and a payer account corresponding to the transaction request according to the characteristic field; and determining the transaction type corresponding to the transaction request according to the types of the payee account and the payer account.
For example, the payee account and the payer account may be various types such as a settlement card, a public account, a private account, a main account and a sub-account. When the transaction type cannot be directly determined from the characteristic field of the transaction request, the transaction type corresponding to the transaction request can be determined according to the types of the payee account and the payer account represented by the characteristic field.
For example, if the payer account and the payee account are both one-user-accessible accounts and the corresponding one-user-accessible main account is the same, the transaction type corresponding to the transaction request is determined to be one-user-accessible transfer. And when the account of the payer is an internal loan-to-public account and the account of the payee is an internal loan account, the transaction type corresponding to the transaction request is a loan-to-public account. For another example, when the payer account is the current bank account and the payee account is the other bank account, the transaction type may be determined to be a cross-bank payment transaction. When the payee account is the current bank account and the payer account is the other bank account, the transaction type can be determined to be a cross-bank payment transaction. When the payee account or the payer account is a foreign exchange account, the transaction type is a foreign exchange transaction. When one of the payer account and the payee account is a settlement card, the other account needs to be of the type of the settlement card, an internal account, a card account or a current account, and if the account type of the other account does not meet the requirement, the transaction is difficult to realize, and the transaction exception is prompted at this moment. And if the account type of the other party account meets the requirement, determining that the transaction type corresponding to the transaction request is a public settlement card.
A simple logical schematic diagram of determining the transaction type based on the types of payer account and payee account may be found in fig. 2. As shown in fig. 2, if the payer account and the payee account are in-line accounts, the transaction type is in-line transfer, if the payer account and the payee account are in different lines, that is, if the payer account and the payee account are in cross-line accounts, the transaction type is cross-line transfer, and if the payer account or the payee account is a foreign exchange account, the transaction type is a foreign exchange transaction.
In one embodiment of the invention, determining the transaction type based on the field value and determining the transaction type based on the payee account and the payer account may be accomplished by a rules processing engine that may employ if-else logic, i.e., determining whether the transaction type may be determined based on the field value, and if not, determining the transaction type based on the payee account and the payer account.
It will be appreciated that the fields of the characteristics characterizing the payee account, payer account and transaction type vary. In addition, uniform features may be employed to represent transaction features of the same meaning or purpose, for example, uniform feature fields may be employed to characterize the transfer channel code "tfrChnlCd", uniform feature fields may be employed to represent payee accounts of the same type, uniform feature fields may be employed to represent payer accounts of the same type, and so on. For fields with personalized differences during the transaction, such as transaction amount and transaction time, value is assigned during the transaction, thereby reducing code redundancy.
Step S103: and determining a target transaction execution component from different types of transaction execution components according to the transaction types.
Step S104: sending the transaction request to the target transaction execution component to cause the target transaction to execute the transaction requested by the transaction request.
Fig. 3 shows a schematic connection between a transaction processing apparatus and a plurality of transaction execution components according to an embodiment of the present invention. In fig. 3, payment settlement, loan deposit, receipt payment, foreign exchange, and charge metering are the different transaction execution components, respectively. After the transaction processing device determines the transaction type corresponding to the transaction request, the transaction request can be sent to the corresponding target transaction execution component. The transaction processing device can adopt a uniform packaging mode and provide a uniform interface for the outside so as to receive different transaction requests. And routing the transaction requests corresponding to different transaction types to the corresponding transaction execution components according to the corresponding rules of the characteristic fields, the transaction types and the transaction execution components, namely, providing different transaction paths according to different transaction types in the transaction execution components to realize different types of transactions. Therefore, developers only need to complete the butt joint of the corresponding transaction execution component and the transaction processing device provided by the embodiment of the invention according to the transaction type, and do not need to pay attention to a specific transaction scene; when the transaction execution component is changed or modified, analysis and targeted modification are facilitated, such as modification of corresponding connection parameters, and development difficulty is reduced.
In one embodiment of the invention, the same transaction execution component may implement multiple transaction processes, with different transaction processes corresponding to different transaction types. Therefore, after the transaction type corresponding to the transaction request is determined, the transaction request and the transaction type can be sent to the target transaction execution component, so that the target transaction execution component invokes a transaction processing procedure corresponding to the transaction type to execute the transaction requested by the transaction request.
That is to say, after determining the transaction types corresponding to the multiple transaction requests respectively, if the multiple transaction types correspond to the same transaction executing component, the transaction processing apparatus provided in the embodiment of the present invention may send the transaction requests corresponding to the multiple transaction types to the same transaction executing component, and send the transaction types corresponding to the multiple requests respectively to the transaction executing component, so that the transaction executing component invokes the transaction processing processes corresponding to the transaction types respectively to implement multiple transactions corresponding to the transaction requests. Therefore, the transaction type is sent to the corresponding target transaction execution component, so that the target transaction execution component can conveniently call the transaction processing process according to the transaction type, the transaction is conveniently realized, and the efficiency of transaction execution is improved.
When the transaction processing device forwards the transaction request to the target transaction execution component, information such as a payer account number, a payer account number name, a payer bank number, a payer bank name, a payee account number name, a payee bank number, a payee bank name, a transaction amount, a transfer route and/or a transaction remark can be assigned to the transaction request message, so that the target transaction execution component can call a corresponding transaction processing process according to the assigned transaction request message.
In addition, in order to ensure smooth execution of the transaction and facilitate transaction reconciliation processing (such as transaction result query and confirmation), in an embodiment of the present invention, after a transaction request is received, a transaction task corresponding to the transaction request is generated and stored in a cache queue corresponding to the target transaction execution component, so that the target transaction execution component extracts and executes the transaction task from the cache queue to execute the transaction requested by the transaction request.
In order to facilitate recording transaction information, complete transaction reconciliation processing (such as transaction result query confirmation) and avoid repeated execution of transactions, in an embodiment of the present invention, a polling mechanism is adopted to determine whether the transaction tasks in the cache queue are successfully executed, delete the successfully executed transaction tasks from the cache queue, and store the transaction tasks which are not successfully executed into the cache queue again.
When some transactions are difficult to complete immediately, there may be a case that the transaction tasks in the cache queue are extracted but not successfully executed, for example, in the process of the foreign exchange transaction, the foreign exchange transaction may be difficult to complete immediately due to transaction time difference or other reasons, and after the corresponding transaction tasks are extracted, the transaction tasks need to be placed in the cache queue again because the transaction is not completed. Therefore, by the polling mechanism, each transaction task can be executed, namely account checking processing of the transaction is completed, and after the tasks are successfully executed, the corresponding transaction tasks are deleted from the cache queue, so that repeated execution of the transaction tasks is avoided, transaction errors are avoided, and transaction execution efficiency is improved.
In addition, after the transaction is successfully executed, the serial number corresponding to the transaction request and the transaction information can be correspondingly recorded; and carrying out statistical analysis according to the recorded transaction information.
For example, when a transaction request is received, a corresponding transaction serial number is generated, the transaction serial numbers corresponding to the transaction requests are stored in the same record table, and after the transaction is completed, transaction information corresponding to the transactions is correspondingly stored in the record table, so that the data such as the transaction quantity, the total transaction amount and the transaction peak in a certain period (such as every day or every week) can be uniformly subjected to statistical analysis, and uniform account checking processing is realized. Therefore, the transaction serial number and the transaction information can be correspondingly recorded, so that a uniform transaction serial record is provided, and uniform account checking processing is facilitated, such as transaction result inquiry confirmation, remittance and the like.
According to the transaction processing method, the transaction request is obtained through the uniform interface, the transaction type corresponding to the transaction request is determined according to the characteristic field in the transaction request, and then the requested transaction is performed by using the target transaction execution component corresponding to the transaction type. Therefore, the transaction of different transaction types is received and processed through the uniform interface, developers of the transaction interface do not need to pay attention to specific transaction scenes, the development difficulty is reduced, redundant development work is avoided, and the development efficiency is improved.
Fig. 4 is a schematic diagram of the main modules of a transaction processing device according to an embodiment of the present invention.
As shown in fig. 4, a transaction processing apparatus 400 according to an embodiment of the present invention includes: a request acquisition module 401, a type determination module 402 and a transaction execution module 403; wherein the content of the first and second substances,
the request obtaining module 401 is configured to obtain a transaction request, where the transaction request includes at least one characteristic field;
the type determining module 402 is configured to determine, according to the at least one characteristic field, a transaction type corresponding to the transaction request;
the transaction execution module 403 is configured to determine a target transaction execution component from different types of transaction execution components according to the transaction type; sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
In an embodiment of the present invention, the type determining module 402 is configured to determine a field value of the feature field; when the field value is matched with any transaction type in a type corresponding table, determining the transaction type matched with the field value as the transaction type corresponding to the transaction request; wherein the type correspondence table includes field values corresponding to a plurality of transaction types, respectively.
In an embodiment of the present invention, the type determining module 402 is configured to determine, according to the characteristic field, a payee account and a payer account corresponding to the transaction request when the transaction type matching with the field value does not exist in the type correspondence table; and determining the transaction type corresponding to the transaction request according to the types of the payee account and the payer account.
In an embodiment of the present invention, the transaction executing module 403 is configured to generate a transaction task corresponding to the transaction request, store the transaction task into a cache queue corresponding to the target transaction executing component, so that the target transaction executing component extracts and executes the transaction task from the cache queue to execute the transaction requested by the transaction request.
In an embodiment of the present invention, the transaction executing module 403 is configured to determine whether the transaction tasks in the cache queue are executed successfully by using a polling mechanism, delete the transaction tasks that are executed successfully from the cache queue, and store the transaction tasks that are not executed successfully into the cache queue again.
In an embodiment of the present invention, the transaction executing module 403 is configured to send the transaction request and the transaction type to the target transaction executing component, so that the target transaction executing component invokes a transaction processing procedure corresponding to the transaction type to execute the transaction requested by the transaction request.
In an embodiment of the present invention, the transaction executing module 403 is further configured to correspondingly record a serial number corresponding to the transaction request and transaction information; and carrying out statistical analysis according to the recorded transaction information.
According to the transaction processing device provided by the embodiment of the invention, the transaction request is acquired through the unified interface, the transaction type corresponding to the transaction request is determined according to the characteristic field in the transaction request, and then the requested transaction is performed by using the target transaction execution component corresponding to the transaction type. Therefore, the transaction of different transaction types is received and processed through the uniform interface, developers of the transaction interface do not need to pay attention to specific transaction scenes, the development difficulty is reduced, redundant development work is avoided, and the development efficiency is improved.
Fig. 5 illustrates an exemplary system architecture 500 of a transaction processing method or a transaction processing device to which embodiments of the invention may be applied.
As shown in fig. 5, the system architecture 500 may include terminal devices 501, 502, 503, a network 504, and a server 505. The network 504 serves to provide a medium for communication links between the terminal devices 501, 502, 503 and the server 505. Network 504 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 501, 502, 503 to interact with a server 505 over a network 504 to receive or send messages or the like. The terminal devices 501, 502, 503 may have various communication client applications installed thereon, such as a shopping application, a web browser application, a search application, an instant messaging tool, a mailbox client, social platform software, and the like.
The terminal devices 501, 502, 503 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 505 may be a server that provides various services, such as a background management server that supports shopping websites browsed by users using the terminal devices 501, 502, 503. The background management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (e.g., target push information and product information) to the terminal device.
It should be noted that, a transaction processing method provided by the embodiment of the present invention is generally executed by the server 505, and accordingly, a transaction processing apparatus is generally disposed in the server 505.
It should be understood that the number of terminal devices, networks, and servers in fig. 5 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 6, a block diagram of a computer system 600 suitable for use with a terminal device implementing an embodiment of the invention is shown. The terminal device shown in fig. 6 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 6, the computer system 600 includes a Central Processing Unit (CPU)601 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)602 or a program loaded from a storage section 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data necessary for the operation of the system 600 are also stored. The CPU 601, ROM 602, and RAM 603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
The following components are connected to the I/O interface 605: an input portion 606 including a keyboard, a mouse, and the like; an output portion 607 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 608 including a hard disk and the like; and a communication section 609 including a network interface card such as a LAN card, a modem, or the like. The communication section 609 performs communication processing via a network such as the internet. The driver 610 is also connected to the I/O interface 605 as needed. A removable medium 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 610 as necessary, so that a computer program read out therefrom is mounted in the storage section 608 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 609, and/or installed from the removable medium 611. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 601.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a request acquisition module, a type determination module, and a transaction execution module. The names of these modules do not in some cases constitute a limitation on the module itself, for example, the request acquisition module may also be described as a "module for acquiring a transaction request".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise: obtaining a transaction request, the transaction request including at least one characteristic field; determining a transaction type corresponding to the transaction request according to the at least one characteristic field; determining a target transaction execution component from different types of transaction execution components according to the transaction types; sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
According to the technical scheme of the embodiment of the invention, the transaction request is obtained through the uniform interface, the transaction type corresponding to the transaction request is determined according to the characteristic field in the transaction request, and then the requested transaction is carried out by utilizing the target transaction execution component corresponding to the transaction type. Therefore, the transaction of different transaction types is received and processed through the uniform interface, developers of the transaction interface do not need to pay attention to specific transaction scenes, the development difficulty is reduced, redundant development work is avoided, and the development efficiency is improved.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A transaction processing method, comprising:
obtaining a transaction request, the transaction request including at least one characteristic field;
determining a transaction type corresponding to the transaction request according to the at least one characteristic field;
determining a target transaction execution component from different types of transaction execution components according to the transaction types;
sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
2. The method of claim 1, wherein determining the transaction type corresponding to the transaction request according to the at least one characteristic field comprises:
determining a field value of the characteristic field;
when the field value is matched with any transaction type in a type corresponding table, determining the transaction type matched with the field value as the transaction type corresponding to the transaction request; wherein the type correspondence table includes field values corresponding to a plurality of transaction types, respectively.
3. The method according to claim 2, wherein when there is no transaction type matching the field value in the type correspondence table, the determining the transaction type corresponding to the transaction request according to the at least one characteristic field comprises:
determining a payee account and a payer account corresponding to the transaction request according to the characteristic field;
and determining the transaction type corresponding to the transaction request according to the types of the payee account and the payer account.
4. The method of claim 1, wherein sending the transaction request to the target transaction execution component to cause the target transaction to execute the transaction requested by the transaction request comprises:
and generating a transaction task corresponding to the transaction request, and storing the transaction task into a cache queue corresponding to the target transaction execution component, so that the target transaction execution component extracts and executes the transaction task from the cache queue to execute the transaction requested by the transaction request.
5. The method of claim 4, further comprising:
and determining whether the transaction tasks in the cache queue are successfully executed or not by adopting a polling mechanism, deleting the successfully executed transaction tasks from the cache queue, and storing the transaction tasks which are not successfully executed into the cache queue again.
6. The method of claim 1, further comprising:
sending the transaction request and the transaction type to the target transaction execution component so that the target transaction execution component invokes a transaction processing procedure corresponding to the transaction type to execute the transaction requested by the transaction request.
7. The method of claim 1, after performing the transaction requested by the transaction request, further comprising:
correspondingly recording the serial number corresponding to the transaction request and transaction information;
and carrying out statistical analysis according to the recorded transaction information.
8. A transaction processing device, comprising: the system comprises a request acquisition module, a type determination module and a transaction execution module; wherein the content of the first and second substances,
the request acquisition module is used for acquiring a transaction request, and the transaction request comprises at least one characteristic field;
the type determining module is used for determining the transaction type corresponding to the transaction request according to the at least one characteristic field;
the transaction execution module is used for determining a target transaction execution component from different types of transaction execution components according to the transaction types; sending the transaction request to the target transaction execution component to cause the target transaction execution component to execute the transaction requested by the transaction request.
9. An electronic device for processing a transaction, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-7.
10. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-7.
CN202010664289.2A 2020-07-10 2020-07-10 Transaction processing method and device Active CN111857888B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010664289.2A CN111857888B (en) 2020-07-10 2020-07-10 Transaction processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010664289.2A CN111857888B (en) 2020-07-10 2020-07-10 Transaction processing method and device

Publications (2)

Publication Number Publication Date
CN111857888A true CN111857888A (en) 2020-10-30
CN111857888B CN111857888B (en) 2023-11-07

Family

ID=72983000

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010664289.2A Active CN111857888B (en) 2020-07-10 2020-07-10 Transaction processing method and device

Country Status (1)

Country Link
CN (1) CN111857888B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184422A (en) * 2020-09-28 2021-01-05 金蝶软件(中国)有限公司 Transaction method and related equipment
CN113159957A (en) * 2021-05-17 2021-07-23 深圳前海微众银行股份有限公司 Transaction processing method and device
CN113657817A (en) * 2021-10-19 2021-11-16 中电金信软件有限公司 Transaction processing method and device, electronic equipment and readable storage medium
CN113763141A (en) * 2021-02-10 2021-12-07 北京沃东天骏信息技术有限公司 Settlement method, settlement device, electronic equipment and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104616193A (en) * 2015-02-05 2015-05-13 中国农业银行股份有限公司 Accounting information processing method, device and system
CN105205717A (en) * 2015-11-10 2015-12-30 中国建设银行股份有限公司 Bank system transaction information management method, system and general account transfer system
CN106775985A (en) * 2016-12-26 2017-05-31 中国建设银行股份有限公司 A kind of batch processing task dispatching method and device
CN109726018A (en) * 2018-02-07 2019-05-07 中国平安财产保险股份有限公司 Method for processing business, device, equipment and computer readable storage medium
CN110264358A (en) * 2019-06-13 2019-09-20 深圳前海微众银行股份有限公司 A kind of transaction processing method and device
CN110415118A (en) * 2019-07-29 2019-11-05 中国工商银行股份有限公司 Processing method and its device, electronic equipment and medium
CN110442608A (en) * 2019-07-31 2019-11-12 中国工商银行股份有限公司 Information processing method, device, electronic equipment, medium and system
CN110706093A (en) * 2019-09-25 2020-01-17 中国建设银行股份有限公司 Accounting processing method and device
CN110941488A (en) * 2019-12-11 2020-03-31 中国建设银行股份有限公司 Task processing method, device, equipment and storage medium
CN111179081A (en) * 2019-12-24 2020-05-19 中国建设银行股份有限公司 Message processing method and processing device

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104616193A (en) * 2015-02-05 2015-05-13 中国农业银行股份有限公司 Accounting information processing method, device and system
CN105205717A (en) * 2015-11-10 2015-12-30 中国建设银行股份有限公司 Bank system transaction information management method, system and general account transfer system
CN106775985A (en) * 2016-12-26 2017-05-31 中国建设银行股份有限公司 A kind of batch processing task dispatching method and device
CN109726018A (en) * 2018-02-07 2019-05-07 中国平安财产保险股份有限公司 Method for processing business, device, equipment and computer readable storage medium
CN110264358A (en) * 2019-06-13 2019-09-20 深圳前海微众银行股份有限公司 A kind of transaction processing method and device
CN110415118A (en) * 2019-07-29 2019-11-05 中国工商银行股份有限公司 Processing method and its device, electronic equipment and medium
CN110442608A (en) * 2019-07-31 2019-11-12 中国工商银行股份有限公司 Information processing method, device, electronic equipment, medium and system
CN110706093A (en) * 2019-09-25 2020-01-17 中国建设银行股份有限公司 Accounting processing method and device
CN110941488A (en) * 2019-12-11 2020-03-31 中国建设银行股份有限公司 Task processing method, device, equipment and storage medium
CN111179081A (en) * 2019-12-24 2020-05-19 中国建设银行股份有限公司 Message processing method and processing device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112184422A (en) * 2020-09-28 2021-01-05 金蝶软件(中国)有限公司 Transaction method and related equipment
CN113763141A (en) * 2021-02-10 2021-12-07 北京沃东天骏信息技术有限公司 Settlement method, settlement device, electronic equipment and storage medium
CN113159957A (en) * 2021-05-17 2021-07-23 深圳前海微众银行股份有限公司 Transaction processing method and device
CN113657817A (en) * 2021-10-19 2021-11-16 中电金信软件有限公司 Transaction processing method and device, electronic equipment and readable storage medium
CN113657817B (en) * 2021-10-19 2022-06-24 中电金信软件有限公司 Transaction processing method and device, electronic equipment and readable storage medium

Also Published As

Publication number Publication date
CN111857888B (en) 2023-11-07

Similar Documents

Publication Publication Date Title
CN111857888B (en) Transaction processing method and device
CN111277639B (en) Method and device for maintaining data consistency
CN111881329A (en) Account balance management method and system
CN110738477A (en) reconciliation method, device, computer equipment and storage medium
CN111429241A (en) Accounting processing method and device
CN110706093A (en) Accounting processing method and device
CN111127181A (en) Voucher bookkeeping method and device
CN112184240A (en) Refund request processing method and device
CN112132674A (en) Transaction processing method and device
CN110705981B (en) Real-time settlement method and device
CN111861745A (en) Service wind control method and device
CN112884181A (en) Quota information processing method and device
CN111724245A (en) Credit card financing method and system
CN112990991A (en) Method and device for merging invoices
CN111526184B (en) Business auditing method and device
CN112559646A (en) Report downloading method and device
CN113485902A (en) Method, device, equipment and computer readable medium for testing service platform
CN111415245A (en) Account opening method and device
CN113704222A (en) Method and device for processing service request
CN111695984A (en) Account balance processing method and device
CN114997977B (en) Data processing method, device, electronic equipment and computer readable medium
CN113242306B (en) Block chain consensus method and device
CN111291038B (en) Data query method and device
CN111882118B (en) Decision making system and method
CN115619550A (en) Service data processing method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20220923

Address after: 25 Financial Street, Xicheng District, Beijing 100033

Applicant after: CHINA CONSTRUCTION BANK Corp.

Address before: 25 Financial Street, Xicheng District, Beijing 100033

Applicant before: CHINA CONSTRUCTION BANK Corp.

Applicant before: Jianxin Financial Science and Technology Co.,Ltd.

GR01 Patent grant
GR01 Patent grant