[go: nahoru, domu]

CN108446975B - Quota management method and device - Google Patents

Quota management method and device Download PDF

Info

Publication number
CN108446975B
CN108446975B CN201810263596.2A CN201810263596A CN108446975B CN 108446975 B CN108446975 B CN 108446975B CN 201810263596 A CN201810263596 A CN 201810263596A CN 108446975 B CN108446975 B CN 108446975B
Authority
CN
China
Prior art keywords
quota
limit
node
transaction
nodes
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.)
Active
Application number
CN201810263596.2A
Other languages
Chinese (zh)
Other versions
CN108446975A (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.)
Shanghai Data Exchange Corp
Original Assignee
Shanghai Data Exchange Corp
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 Shanghai Data Exchange Corp filed Critical Shanghai Data Exchange Corp
Priority to CN201810263596.2A priority Critical patent/CN108446975B/en
Publication of CN108446975A publication Critical patent/CN108446975A/en
Application granted granted Critical
Publication of CN108446975B publication Critical patent/CN108446975B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/02Banking, e.g. interest calculation or account maintenance
    • 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

Landscapes

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

Abstract

The invention provides a method and a device for managing a quota. The method comprises the following steps: receiving a request of transaction operation sent by a user; selecting a target node meeting a transaction range condition from a node tree corresponding to an account of a user; if the quota of the target node can meet the transaction operation, executing the transaction operation; and if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the successful application, and then executing the transaction operation. The method and the device help to reasonably process the problem of credit management of the data transaction system, thereby helping to ensure smooth and efficient data transaction.

Description

