[go: nahoru, domu]

CN110992175A - Asynchronous accounting and transaction separation method and system based on message middleware - Google Patents

Asynchronous accounting and transaction separation method and system based on message middleware Download PDF

Info

Publication number
CN110992175A
CN110992175A CN201911046075.2A CN201911046075A CN110992175A CN 110992175 A CN110992175 A CN 110992175A CN 201911046075 A CN201911046075 A CN 201911046075A CN 110992175 A CN110992175 A CN 110992175A
Authority
CN
China
Prior art keywords
transaction
information
module
accounting
scene
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201911046075.2A
Other languages
Chinese (zh)
Inventor
姚菁菁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chengdu Mobo Network Technology Co ltd
Original Assignee
Chengdu Mobo Network Technology 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 Chengdu Mobo Network Technology Co ltd filed Critical Chengdu Mobo Network Technology Co ltd
Priority to CN201911046075.2A priority Critical patent/CN110992175A/en
Publication of CN110992175A publication Critical patent/CN110992175A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/40Authorisation, e.g. identification of payer or payee, verification of customer or shop credentials; Review and approval of payers, e.g. check credit lines or negative lists
    • G06Q20/405Establishing or using transaction specific rules
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/40Authorisation, e.g. identification of payer or payee, verification of customer or shop credentials; Review and approval of payers, e.g. check credit lines or negative lists
    • G06Q20/407Cancellation of a transaction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/12Accounting