Quota management method and device
Technical Field
The present invention relates to the field of computing technologies, and in particular, to a method and an apparatus for managing a quota.
Background
With the development of information technology, data becomes an essential element for people's life and work, and the amount of data generated in people's work and life is huge, and the data amount growth speed is higher and higher. Data trading activities are more and more, and data trading activities can be performed by using a data trading system frequently, because data is more and more closely related to production and life of people.
The distributed high-concurrency data transaction system is one of data transaction systems and has the characteristics of cohesiveness, transparency, high concurrency and the like. In the distributed high-concurrency data transaction system, a data demander pays to inquire data resources of a data provider, an account of the data demander obtains a certain amount through modes of recharging, credit granting and the like so as to carry out data purchasing operation, and the amount management of the data demander is an important link in a data transaction link. In order to smoothly perform data transaction, it is necessary to provide an efficient and sensitive credit management mechanism to improve the overall data distribution efficiency of the distributed high-concurrency data transaction system. The data distribution subsystem of the distributed high-concurrency data transaction system is complex and is a distributed high-concurrency high-throughput system. The prior art of the method for managing the quota in the huge system has the problems of too complex quota management process, too large calculation amount and the like, so that the efficient and sensitive quota management is difficult to realize.
Disclosure of Invention
In view of the above, the present invention provides a method and an apparatus for controlling credit, which are helpful to reasonably handle the credit management problem of a data transaction system, thereby helping to ensure that data transaction is smoothly and efficiently performed. Other objects and advantages of the present invention will be described or apparent in connection with the detailed description.
To achieve the above object, according to one aspect of the present invention, there is provided a method for managing an amount.
The method for managing the quota of the embodiment of the invention comprises the following steps: receiving a request of transaction operation sent by a user; selecting a target node meeting a transaction range condition from a node tree corresponding to an account of a user; if the quota of the target node can meet the transaction operation, executing the transaction operation; and if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the successful application, and then executing the transaction operation.
Optionally, the step of selecting a target node that meets the transaction range condition from the node tree corresponding to the account of the user includes: searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, selecting the nodes as target nodes; if not, entering the following steps; searching non-leaf nodes meeting the transaction range condition in the child nodes, and if the non-leaf nodes are found, selecting the non-leaf nodes as target nodes; if not, entering the following steps; and judging whether the root node meets the transaction range condition, if so, selecting the root node as a target node.
Optionally, after the step of performing the transaction operation, the method further includes: deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain a remaining credit; recording the surplus limit into a distribution log of the target node; after the set time is reached, calculating the settlement amount of the account according to the distribution log; updating the account quota according to the settlement quota; and sending the updated quota of the account to the quota control center.
Optionally, the step of applying for the corresponding quota from the quota control center includes: sending limit application information to a limit control center, and applying for a corresponding limit from a limit pool corresponding to the node tree; locking the limit pool to ensure that the limit control center refuses to respond to other limit application information after receiving the other limit application information of the user; receiving information of successful credit application; and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
In another aspect of the embodiments of the present invention, an apparatus for managing a quota is provided.
The limit management device of the embodiment of the invention comprises: a request receiving module: the system comprises a processing unit, a processing unit and a display unit, wherein the processing unit is used for receiving a request of a transaction operation sent by a user; a target node selection module: the method comprises the steps that a target node meeting a transaction range condition is selected from a node tree corresponding to an account of a user; a first execution module: the system is used for executing the transaction operation if the limit of the target node can meet the transaction operation; a second execution module: and if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the application is successful, and then executing the transaction operation.
Optionally, the target node selecting module includes: leaf node search unit: the node is used for searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, the nodes are selected as target nodes; if not, entering the following steps; a non-leaf node search unit: the method comprises the steps that non-leaf nodes meeting transaction range conditions are searched in child nodes, and if the non-leaf nodes are found, the non-leaf nodes are selected as target nodes; if not, entering the following steps; a root node search unit: and the method is used for judging whether the root node meets the transaction range condition, and if so, selecting the root node as a target node.
Optionally, the apparatus further comprises: the residual amount calculating module: the system is used for deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain remaining credit; the remaining amount recording module: the system is used for recording the surplus limit into a distribution log of the target node; a settlement limit calculation module: the system is used for calculating the settlement limit of the account according to the distribution log after the set time is reached; a balance updating module: the account is used for updating the account amount according to the settlement amount; a balance sending module: and the account management server is used for sending the updated quota of the account to the quota control center.
Optionally, the second execution module includes: the credit application information sending unit: the system comprises a node tree, a limit control center and a limit application server, wherein the limit application server is used for sending limit application information to the limit control center and applying for a corresponding limit from a limit pool corresponding to the node tree; a locking unit: the system is used for locking the quota pool, so that the quota control center refuses to respond to other quota application information after receiving the other quota application information of the user; a feedback information receiving unit: receiving information of successful credit application; an unlocking unit: and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
According to still another aspect of the present invention, there is provided an electronic apparatus including: one or more processors; storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to carry out a method according to any embodiment of the invention.
According to a further aspect of the invention, there is provided a computer readable medium having stored thereon a computer program which, when executed by a processor, performs a method according to any of the embodiments of the invention.
According to the technical scheme of the invention, when a user wants to execute the transaction operation of data, a request of the transaction operation can be sent through a data demand side front-end processor, after the request of the transaction operation sent by the user is received, a target node is selected from nodes meeting the condition of the transaction range, when the target node has a quota, the transaction operation is directly executed, and the quota of the corresponding target node is deducted; when the target node does not have the quota, the quota is applied, then the transaction operation is executed, and the quota of the corresponding target node is deducted after the transaction operation is completed. When a plurality of transaction operation requests exist, different transaction operations can be respectively executed on a plurality of nodes, and the quota application and cost between the nodes can be independently carried out, so that the complexity of quota management can be reduced in a high-concurrency data transaction system, the condition that a large amount of repeated read-write operations are carried out on the same quota data is avoided, repeated calculation is reduced, and the extra overhead of the system is reduced. Meanwhile, the situation that a plurality of processes compete for the same quota data at the same time can be avoided, when massive users request data transaction for some data in a short time, the frequent access and update situations are reduced, the system load is reduced, the response time is shortened, and the execution speed and the execution efficiency of the data transaction are improved. Under the high concurrency state, when the data base writing operation of the current process is not completed, the subsequent process reads the data base, the actual credit is not enough when the reading state of the subsequent process is the same as the reading state of the previous process, and the transaction can be carried out, namely the real cost exceeds the credit. The embodiment of the invention reduces the high concurrency condition on one node, simultaneously carries out transaction operation after the credit is successfully applied, avoids the problem that real cost exceeds the credit, and reduces the high concurrency condition on the same node without influencing the response speed of a data transaction system because the nodes on the node tree can bear the credit spent by the transaction operation in the corresponding transaction range.
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 diagram illustrating the main steps of a method for managing a credit in accordance with an embodiment of the present invention;
FIG. 2 is a schematic diagram of a processing assembly according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a node tree structure according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of information transmission between a node tree and a credit control center according to an embodiment of the invention;
FIG. 5 is a schematic diagram of the main modules of an quota managing apparatus according to an embodiment of the present 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.
In the embodiment of the invention, a hierarchical control mode is adopted to accurately control the quota of the account, and the complexity of the whole system is not increased. The following detailed description is made with reference to the accompanying drawings. FIG. 1 is a diagram illustrating the main steps of a method for managing an amount according to an embodiment of the present invention.
Step 101: and receiving a request of transaction operation sent by a user.
The user is a data demand party, and sends a data transaction operation request through the data transaction system to request to obtain certain specific data through the account amount. For example, a data consumer needs advertisement data, generating a request for a transaction operation with the advertisement data.
Step 102: and selecting a target node meeting the transaction range condition from the node tree corresponding to the account of the user.
For the same user, there may be one main account and multiple sub-accounts, and among all the main accounts and sub-accounts, the account capable of data transaction is divided into nodes, and a node tree corresponding to the user is generated. In the initial case, the user applies for the primary account first, and then applies for the secondary account according to the transaction scope. And applying for accounts according to the range of available transactions, wherein the accounts comprise a main account and sub-accounts, and each account is a node. The business account can continue to generate sub business accounts, namely sub nodes according to the reduced product range, so that a node tree divided by the transaction range is formed. Each user typically corresponds to a tree of nodes. In the embodiment of the present invention, a user generally has a primary account, and thus, a user corresponds to a node tree, the primary account corresponds to a root node of the node tree, and the sub-account corresponds to a child node of the node tree. In the node tree corresponding to the user, each node corresponds to a certain transaction range, and data transaction can be performed within the transaction range corresponding to the node, for example, a certain node can perform data transaction with a certain data provider or certain specific data providers. The request of the transaction operation corresponds to a specific transaction range, for example, data provided by a specific data provider is needed, and before the request of the corresponding transaction operation, a node corresponding to the transaction range of the request of the current transaction operation needs to be searched. In a node tree, at least one node meeting the transaction range condition may exist, and one of the nodes meeting the transaction range condition is selected as a target node, and the target node provides a required quota for the transaction operation.
The target node may be a child node or a root node.
When no node meeting the transaction range condition exists in the node tree, the related information of transaction failure is returned, then the user can be prompted to register a new sub-account, a new sub-account is generated for the user, and then a new child node capable of meeting the transaction range condition is correspondingly established in the node tree.
Step 103: and if the quota of the target node can meet the transaction operation, executing the transaction operation.
The user obtains a certain amount by charging the account, accepting the giving operation of another account, the credit giving operation and the like, if the amount of the selected target node can meet the request of the transaction operation, the transaction operation is directly executed, and the amount consumed by the transaction operation is deducted from the amount of the target node.
Step 104: and if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota through a quota control center, adding the applied quota to the total quota of the target node after the successful application, and then executing the transaction operation.
After the target node is selected, the amount required by the transaction operation is directly deducted from the amount of the target node, and the new amount is applied for the target node after the transaction operation is completed, so that the amounts of the main account and the sub-account of the user are not influenced with each other, and the amount control is simpler.
The quota applied by the node of the node tree can be used only when the node is used as a target node of a request of certain transaction operation, and the node can be applied after the quota is used up, so that the condition that the actual expense of the account exceeds the quota of the account can be avoided.
In the step of applying for the corresponding quota through the quota control center, the quota applied is adapted to the transaction operation and can be determined by means of prediction and the like.
The step of executing the transaction operation specifically includes all steps necessary for executing the transaction operation, for example, sending a data request corresponding to executing the transaction operation to a data provider, receiving data feedback information provided by the data provider, sending the data feedback information to a set receiving module, and the like.
In the embodiment of the invention, when the target node carries out transaction, if the limit is not enough, the node applies for the limit to the limit control center, and generally carries out pre-estimated limit application according to the business volume and the price of transaction operation. When a plurality of transaction operations occur to a user account, the transaction operations respectively acquire the quota required by the transaction on the corresponding target nodes, and because the target nodes can not apply for the quota to the quota center through the root node, when the requests of the transaction operations are sent out simultaneously, the conditions of competing the same quota data do not occur, the problem that more and more requests of other transaction operations can not be responded in time along with the normal response time is avoided, and the system congestion is effectively avoided. In a highly concurrent data transaction system, the embodiment of the invention selects the target node to execute the transaction operation according to the range corresponding to the request of the transaction operation, reduces the frequent access and update of some data by mass users in a short time, shortens the response time, improves the response speed, and avoids the breakdown of the data transaction system caused by the avalanche effect generated by the requests of the users for multiple times of the same transaction operation when the response is slow.
In some embodiments of the present invention, the step of selecting a target node that satisfies the transaction scope condition from a node tree corresponding to the account of the user includes:
searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, selecting the nodes as target nodes; if not, entering the following steps;
searching non-leaf nodes meeting the transaction range condition in the child nodes, and if the non-leaf nodes are found, selecting the non-leaf nodes as target nodes; if not, entering the following steps;
and judging whether the root node meets the transaction range condition, if so, selecting the root node as a target node.
The transaction range may correspond to a request for a transaction operation, and may be recorded in the request for a transaction operation. In the embodiment of the invention, the trading nodes are selected according to the minimum matching principle of the trading range, namely the leaf nodes have the trading priority. Therefore, all transaction operations are distributed to different nodes as much as possible, the nodes with large transaction range are prevented from bearing excessive transaction operation tasks, congestion is further avoided, and processing efficiency is improved.
In some embodiments of the present invention, after the step of performing the transaction operation, the method further includes:
deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain a remaining credit;
recording the surplus limit into a distribution log of the target node;
after the set time is reached, calculating the settlement amount of the account according to the distribution log;
updating the account quota according to the settlement quota;
and sending the updated quota of the account to the quota control center.
In the embodiment of the invention, each node can acquire a certain amount for transaction operation in the modes of cash recharging, platform giving, platform credit granting and the like before transaction operation, and the amount can be gradually consumed after the transaction operation is executed. All nodes respectively calculate the amount consumed for executing corresponding transaction operation, then the amount calculated by each node is sent to an amount control center for gathering, the amount counting and the real account settlement are separately performed, the account settlement generates a distribution log according to the real distribution amount, the times of transaction operation requests of the account of a data demand party are recorded in the distribution log, then the settlement amount of the account is calculated according to the distribution log, the expenses of all accounts of a user are gathered to obtain the total expense of all sub-accounts and main accounts of the user, and in the amount control center, the residual amount of the user is the initial amount minus the total expense. The method can avoid repeated calculation and ensure the accuracy of the calculation of the quota.
In some embodiments of the present invention, the step of applying for the corresponding credit through the credit control center includes:
sending limit application information to a limit control center, and applying for a corresponding limit from a limit pool corresponding to the node tree;
locking the limit pool to ensure that the limit control center refuses to respond to other limit application information after receiving the other limit application information of the user;
receiving information of successful credit application;
and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
In the prior art, in a high concurrency scenario, multiple requests sent by multiple processes are simultaneously distributed to multiple servers in an intranet through load balancing, and before a certain request is successfully written into a database, query results of other requests may be in a state before writing, which may cause system misjudgment.
In the embodiment of the invention, when transaction operation is executed, the amount of the target node is deducted, and the embodiment of the invention introduces a locking mechanism, and accounts of the same user share an amount pool, namely a node share amount pool of the same node tree. Only one quota application message is processed at one time, other quota application messages are discharged when one quota application message is processed, and the condition that multiple processes simultaneously compete for the same quota data due to the introduction of a locking mechanism when a plurality of sub-accounts simultaneously apply for the quota can not occur.
The processing components related to the present invention mainly include a DMP (Data Management Platform), a DLS (Data link Service, a portal for providing Data transaction services to members by a Data transaction center), a DMIX (Data distribution System), a DAS (Data Analysis System), a Redis cluster, a CAP product (Chinese Audience image library), a CRP product (Credit Risk image library), and a line control center.
DMP: a supplier or demander business system for data circulation in the transaction process; in the system, the requiring DMP sends out a query request, the query request is routed to the DMP of the data provider through the DMIX, and the supplier DMP returns a query result after receiving the request.
DLS: through a portal for providing data transaction service for members through a data transaction center, the data provider and the data demander members can realize the transaction operations of commodity listing, demand release, data ordering, transaction management, information inquiry, clearing and settlement and the like of data transaction, and can execute the operation of settlement and credit file push.
DMIX: the method is mainly used for receiving the query request of the DMP of the data demand party and routing the DMP of the data supply party, and has the functions of real-time quota calculation, control, production and distribution log and the like.
DAS: and focusing on operating the distribution log generated by the DMIX, analyzing the distribution log, and summarizing the distribution amount for clearing and settlement by the DLS.
Redis Cluster: and introducing a third memory database cluster, wherein each node corresponds to a Redis cache in the node tree, and the Redis caches of a plurality of nodes form a Redis cluster. Redis is a key-Value storage system that supports the storage of data in some structures, such as Value structures. The Redis cluster provides convenient and fast data caching service, and is used for realizing process communication and caching data in a system. When the request of transaction operation is processed, the target node firstly inquires the quota in the Redis cache of the target node, and if the quota is insufficient, the quota is requested to the quota control center.
CAP product: is a standardized data product oriented to the marketing industry. The main user groups are advertisers, 4A advertising agent companies, DSP data delivery enterprises and the like, and various services such as user portraits before advertisement delivery, data completion during delivery, data verification after delivery and the like are provided for the users.
CRP product: the product can provide credit risk data exploration service for individuals and enterprises for financial institutions and help the financial institutions to finish risk control.
The limit control center: the credit control center is the credit management and control center of all the user accounts and sub-accounts thereof. The service provided by the credit control center comprises the following steps: the system is responsible for accepting the application of the account quota and redistributing and scheduling the node quota through calculation; allocating the amount, calculating the real cost of the user for clearing the cost, and obtaining the remaining amount of the account; and processing other quota adjusting related services, and the like.
Fig. 2 is a schematic diagram of processing components involved in the quota management method provided by the embodiment of the invention, including a Reids cache 201, a target node 202, a quota control center 203, a DLS204, a DAS205, a DMIX206, and a data provider front-end processor 207.
After receiving a request of a transaction operation of a user, matching transaction nodes, and selecting a target node 202 meeting the transaction range condition of the request. After determining the target node 202, the target node queries the quota in its Redis cache 201, and if the quota is insufficient, requests the quota from the quota control center 203. After the target node 202 successfully acquires the quota, it executes the transaction operation, and initiates a data request corresponding to the request of the transaction operation to the data provider front-end processor 207. During which time DMIX206 is responsible for both data dispatches. And when the data distribution is completed, the target node deducts the corresponding amount and records the amount in the Redis cache 201. Then, the record of the current transaction operation is recorded in the distribution log and transmitted from the node to the DAS 205. The DAS205 analyzes and counts the account delivery volume in real time, counts xml files of delivery information of all accounts, and pushes the xml files to the DLS204 at a fixed time every day (for example, 5 am).
In some embodiments of the present invention, the node tree may take the structure shown in FIG. 3. Including a root node 301, at least one non-leaf child node 302, and at least one leaf node 303. In general, the root node 301 corresponds to the primary account of the user, and the transaction range is the largest. And as the number of layers of the sub-accounts of the user corresponding to the other nodes is increased, the transaction range of the sub-accounts corresponding to the nodes is reduced.
FIG. 4 is a diagram illustrating a relationship between a node tree and a credit control center in an embodiment of the present invention. Node trees 401 of multiple users send quota application information to quota control center cluster 403 through load balancing 402, each node tree 401 is provided with corresponding quota control center 4031 in quota control center cluster 403, any node on the same node tree 401 can send quota application information to corresponding quota control center 4031 through load balancing 402, and receive information that quota application passes or does not pass through load balancing 402.
Meanwhile, the present invention also provides an amount management device, which is shown in fig. 5 as a block diagram, and the amount management device 500 of the embodiment includes: the device comprises a request receiving module, a target node selecting module, a first executing module and a second executing module.
A request receiving module: the system comprises a processing unit, a processing unit and a display unit, wherein the processing unit is used for receiving a request of a transaction operation sent by a user;
a target node selection module: the method comprises the steps that a target node meeting a transaction range condition is selected from a node tree corresponding to an account of a user;
a first execution module: the transaction operation is executed if the quota of the target node can meet the request of the transaction operation;
a second execution module: and if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the application is successful, and then executing the transaction operation.
In some embodiments of the invention, the target node selection module comprises:
leaf node search unit: the node is used for searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, the nodes are selected as target nodes; if not, entering the following steps;
a non-leaf node search unit: the method comprises the steps that non-leaf nodes meeting transaction range conditions are searched in child nodes, and if the non-leaf nodes are found, the non-leaf nodes are selected as target nodes; if not, entering the following steps;
a root node search unit: and the method is used for judging whether the root node meets the transaction range condition, and if so, selecting the root node as a target node.
In some embodiments of the invention, the apparatus further comprises:
the residual amount calculating module: the system is used for deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain remaining credit;
the remaining amount recording module: the system is used for recording the surplus limit into a distribution log of the target node;
a settlement limit calculation module: the system is used for calculating the settlement limit of the account according to the distribution log after the set time is reached;
a balance updating module: the account is used for updating the account amount according to the settlement amount;
a balance sending module: and the account management server is used for sending the updated quota of the account to the quota control center.
In some embodiments of the invention, the second execution module comprises:
the credit application information sending unit: the system comprises a node tree, a limit control center and a limit application server, wherein the limit application server is used for sending limit application information to the limit control center and applying for a corresponding limit from a limit pool corresponding to the node tree;
a locking unit: the system is used for locking the quota pool, so that the quota control center refuses to respond to other quota application information after receiving the other quota application information of the user;
a feedback information receiving unit: receiving information of successful credit application;
an unlocking unit: and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
DLS generates the bill according to the delivery list and the product price, updates the account amount account and the fund account according to the bill, and finally pushes the latest amount to the amount control center, so that the amount control center also has the latest amount of each account. The system thus forms a closed loop and cycles on.
As another aspect, embodiments of the present invention provide an electronic device, which includes one or more processors; and a storage device, configured to store one or more programs, which when executed by the one or more processors, cause the one or more processors to implement the method according to the embodiment of the present invention, for example, the method executed according to fig. 1. As a further aspect, the present invention also provides a computer-readable medium, which may be included 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, enable the device to perform the methods of embodiments of the present invention, e.g., the methods performed in accordance with fig. 1.
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 (8)

1. A method for managing a quota, comprising:
receiving a request of transaction operation sent by a user;
selecting a target node meeting a transaction range condition from a node tree corresponding to the account of the user;
if the quota of the target node can meet the transaction operation, executing the transaction operation;
if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the successful application, and then executing the transaction operation;
the step of selecting a target node meeting the transaction range condition from the node tree corresponding to the account of the user comprises the following steps:
searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, selecting the nodes as target nodes; if not, entering the following steps;
searching non-leaf nodes meeting the transaction range condition in the child nodes, and if the non-leaf nodes are found, selecting the non-leaf nodes as target nodes; if not, entering the following steps;
and judging whether the root node meets the transaction range condition, if so, selecting the root node as a target node.
2. The method of claim 1, wherein the step of performing the transaction operation is followed by:
deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain a remaining credit;
recording the surplus limit into a distribution log of the target node;
after the set time is reached, calculating the settlement amount of the account according to the distribution log;
updating the account quota according to the settlement quota;
and sending the updated quota of the account to the quota control center.
3. The method of claim 1 or 2, wherein the step of applying for the corresponding credit to the credit control center comprises:
sending limit application information to a limit control center, and applying for a corresponding limit from a limit pool corresponding to the node tree;
locking the limit pool to ensure that the limit control center refuses to respond to other limit application information after receiving the other limit application information of the user;
receiving information of successful credit application;
and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
4. An amount management device, comprising:
a request receiving module: the system comprises a processing unit, a processing unit and a display unit, wherein the processing unit is used for receiving a request of a transaction operation sent by a user;
a target node selection module: the method comprises the steps that a target node meeting a transaction range condition is selected from a node tree corresponding to an account of a user;
a first execution module: the system is used for executing the transaction operation if the limit of the target node can meet the transaction operation;
a second execution module: if the quota of the target node cannot meet the transaction operation, applying for a corresponding quota to a quota control center, adding the applied quota to the total quota of the target node after the application is successful, and then executing the transaction operation;
wherein the target node selection module comprises:
leaf node search unit: the node is used for searching nodes meeting the transaction range condition in leaf nodes of the node tree, and if the nodes are found, the nodes are selected as target nodes; if not, entering the following steps;
a non-leaf node search unit: the method comprises the steps that non-leaf nodes meeting transaction range conditions are searched in child nodes, and if the non-leaf nodes are found, the non-leaf nodes are selected as target nodes; if not, entering the following steps;
a root node search unit: and the method is used for judging whether the root node meets the transaction range condition, and if so, selecting the root node as a target node.
5. The apparatus of claim 4, further comprising:
the residual amount calculating module: the system is used for deducting the credit consumed for executing the transaction operation from the total credit of the target node to obtain remaining credit;
the remaining amount recording module: the system is used for recording the surplus limit into a distribution log of the target node;
a settlement limit calculation module: the system is used for calculating the settlement limit of the account according to the distribution log after the set time is reached;
a balance updating module: the account is used for updating the account amount according to the settlement amount;
a balance sending module: and the account management server is used for sending the updated quota of the account to the quota control center.
6. The apparatus of claim 4 or 5, wherein the second execution module comprises:
the credit application information sending unit: the system comprises a node tree, a limit control center and a limit application server, wherein the limit application server is used for sending limit application information to the limit control center and applying for a corresponding limit from a limit pool corresponding to the node tree;
a locking unit: the system is used for locking the quota pool, so that the quota control center refuses to respond to other quota application information after receiving the other quota application information of the user;
a feedback information receiving unit: receiving information of successful credit application;
an unlocking unit: and unlocking the limit pool, so that the limit control center can respond to the other limit application information after receiving the other limit application information.
7. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method of any of claims 1-3.
8. A computer-readable medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method according to any one of claims 1 to 3.
CN201810263596.2A 2018-03-28 2018-03-28 Quota management method and device Active CN108446975B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810263596.2A CN108446975B (en) 2018-03-28 2018-03-28 Quota management method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810263596.2A CN108446975B (en) 2018-03-28 2018-03-28 Quota management method and device