Landscapes

  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Engineering & Computer Science (AREA)
  • Finance (AREA)
  • Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Economics (AREA)
  • Development Economics (AREA)
  • Marketing (AREA)
  • Technology Law (AREA)
  • Computer Security & Cryptography (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The invention discloses a method and a system for separating asynchronous accounting from transaction based on message middleware, which comprises the following steps: acquiring and sending customer transaction information to a transaction scene database; acquiring real-time transaction scene information in a transaction scene database, and regularly sending the real-time transaction scene information to an accounting system in a queue mode; carrying out data decryption on the received real-time transaction scene information, and analyzing; judging whether the analyzed data information is legal or not, and if so, judging whether the money information in the analyzed data information is correct or not; if not, sending a payment stopping instruction to the accounting system; and judging whether the amount information in the analyzed data information is correct or not, if so, performing accounting processing on the analyzed data information in an accounting entry mode, and sending the processed information to a general ledger database. The invention separates the transaction and accounting to improve the transaction processing performance and efficiency, thereby solving the complex business logic in a targeted way.

Description

Asynchronous accounting and transaction separation method and system based on message middleware
Technical Field
The invention relates to the technical field of data processing, in particular to an asynchronous accounting and transaction separation method and system based on message middleware.
Background
The traditional method is that transaction and accounting are tightly coupled together, at present, financial institutions adopt an accounting processing mode bound with the transaction, and accounting functions are integrated in each transaction system, but when the data processing amount is too large, the method has a great problem, the transaction performance is not strong, and the functions of high availability, high concurrency, hot plug and the like cannot be realized, so that a technology for separating transaction and accounting is urgently needed, the requirement of the system on strong data consistency can be met, on the other hand, in order to ensure the confidentiality of separated data transmission, encryption and decryption processing before and after transmission of business key data is needed, and an algorithm based on SM4 is used for encryption and decryption.
Disclosure of Invention
In order to solve the problems in the prior art, the invention provides a method and a system for separating asynchronous accounting from transaction based on message middleware, which separate transaction from accounting to improve the transaction processing performance and efficiency, thereby solving complex business logic in a targeted manner; a message compensation algorithm is adopted to provide double guarantees for data transmission; checking and accounting the transaction amount obtained asynchronously, if the transaction amount does not pass the checking, locking the designated account, and ensuring the accuracy and the safety of account data; meanwhile, key information before and after transmission is encrypted and decrypted, and the safety of data transmission is guaranteed.
The technical scheme adopted by the invention is as follows:
an asynchronous accounting and transaction separation method based on message middleware comprises the following steps:
s1, acquiring the customer transaction information, and sending the acquired transaction information based on the national password to a transaction scene database;
s2, acquiring real-time transaction scene information in the transaction scene database through the message middleware, and regularly sending the real-time transaction scene information to the accounting system in a queue mode;
s3, carrying out data decryption on the received real-time transaction scene information, and then analyzing;
s4, judging whether the analyzed data information is legal, if so, entering the step S5; if not, go to step S6;
s5, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, go to step S6;
s6, sending a payment stopping instruction to the accounting system;
and S7, performing accounting processing on the analyzed data information in an accounting entry mode, and sending the processed information to a general ledger database.
Acquiring transaction information of a client, sending the acquired transaction information based on the state password to a transaction scene database, judging whether the transaction information is successful or not, sending the successful transaction information to the transaction scene database, acquiring real-time transaction scene information in the transaction scene database through message middleware, regularly sending the real-time transaction scene information to an accounting system in a queue mode, analyzing the information after the accounting system receives the real-time transaction scene information, and simultaneously checking the legality and the correctness of the amount of the data; if the data is legal and the amount of money is correct, the verification is passed, and the analyzed data is subjected to accounting processing in an accounting entry mode and is recorded into a general ledger; and if the data is illegal or the amount of money is incorrect, indicating that the verification is not passed, activating a specific target locking function and sending a payment stopping instruction to the accounting system.
The method is mainly used for stripping the related accounting contents of the payment system to the accounting subsystem and completely separating transaction processing and accounting. The online transaction record transaction scene is transmitted to the accounting subsystem by using the message middleware, the accounting engine module of the accounting subsystem generates an accounting entry according to an accounting entry generation rule, the accounting engine system automatically performs debit and credit balance check on the whole transaction entry, the account system modifies account balance according to the transaction entry, and the general ledger module enters the general ledger on the same day according to the entry. And unidirectional data exchange from the payment to the kernel operator system is completed through the message middleware. High availability, high concurrency and hot plug are realized.
Further, step S1 includes the steps of:
s11, acquiring the transaction information of the client;
s12, judging whether the acquired customer transaction information is successful transaction information, if so, entering the step S13; if not, alarming and prompting, and entering the step S11;
and S13, sending the successful transaction information to the transaction scene database.
And judging whether the obtained customer transaction information is successful transaction information or not, and ensuring the effectiveness of subsequent work.
Further, step S2 includes the steps of:
s21, acquiring real-time transaction scene information in the transaction scene database through message middleware;
s22, timely sending real-time transaction scene information to an accounting system in a queue mode;
s23, judging whether the transaction scene information is successfully sent, if so, entering the step S3; if not, the flow proceeds to step S21.
The payment system transaction scene can track the message sending state of the message middleware, and if no feedback exists or the feedback fails, the transaction records are retransmitted again through a retransmission mechanism, so that the effectiveness of data transmission is ensured.
Further, step S5 includes the steps of:
s51, presetting a verification number value;
s52, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, recording the judgment times, and entering the step S53;
s53, judging whether the recorded judgment times exceed a preset verification time value, if so, entering a step S6; if not, the flow proceeds to step S52.
Balance check is carried out on each transaction amount obtained asynchronously by utilizing an accounting principle, if the check is not passed, the account amount is re-accounted and checked through a retry mechanism, after the appointed number of times of trial, the check is still not passed, a specific target locking function is activated, a message middleware is triggered to send a payment stopping instruction to a payment system, and the appointed account is locked until the amount check is successful. And the requirement of the system on strong data consistency is met.
The utility model provides an asynchronous accounting and transaction piece-rate system based on message middleware, includes customer transaction module, transaction scene module, scene analysis module, legal judgement module, amount of money judgement module, payment-stopping module and account processing module, wherein:
the client trading module is used for acquiring client trading information and sending the acquired trading information based on the national password to the trading scene database;
the transaction scene module is used for acquiring real-time transaction scene information in the transaction scene database through the message middleware and regularly sending the real-time transaction scene information to the accounting system in a queue mode;
the scene analysis module is used for carrying out data decryption on the received real-time transaction scene information and analyzing the data;
the legal judgment module is used for judging whether the analyzed data information is legal or not, and if so, the money amount judgment module works; if not, the payment stopping module works;
the amount judgment module is used for judging whether the amount information in the analyzed data information is correct or not, and if so, the accounting processing module works; if not, the payment stopping module works;
the payment stopping module is used for sending a payment stopping instruction to the accounting system;
and the accounting processing module is used for performing accounting processing on the analyzed data information in an accounting entry mode and sending the processed information to the general ledger database.
The method comprises the steps that transaction information of a client is obtained through a client transaction module, whether the transaction information is successful or not is judged, the successful transaction information is sent to a transaction scene database, the transaction scene module obtains real-time transaction scene information in the transaction scene database through message middleware, the real-time transaction scene information is sent to an accounting system in a queue mode at regular time, the accounting system receives the real-time transaction scene information and then analyzes the information through a scene analyzing module, and meanwhile, the legality and the correctness of money of the data are respectively checked through a legality judging module and a money amount judging module; if the data is legal and the amount of money is correct, the verification is passed, and the accounting processing module carries out accounting processing on the analyzed data in an accounting entry mode and records the data into a general ledger; and if the data is illegal or the amount of money is incorrect, the verification is not passed, the specific target locking function is activated, and the payment stopping module sends a payment stopping instruction to the accounting system.
The system is mainly used for stripping the related accounting contents of the payment system to the accounting subsystem and completely separating transaction processing and accounting. The online transaction record transaction scene is transmitted to the accounting subsystem by using the message middleware, the accounting engine module of the accounting subsystem generates an accounting entry according to an accounting entry generation rule, the accounting engine system automatically performs debit and credit balance check on the whole transaction entry, the account system modifies account balance according to the transaction entry, and the general ledger module enters the general ledger on the same day according to the entry. And unidirectional data exchange from the payment to the kernel operator system is completed through the message middleware. High availability, high concurrency and hot plug are realized.
Further, the customer transaction module comprises a transaction acquisition sub-module, a transaction judgment sub-module and an information sending sub-module, wherein:
the transaction acquisition submodule is used for acquiring the transaction information of the client;
the transaction judgment submodule is used for judging whether the acquired customer transaction information is successful transaction information or not, and if so, the information sending submodule; if not, giving an alarm to prompt, and enabling the transaction acquisition sub-module to work;
and the information sending submodule is used for sending the successful transaction information to the transaction scene database.
And judging whether the obtained customer transaction information is successful transaction information or not, and ensuring the effectiveness of subsequent work.
Further, the transaction scene module comprises a scene acquisition sub-module, a scene sending sub-module and a scene judgment sub-module, wherein:
the scene acquisition submodule is used for acquiring real-time transaction scene information in the transaction scene database through the message middleware;
the scene sending submodule is used for regularly sending real-time transaction scene information to the accounting system in a queue mode;
the scene judging submodule is used for judging whether the transaction scene information is successfully sent, and if so, the scene analyzing module works; and if not, the scene sending submodule works.
The payment system transaction scene can track the message sending state of the message middleware, and if no feedback exists or the feedback fails, the transaction records are retransmitted again through a retransmission mechanism, so that the effectiveness of data transmission is ensured.
Further, the amount judgment module comprises a preset times submodule, an amount judgment submodule and a times judgment submodule, wherein:
the preset times submodule is used for presetting a verification times value;
the amount judgment sub-module is used for judging whether the amount information in the analyzed data information is correct or not, and if so, the accounting processing module works; if not, recording the judgment times, and the times judgment submodule works;
the number judgment submodule is used for judging whether the recorded judgment number exceeds a preset verification number value or not, and if so, the payment stopping module works; if not, the money amount judgment submodule works.
Balance check is carried out on each transaction amount obtained asynchronously by utilizing an accounting principle, if the check is not passed, the account amount is re-accounted and checked through a retry mechanism, after the appointed number of times of trial, the check is still not passed, a specific target locking function is activated, a message middleware is triggered to send a payment stopping instruction to a payment system, and the appointed account is locked until the amount check is successful. And the requirement of the system on strong data consistency is met.
The invention has the beneficial effects that:
1. the unidirectional data exchange from the payment to the nuclear operator system is completed through the message middleware, and the functions of high availability, high concurrency, hot plug and the like are realized;
2. the distributed message middleware based on kafka has the advantages of high performance, persistence, good transverse expansion capability and the like, and has the functions of decoupling, peak clipping and asynchronous processing on accounting and transaction;
3. a message compensation algorithm is adopted to provide double guarantees for data transmission;
4. and checking and accounting the transaction amount obtained asynchronously, if the transaction amount does not pass the checking, locking the designated account, and encrypting and decrypting the key information before and after transmission to ensure the accuracy and the safety of the account data.
Drawings
FIG. 1 is a flow chart of a method for separating asynchronous accounting from transaction based on message middleware according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an asynchronous accounting and transaction separation system based on message middleware according to an embodiment of the present invention.
Description of reference numerals:
10. a customer transaction module; 101. a transaction acquisition sub-module; 102. a transaction judgment submodule; 103. an information sending submodule; 20. a transaction scenario module; 201. a scene acquisition submodule; 202. a scene sending submodule; 203. a scene judgment submodule; 30. a scene analyzing module; 40. a legal judgment module; 50. an amount judgment module; 501. a preset times submodule; 502. an amount judgment submodule; 503. a frequency judgment submodule; 60. a payment stopping module; 70. and an accounting processing module.
Detailed Description
Embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
Examples
As shown in fig. 1, an asynchronous accounting and transaction separation method based on message middleware includes the following steps:
s1, acquiring the customer transaction information, and sending the acquired transaction information based on the national password to a transaction scene database;
s2, acquiring real-time transaction scene information in the transaction scene database through the message middleware, and regularly sending the real-time transaction scene information to the accounting system in a queue mode;
s3, carrying out data decryption on the received real-time transaction scene information, and analyzing;
s4, judging whether the analyzed data information is legal, if so, entering the step S5; if not, go to step S6;
s5, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, go to step S6;
s6, sending a payment stopping instruction to the accounting system;
and S7, performing accounting processing on the analyzed data information in an accounting entry mode, and sending the processed information to a general ledger database.
Acquiring transaction information of a client, judging whether the transaction information is successful or not, sending the successful transaction information to a transaction scene database, acquiring real-time transaction scene information in the transaction scene database through message middleware, regularly sending the real-time transaction scene information to an accounting system in a queue mode, analyzing the information after the accounting system receives the real-time transaction scene information, and simultaneously checking the legality and the correctness of the amount of data; if the data is legal and the amount of money is correct, the verification is passed, and the analyzed data is subjected to accounting processing in an accounting entry mode and is recorded into a general ledger; and if the data is illegal or the amount of money is incorrect, indicating that the verification is not passed, activating a specific target locking function and sending a payment stopping instruction to the accounting system.
And after the payment transaction is successfully processed, every time a transaction scene record is recorded, the message middleware feeds the monitored record back to the kafka, simultaneously creates a record, writes in a corresponding file apend, and specifies a corresponding topic and a value in the record, and optionally selects a key and a partition. Serializing, and then putting the data into a corresponding sending queue according to topic and partition. product is a batch request that accumulates a batch and then sends it together, rather than immediately network. Has high performance, lasting and transverse expansion capability. The producer writes messages into the queue, and the consumer cancels messages from the queue to perform business logic. The functions of decoupling, peak clipping and asynchronous processing are performed on the accounting and the transaction.
The method is mainly used for stripping the related accounting contents of the payment system to the accounting subsystem and completely separating transaction processing and accounting. The online transaction record transaction scene is transmitted to the accounting subsystem by using the message middleware, the accounting engine module of the accounting subsystem generates an accounting entry according to an accounting entry generation rule, the accounting engine system automatically performs debit and credit balance check on the whole transaction entry, the account system modifies account balance according to the transaction entry, and the general ledger module enters the general ledger on the same day according to the entry. And unidirectional data exchange from the payment to the kernel operator system is completed through the message middleware. High availability, high concurrency and hot plug are realized.
In one embodiment, step S1 includes the following steps:
s11, acquiring the transaction information of the client;
s12, judging whether the acquired customer transaction information is successful transaction information, if so, entering the step S13; if not, alarming and prompting, and entering the step S11;
and S13, sending the successful transaction information to the transaction scene database.
And judging whether the obtained customer transaction information is successful transaction information or not, and ensuring the effectiveness of subsequent work.
In one embodiment, step S2 includes the following steps:
s21, acquiring real-time transaction scene information in the transaction scene database through message middleware;
s22, timely sending real-time transaction scene information to an accounting system in a queue mode;
s23, judging whether the transaction scene information is successfully sent, if so, entering the step S3; if not, the flow proceeds to step S21.
And a message compensation algorithm is adopted to provide double guarantee for data transmission. The message compensation algorithm is an algorithm based on kafka, which maintains a list of ARs including all the copies of the partitions, and self-research algorithm, and the ARs are further classified into ISRs and OSRs, i.e. a multi-copy synchronization mode. In order to ensure strong consistency of data and effectively prevent data loss, the kafka parameter acks is set to be-1, namely, the success can be returned after all machines in the ISR are synchronized successfully. Where the delay depends on the slowest machine, where the machines in the ISR list are variable and will be removed from the ISR list depending on how long there is no synchronization. At the moment, the self-research algorithm starts to play a role, the message sending state of the message middleware is tracked in the transaction scene of the payment system, and if no feedback exists or the feedback fails, the transaction record is retransmitted again through a retransmission mechanism.
In one embodiment, step S5 includes the following steps:
s51, presetting a verification number value;
s52, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, recording the judgment times, and entering the step S53;
s53, judging whether the recorded judgment times exceed a preset verification time value, if so, entering a step S6; if not, the flow proceeds to step S52.
Accounting systems are set up for the needs of internal accounting management, interdependent with payment transactions. However, the separation of transaction and accounting inevitably leads to the problem of misclassification and misclassification of two independent systems, the requirement of the systems on strong data consistency cannot be met, and the application of transaction error payment stopping specific target technology is generated for meeting the requirement. The technology for stopping payment of the specific target by transaction errors is characterized in that an account accounting principle is utilized to carry out balance check on each transaction amount asynchronously acquired, if the transaction amount does not pass the check, the account amount is re-accounted and checked through a retry mechanism, after the check is tried for a specified number of times and still fails, a specific target locking function is activated, a message middleware is triggered to send a payment stopping instruction to a payment system, the specified account is locked until the amount is successfully checked, and the requirement of the system on strong data consistency is met.
As shown in fig. 2, an asynchronous accounting and transaction separation system based on message middleware comprises a client transaction module 10, a transaction scenario module 20, a scenario parsing module 30, a legality judgment module 40, a money amount judgment module 50, a payment suspension module 60 and an accounting processing module 70, wherein:
the client transaction module 10 is used for acquiring client transaction information and sending the acquired transaction information based on the national password to the transaction scene database;
the transaction scene module 20 is configured to obtain real-time transaction scene information in a transaction scene database through the message middleware, and regularly send the real-time transaction scene information to the accounting system in a queue manner;
the scene analyzing module 30 is configured to decrypt and analyze the received real-time transaction scene information;
a legal judging module 40, configured to judge whether the analyzed data information is legal, and if so, the money amount judging module 50 works; if not, the payment stopping module 60 works;
the amount judgment module 50 is used for judging whether the amount information in the analyzed data information is correct, and if so, the accounting processing module 70 works; if not, the payment stopping module 60 works;
a payment stopping module 60 for sending a payment stopping instruction to the accounting system;
and the accounting processing module 70 is configured to perform accounting processing on the analyzed data information in an accounting entry manner, and send the processed information to the general ledger database.
The method comprises the steps that transaction information of a client is obtained through a client transaction module 10, whether the transaction information is successful or not is judged, the successful transaction information is sent to a transaction scene database, a transaction scene module 20 obtains real-time transaction scene information in the transaction scene database through message middleware, the real-time transaction scene information is sent to an accounting system in a queue mode at regular time, the accounting system receives the real-time transaction scene information and analyzes the information through a scene analyzing module 30, and meanwhile, the legality and the correctness of data are respectively checked through a legality judging module 40 and an amount judging module 50; if the data is legal and the amount is correct, the verification is passed, and the accounting processing module 70 performs accounting processing on the analyzed data in an accounting entry mode and records the data into a general ledger; if the data is illegal or the amount of money is incorrect, the verification is not passed, the specific target locking function is activated, and the payment stopping module 60 sends a payment stopping instruction to the accounting system.
The system is mainly used for stripping the related accounting contents of the payment system to the accounting subsystem and completely separating transaction processing and accounting. The online transaction record transaction scene is transmitted to the accounting subsystem by using the message middleware, the accounting engine module of the accounting subsystem generates an accounting entry according to an accounting entry generation rule, the accounting engine system automatically performs debit and credit balance check on the whole transaction entry, the account system modifies account balance according to the transaction entry, and the general ledger module enters the general ledger on the same day according to the entry. And unidirectional data exchange from the payment to the kernel operator system is completed through the message middleware. High availability, high concurrency and hot plug are realized. The transaction and the accounting are separated to improve the transaction processing performance and efficiency, so that the complex business logic is solved in a targeted manner in blocks; a message compensation algorithm is adopted to provide double guarantees for data transmission; checking and accounting the transaction amount obtained asynchronously, if the transaction amount does not pass the checking, locking the designated account, and ensuring the accuracy and the safety of account data; meanwhile, key information before and after transmission is encrypted and decrypted, and the safety of data transmission is guaranteed.
In one embodiment, the customer transaction module 10 includes a transaction obtaining sub-module 101, a transaction determining sub-module 102, and an information sending sub-module 103, wherein:
the transaction acquisition submodule 101 is used for acquiring the transaction information of a client;
the transaction judgment sub-module 102 is used for judging whether the acquired customer transaction information is successful transaction information, and if so, the information sending sub-module 103 is used for sending the information; if not, giving an alarm to prompt, and enabling the transaction acquisition sub-module 101 to work;
and the information sending submodule 103 is used for sending the successful transaction information to the transaction scene database.
And judging whether the obtained customer transaction information is successful transaction information or not, and ensuring the effectiveness of subsequent work.
In one embodiment, the transaction scenario module 20 includes a scenario acquisition sub-module 201, a scenario transmission sub-module 202, and a scenario judgment sub-module 203, where:
the scene obtaining submodule 201 is used for obtaining real-time transaction scene information in a transaction scene database through message middleware;
the scene sending submodule 202 is used for sending real-time transaction scene information to the accounting system in a queue mode at regular time;
the scene judging submodule 203 is used for judging whether the transaction scene information is successfully sent, and if so, the scene analyzing module 30 works; if not, the scene transmission sub-module 202 operates.
The payment system transaction scene can track the message sending state of the message middleware, and if no feedback exists or the feedback fails, the transaction records are retransmitted again through a retransmission mechanism, so that the effectiveness of data transmission is ensured.
In one embodiment, the amount determining module 50 includes a preset times sub-module 501, an amount determining sub-module 502, and a times determining sub-module 503, wherein:
a preset times submodule 501 for presetting a verification times value;
the amount judgment sub-module 502 is configured to judge whether the amount information in the analyzed data information is correct, and if yes, the accounting processing module 70 operates; if not, recording the judgment times, and the times judgment submodule 503 works;
the number judgment submodule 503 is configured to judge whether the recorded judgment number exceeds a preset verification number, and if so, the payment suspension module 60 operates; if not, the amount determination sub-module 502 operates.
Balance check is carried out on each transaction amount obtained asynchronously by utilizing an accounting principle, if the check is not passed, the account amount is re-accounted and checked through a retry mechanism, after the appointed number of times of trial, the check is still not passed, a specific target locking function is activated, a message middleware is triggered to send a payment stopping instruction to a payment system, and the appointed account is locked until the amount check is successful. And the requirement of the system on strong data consistency is met.
The above-mentioned embodiments only express the specific embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention.

Claims (8)

1. An asynchronous accounting and transaction separation method based on message middleware is characterized by comprising the following steps:
s1, acquiring the customer transaction information, and sending the acquired transaction information based on the national password to a transaction scene database;
s2, acquiring real-time transaction scene information in the transaction scene database through the message middleware, and regularly sending the real-time transaction scene information to the accounting system in a queue mode;
s3, carrying out data decryption on the received real-time transaction scene information, and analyzing;
s4, judging whether the analyzed data information is legal, if so, entering the step S5; if not, go to step S6;
s5, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, go to step S6;
s6, sending a payment stopping instruction to the accounting system;
and S7, performing accounting processing on the analyzed data information in an accounting entry mode, and sending the processed information to a general ledger database.
2. The asynchronous accounting and transaction separation method based on message middleware of claim 1, wherein the step S1 comprises the steps of:
s11, acquiring the transaction information of the client;
s12, judging whether the acquired customer transaction information is successful transaction information, if so, entering the step S13; if not, alarming and prompting, and entering the step S11;
and S13, sending the successful transaction information to the transaction scene database.
3. The asynchronous accounting and transaction separation method based on message middleware of claim 1, wherein the step S2 comprises the steps of:
s21, acquiring real-time transaction scene information in the transaction scene database through message middleware;
s22, timely sending real-time transaction scene information to an accounting system in a queue mode;
s23, judging whether the transaction scene information is successfully sent, if so, entering the step S3; if not, the flow proceeds to step S21.
4. The asynchronous accounting and transaction separation method based on message middleware of claim 1, wherein the step S5 comprises the steps of:
s51, presetting a verification number value;
s52, judging whether the money information in the analyzed data information is correct, if so, going to step S7; if not, recording the judgment times, and entering the step S53;
s53, judging whether the recorded judgment times exceed a preset verification time value, if so, entering a step S6; if not, the flow proceeds to step S52.
5. The utility model provides an asynchronous accounting and transaction piece-rate system based on message middleware, which characterized in that, includes customer transaction module, transaction scene module, scene analysis module, legal judgement module, amount of money judgement module, payment stopping module and account processing module, wherein:
the client trading module is used for acquiring client trading information and sending the acquired trading information based on the national password to the trading scene database;
the transaction scene module is used for acquiring real-time transaction scene information in the transaction scene database through the message middleware and regularly sending the real-time transaction scene information to the accounting system in a queue mode;
the scene analysis module is used for carrying out data decryption on the received real-time transaction scene information and analyzing the data;
the legal judgment module is used for judging whether the analyzed data information is legal or not, and if so, the money amount judgment module works; if not, the payment stopping module works;
the amount judgment module is used for judging whether the amount information in the analyzed data information is correct or not, and if so, the accounting processing module works; if not, the payment stopping module works;
the payment stopping module is used for sending a payment stopping instruction to the accounting system;
and the accounting processing module is used for performing accounting processing on the analyzed data information in an accounting entry mode and sending the processed information to the general ledger database.
6. The message-middleware-based asynchronous accounting and transaction separation system of claim 5, wherein the client transaction module comprises a transaction acquisition sub-module, a transaction judgment sub-module and an information transmission sub-module, wherein:
the transaction acquisition submodule is used for acquiring the transaction information of the client;
the transaction judgment submodule is used for judging whether the acquired customer transaction information is successful transaction information or not, and if so, the information sending submodule; if not, giving an alarm to prompt, and enabling the transaction acquisition sub-module to work;
and the information sending submodule is used for sending the successful transaction information to the transaction scene database.
7. The message-middleware-based asynchronous accounting and transaction separation system of claim 5, wherein the transaction scenario module comprises a scenario acquisition sub-module, a scenario transmission sub-module and a scenario judgment sub-module, wherein:
the scene acquisition submodule is used for acquiring real-time transaction scene information in the transaction scene database through the message middleware;
the scene sending submodule is used for regularly sending real-time transaction scene information to the accounting system in a queue mode;
the scene judging submodule is used for judging whether the transaction scene information is successfully sent, and if so, the scene analyzing module works; and if not, the scene sending submodule works.
8. The message-middleware-based asynchronous accounting and transaction separating system of claim 5, wherein the amount judgment module comprises a preset number sub-module, an amount judgment sub-module and a number judgment sub-module, wherein:
the preset times submodule is used for presetting a verification times value;
the amount judgment sub-module is used for judging whether the amount information in the analyzed data information is correct or not, and if so, the accounting processing module works; if not, recording the judgment times, and the times judgment submodule works;
the number judgment submodule is used for judging whether the recorded judgment number exceeds a preset verification number value or not, and if so, the payment stopping module works; if not, the money amount judgment submodule works.
CN201911046075.2A 2019-10-30 2019-10-30 Asynchronous accounting and transaction separation method and system based on message middleware Pending CN110992175A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911046075.2A CN110992175A (en) 2019-10-30 2019-10-30 Asynchronous accounting and transaction separation method and system based on message middleware

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911046075.2A CN110992175A (en) 2019-10-30 2019-10-30 Asynchronous accounting and transaction separation method and system based on message middleware

Publications (1)

Publication Number Publication Date
CN110992175A true CN110992175A (en) 2020-04-10

Family

ID=70082722

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911046075.2A Pending CN110992175A (en) 2019-10-30 2019-10-30 Asynchronous accounting and transaction separation method and system based on message middleware

Country Status (1)

Country Link
CN (1) CN110992175A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112785403A (en) * 2021-01-28 2021-05-11 杉德银卡通信息服务有限公司 Accounting configuration method and system
CN113628021A (en) * 2021-07-30 2021-11-09 北京乾元大通技术有限公司 Efficient accounting system
CN117934190A (en) * 2024-03-20 2024-04-26 深圳市雁联计算系统有限公司 Heterogeneous billing method and system based on message middleware and distributed lock

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060036448A1 (en) * 2001-06-13 2006-02-16 Caminus Corporation System architecture and method for energy industry trading and transaction management
CN101110113A (en) * 2007-08-10 2008-01-23 魏恺言 Multi-use safety device for computing electronic payment code and its generating method
CN103247003A (en) * 2013-05-15 2013-08-14 上海大智慧股份有限公司 Distributed program trading system oriented to event processing
CN103942681A (en) * 2013-01-22 2014-07-23 成都摩宝网络科技有限公司 Mobile phone near field payment system based on RFID
GB2533432A (en) * 2014-12-18 2016-06-22 Ipco 2012 Ltd A device system, method and computer program product for processing electronic transaction requests
CN106022902A (en) * 2016-05-13 2016-10-12 中国建设银行股份有限公司 Accounting method and device
CN106097098A (en) * 2016-06-02 2016-11-09 重庆农村商业银行股份有限公司 The core banking system separated is adjusted in transaction based on open architecture
CN106971340A (en) * 2017-01-16 2017-07-21 平安银行股份有限公司 The method and system that transaction is adjusted
CN109472577A (en) * 2018-09-26 2019-03-15 中国平安人寿保险股份有限公司 Account keeps accounts method, apparatus, computer equipment and storage medium
CN109493201A (en) * 2018-09-18 2019-03-19 深圳壹账通智能科技有限公司 Account checking method, device, computer equipment and storage medium
WO2019061630A1 (en) * 2017-09-26 2019-04-04 武汉斗鱼网络科技有限公司 Transaction accounting method, and client

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060036448A1 (en) * 2001-06-13 2006-02-16 Caminus Corporation System architecture and method for energy industry trading and transaction management
CN101110113A (en) * 2007-08-10 2008-01-23 魏恺言 Multi-use safety device for computing electronic payment code and its generating method
CN103942681A (en) * 2013-01-22 2014-07-23 成都摩宝网络科技有限公司 Mobile phone near field payment system based on RFID
CN103247003A (en) * 2013-05-15 2013-08-14 上海大智慧股份有限公司 Distributed program trading system oriented to event processing
GB2533432A (en) * 2014-12-18 2016-06-22 Ipco 2012 Ltd A device system, method and computer program product for processing electronic transaction requests
CN106022902A (en) * 2016-05-13 2016-10-12 中国建设银行股份有限公司 Accounting method and device
CN106097098A (en) * 2016-06-02 2016-11-09 重庆农村商业银行股份有限公司 The core banking system separated is adjusted in transaction based on open architecture
CN106971340A (en) * 2017-01-16 2017-07-21 平安银行股份有限公司 The method and system that transaction is adjusted
WO2019061630A1 (en) * 2017-09-26 2019-04-04 武汉斗鱼网络科技有限公司 Transaction accounting method, and client
CN109493201A (en) * 2018-09-18 2019-03-19 深圳壹账通智能科技有限公司 Account checking method, device, computer equipment and storage medium
CN109472577A (en) * 2018-09-26 2019-03-15 中国平安人寿保险股份有限公司 Account keeps accounts method, apparatus, computer equipment and storage medium

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
刘彬;石亮亮;: "银行科技系统会计引擎作用浅析" *
李法杰;张睿;: "农村商业银行核心业务系统核算引擎现状分析与改进探讨" *
索燕;: "支付系统中间件应用研究" *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112785403A (en) * 2021-01-28 2021-05-11 杉德银卡通信息服务有限公司 Accounting configuration method and system
CN113628021A (en) * 2021-07-30 2021-11-09 北京乾元大通技术有限公司 Efficient accounting system
CN117934190A (en) * 2024-03-20 2024-04-26 深圳市雁联计算系统有限公司 Heterogeneous billing method and system based on message middleware and distributed lock
CN117934190B (en) * 2024-03-20 2024-05-28 深圳市雁联计算系统有限公司 Heterogeneous billing method and system based on message middleware and distributed lock

Similar Documents

Publication Publication Date Title
CN110609869B (en) Block chain-based data storage method, related equipment and storage medium
CN110992175A (en) Asynchronous accounting and transaction separation method and system based on message middleware
CN111415163B (en) Block chain-based service processing and verifying method, system and verifying node
CN110458559B (en) Transaction data processing method, device, server and storage medium
WO2020088098A1 (en) Block chain-based quality data processing method and apparatus
CN112367629B (en) Financial big data processing method based on 5G and block chain and system platform thereof
CN105959169B (en) A kind of transaction data processing system and method
US10657028B2 (en) Method for replicating production behaviours in a development environment
CN110221816A (en) Algorithm operation method, device, medium and algorithm platform based on algorithm platform
CN116051276A (en) Block chain-based decentralised digital asset trading system
CN111583041A (en) Block chain-based bond issue data storage and verification processing method and device
CN112883425B (en) Block chain-based data processing method and block chain link point
CN109213612B (en) Invoice issuing method and system based on webservice interface
CN111274255B (en) Service data monitoring method and system, monitoring architecture, equipment and storage medium
CN106355496A (en) Method, system and device for realizing batch electronic transactions as well as electronic signature tool
CN110335151B (en) Centralized language prediction machine matched with intelligent contract application, information output method and system
CN116956346A (en) Transaction data safety supervision system and method based on big data
CN114782045B (en) Cross-chain non-transactional writing method and device, storage medium and electronic equipment
CN106779703B (en) Dynamic realization method and device for centralized management of bank card key
CN114997987A (en) Business information processing method, device, equipment and medium based on block chain system
CN115660676A (en) Transaction management method and device based on block chain, storage medium and electronic equipment
CN107483210B (en) Data verification method and system
CN115099800A (en) Block chain based method and device for transferring poor asset data
CN112395012A (en) Data clearing method and device based on double-core intelligent electric meter and computer equipment
CN106408301A (en) Method and device for improving security of transaction command

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20200410

RJ01 Rejection of invention patent application after publication