Publications (2)

Publication Number Publication Date
CN108446975A CN108446975A (en) 2018-08-24
CN108446975B true CN108446975B (en) 2022-01-14

Family

ID=63197578

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810263596.2A Active CN108446975B (en) 2018-03-28 2018-03-28 Quota management method and device

Country Status (1)

Country Link
CN (1) CN108446975B (en)

Families Citing this family (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110335033A (en) * 2019-07-09 2019-10-15 中国工商银行股份有限公司 Limit processing method and system
CN110599185A (en) * 2019-07-30 2019-12-20 上海数据交易中心有限公司 Account synchronization method and device, data transaction system, storage medium and terminal
CN110648129A (en) * 2019-08-20 2020-01-03 上海数据交易中心有限公司 Quota control method and device for batch distribution system, storage medium and terminal
CN111429125B (en) * 2020-03-17 2024-04-19 京东科技控股股份有限公司 Account management method and device, storage medium and electronic equipment
CN111461692A (en) * 2020-04-17 2020-07-28 支付宝(杭州)信息技术有限公司 Data processing method and device
CN111667360A (en) * 2020-06-19 2020-09-15 中信银行股份有限公司 User limit information management method and device, electronic equipment and storage medium
CN111798302A (en) * 2020-06-29 2020-10-20 平安普惠企业管理有限公司 Quota updating method and device based on micro service, electronic equipment and storage medium
CN111784510B (en) * 2020-07-07 2021-03-19 北京开科唯识技术股份有限公司 Account checking method and device
CN111915429B (en) * 2020-08-11 2021-05-14 北京开科唯识技术股份有限公司 Account checking method and device
CN112085486B (en) * 2020-08-24 2024-01-30 宝付网络科技(上海)有限公司 Method and system for improving funds distribution capacity
CN112395091A (en) * 2020-11-24 2021-02-23 上海商汤智能科技有限公司 Cloud service request response method and device, electronic equipment and storage medium
CN112365345B (en) * 2021-01-14 2021-04-13 北京江融信科技有限公司 DAG-based dynamic control method and system for multi-type credit line
CN113052674B (en) * 2021-03-15 2024-06-25 平安银行股份有限公司 Method for managing credit, electronic device, computer equipment and storage medium
CN114971611B (en) * 2022-05-07 2024-08-13 中国工商银行股份有限公司 Hot spot balance processing method and device for account, processor and electronic equipment

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9336222B2 (en) * 2011-08-05 2016-05-10 Netapp, Inc. Creation and access of quota trees in a file system
CN106327330A (en) * 2016-08-17 2017-01-11 深圳市金证科技股份有限公司 Method and system for multiple orders to share account fund
CN107026897A (en) * 2017-02-20 2017-08-08 阿里巴巴集团控股有限公司 A kind of methods, devices and systems of data processing
CN107463593A (en) * 2016-12-13 2017-12-12 阿里巴巴集团控股有限公司 Stock reduces method and its equipment
CN107679983A (en) * 2017-10-20 2018-02-09 京北方信息技术股份有限公司 Amount tree constructing method and device, amount take route inspection method and apparatus

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9336222B2 (en) * 2011-08-05 2016-05-10 Netapp, Inc. Creation and access of quota trees in a file system
CN106327330A (en) * 2016-08-17 2017-01-11 深圳市金证科技股份有限公司 Method and system for multiple orders to share account fund
CN107463593A (en) * 2016-12-13 2017-12-12 阿里巴巴集团控股有限公司 Stock reduces method and its equipment
CN107026897A (en) * 2017-02-20 2017-08-08 阿里巴巴集团控股有限公司 A kind of methods, devices and systems of data processing
CN107679983A (en) * 2017-10-20 2018-02-09 京北方信息技术股份有限公司 Amount tree constructing method and device, amount take route inspection method and apparatus

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
额度授信管理系统的设计与实现;蔡秀娟;《赤峰学院学报(自然科学版)》;20141231;第30卷(第12期);全文 *

Also Published As

Publication number Publication date
CN108446975A (en) 2018-08-24

Similar Documents

Publication Publication Date Title
CN108446975B (en) Quota management method and device
US11907876B2 (en) Autonomic discrete business activity management method
RU2628902C2 (en) Coordination mechanism for cloud choice
US7958026B2 (en) Hierarchical transaction filtering
US20080162377A1 (en) System and method of managing cash and suggesting transactions in a multi-strategy portfolio
US20110119312A1 (en) System and method for automated scalability of n-tier computer applications
CN109035028B (en) Intelligent consultation strategy generation method and device, electronic equipment and storage medium
US20220237599A1 (en) Efficient, accurate, and secure digital asset conversions for real-time funding of merchant transactions
US20190378183A1 (en) Systems and methods for improving invoice management using enhanced analytical insight
US20220337529A1 (en) System and Method for Maximizing Resource Credits Across Shared Infrastructure
US10417059B1 (en) Staged application programming interface
CN103748602A (en) Paying non-settlement transactions
US20070100685A1 (en) Portfolio infrastructure management method and system
US11188981B1 (en) Identifying matching transfer transactions
CN114140252A (en) Resource allocation method of target object and related device
CN113379523A (en) Bill generation method, device, medium and electronic equipment
CN117726464A (en) Account checking method, account checking system and related equipment
CN111127224B (en) Information processing method, information processing device, electronic equipment and storage medium
US11068947B2 (en) Machine learning-based dynamic outcome-based pricing framework
US11222026B1 (en) Platform for staging transactions
Ramuka Data analytics with Google Cloud platform
EP2413272A1 (en) Capturing and processing data generatid in an erp interim phase
US20220366501A1 (en) Systems and Methods for Modeling Future Value
CN111429125B (en) Account management method and device, storage medium and electronic equipment
CN114186267A (en) Virtual asset data processing method and device and computer readable storage medium

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
GR01 Patent grant
GR01 Patent grant