CN113626458A - High-concurrency data updating method, device, equipment and computer storage medium - Google Patents

High-concurrency data updating method, device, equipment and computer storage medium Download PDF

Info

Publication number
CN113626458A
CN113626458A CN202110955497.2A CN202110955497A CN113626458A CN 113626458 A CN113626458 A CN 113626458A CN 202110955497 A CN202110955497 A CN 202110955497A CN 113626458 A CN113626458 A CN 113626458A
Authority
CN
China
Prior art keywords
data
database
sub
stock
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110955497.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.)
China Mobile Communications Group Co Ltd
MIGU Digital Media Co Ltd
MIGU Culture Technology Co Ltd
Original Assignee
China Mobile Communications Group Co Ltd
MIGU Digital Media Co Ltd
MIGU Culture 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 China Mobile Communications Group Co Ltd, MIGU Digital Media Co Ltd, MIGU Culture Technology Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN202110955497.2A priority Critical patent/CN113626458A/en
Publication of CN113626458A publication Critical patent/CN113626458A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2308Concurrency control
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24552Database cache management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor

Abstract

The embodiment of the invention relates to the technical field of data processing, and discloses a method, a device, equipment and a storage medium for updating high-concurrency data, wherein the method comprises the following steps: acquiring a data processing request; the data processing request comprises a target object identifier and operation information; inquiring in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of the target database; each sub-stock data is stored in a corresponding target database and is synchronized to a cache in advance; determining a database to be updated from a target database according to the operation information and all sub-stock data; and updating the database to be updated according to the operation information and the database identifier of the database to be updated. Through the mode, the embodiment of the invention improves the processing efficiency of high concurrent data.

Description

High-concurrency data updating method, device, equipment and computer storage medium
Technical Field
The embodiment of the invention relates to the technical field of data processing, in particular to a method, a device, equipment and a computer storage medium for updating high-concurrency data.
Background
In high concurrent environments such as killing in seconds or drawing a lottery, data such as account stock data and commodity stock often need to be updated.
In the prior art, when data is updated, the data is generally updated in a traditional database reading and writing mode, which causes the problem of row locking; in addition, when a plurality of databases are used for storing data in a distributed manner to disperse update pressure of the databases, the database selection strategy adopted in the prior art cannot reduce the total number of times of reading and writing operations on the databases, and the problem results in low efficiency of the existing high-concurrency data update processing.
Disclosure of Invention
In view of the foregoing problems, embodiments of the present invention provide a method, an apparatus, a device, and a computer storage medium for high-concurrency data update, which are used to solve the problem in the prior art that the efficiency of data update processing is low.
According to an aspect of an embodiment of the present invention, there is provided a high concurrency data updating method, including:
acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
inquiring in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; the sub-stock data are stored in a corresponding target database and are synchronized to the cache in advance;
determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and updating the database to be updated according to the operation information and the database identifier of the database to be updated.
In an alternative, the operation information includes decrement data; the decrement data is used for determining data to be decremented for the target stock data; the method further comprises the following steps:
determining target total stock data according to all the sub stock data;
respectively comparing the decrement data with the target total stock data and the sub stock data;
determining the sub-inventory data larger than the decrement data as optional sub-inventory data when the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data;
determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight;
and determining the target database storing the sub-stock data to be updated as the database to be updated.
In an optional manner, the method further comprises:
determining whether the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
when the decrement data is smaller than the target total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated;
updating the sub-stock data stored in the main database to be updated to zero;
updating the decrement data according to the maximum sub-stock data;
respectively comparing the updated decrement data with the target total stock data and the sub stock data;
after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
In an optional manner, the operation information includes incremental data; the incremental data is used for determining data to be added aiming at the target stock data; the method further comprises the following steps:
respectively calculating the difference value between each sub-stock data and a preset stock data threshold value;
and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
In an optional manner, the method further comprises:
determining stock data change records according to the operation information;
inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated;
and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
In an optional manner, the method further comprises:
when the current time is in a high concurrency period, determining the total number of records of the stock data change records;
when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information;
and updating the sub-stock data in the database to be updated according to the change merging information.
In an optional manner, the method further comprises:
when at least two sub-stock data are smaller than a preset stock data threshold, determining a target database in which the sub-stock data smaller than the stock data threshold are stored as a database to be merged;
determining a main database to be merged and at least one slave database to be merged from the databases to be merged;
and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
According to another aspect of the embodiments of the present invention, there is provided a high concurrency data updating apparatus, including:
the acquisition module is used for acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
the query module is used for querying in the cache according to the target object identifier and determining target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; the sub-stock data are stored in a corresponding target database and are synchronized to the cache in advance;
the determining module is used for determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and the updating module is used for updating the database to be updated according to the operation information and the database identifier of the database to be updated.
According to another aspect of the embodiments of the present invention, there is provided a high concurrency data updating apparatus, including:
the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is configured to store at least one executable instruction that causes the processor to perform operations as the high concurrency data update method.
According to yet another aspect of the embodiments of the present invention, there is provided a computer-readable storage medium having at least one executable instruction stored therein, the executable instruction causing a high-concurrency data updating apparatus to perform the operations of the high-concurrency data updating method.
The embodiment of the invention obtains the data processing request; the data processing request comprises a target object identifier and operation information, and then the data processing request is inquired in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; each sub-stock data is stored in a corresponding target database and is synchronized to a cache in advance; determining a database to be updated from a target database according to the operation information and all sub-stock data; and finally, updating the database to be updated according to the operation information and the identifier of the database to be updated.
The method and the device are different from the problem that the total times of database operation are large and the method and the device are not suitable for high concurrency environment due to the fact that row locking exists and concurrency pressure is concentrated on a certain database during data updating in the prior art, the target stock data can be stored in a distributed mode into a plurality of sub stock data in a cache, the target database needing to be operated is determined according to the sub stock data and operation information, accordingly, pressure of frequent calling of the database during data updating in the high concurrency environment is reduced, the database to be updated is reasonably selected according to the quantity relation between the current operation information and the sub stock data in each database, and accordingly, efficiency of high concurrency data updating is improved.
The foregoing description is only an overview of the technical solutions of the embodiments of the present invention, and the embodiments of the present invention can be implemented according to the content of the description in order to make the technical means of the embodiments of the present invention more clearly understood, and the detailed description of the present invention is provided below in order to make the foregoing and other objects, features, and advantages of the embodiments of the present invention more clearly understandable.
Drawings
The drawings are only for purposes of illustrating embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a schematic flow chart illustrating a high-concurrency data updating method provided by an embodiment of the present invention;
FIG. 2 is a schematic structural diagram of a high concurrency data update system provided by an embodiment of the present invention;
FIG. 3 is a schematic structural diagram of a high concurrency data update apparatus provided by an embodiment of the present invention;
fig. 4 is a schematic structural diagram illustrating a high-concurrency data update device according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the invention are shown in the drawings, it should be understood that the invention can be embodied in various forms and should not be limited to the embodiments set forth herein.
Fig. 1 is a flowchart illustrating a method for updating high-concurrency data according to an embodiment of the present invention, which may be applied to the high-concurrency data updating system illustrated in fig. 2.
Fig. 2 is a schematic structural diagram illustrating a high concurrency data update system according to an embodiment of the present invention. As shown in fig. 2, the system includes a client, a routing layer, a server cluster, a database proxy, a data storage layer, and a background service.
The client is used for sending a data processing request to the routing layer; the routing layer is used for receiving the data processing request, inquiring in the cache according to the request, determining and issuing a service request to the server cluster, wherein the service request comprises routing information and operation information of the database to be updated; the server cluster receives the service request, performs logic processing, and calls a database agent to access the database to be updated; the database agent converts the operation information into stock data change records and inserts the stock data change records into a database to be updated; and the background service merges the stock data change records in the database to be updated according to a preset merging strategy, so that the data updating is completed. As shown in fig. 1, the method comprises the steps of:
step 101: and acquiring a data processing request.
In one embodiment of the invention, the data processing request may be a request sent by a user in a high-concurrency scenario such as killing by seconds, robbery, and the like. As shown in fig. 2, the data processing request may be sent by a client and received by the routing layer, and the specific client may be an application corresponding to a lottery or credit platform.
The data processing request comprises target object identification and operation information. The target object identification is used for specifically identifying a target object, the target object is any one of a plurality of selectable objects in the high concurrency scene, and the selectable objects can be users, accounts, commodities, resources and the like.
The operation information indicates operation information of stock data corresponding to the attribute of the target object, such as various operation types of inquiry, modification, and the like, and operation parameters under the operation types, such as modified values, and the like. The attribute may be countable attributes such as available traffic or telephone charges of the user, points or exchange coins of the account, inventory of goods or resources, and the like. The stock data refers to the quantity statistical data corresponding to the current attribute, such as telephone charge balance, integral quantity, stock quantity and the like.
Step 102: and inquiring in a cache according to the target object identifier to determine target stock data.
In one embodiment of the invention, the cache is stored in the data store layer in FIG. 2, and may be a common non-relational database such as redis, MongoDB, and the like. The cache stores a plurality of selectable inventory data corresponding to the selectable object identifier in step 101, and determines the selectable inventory data corresponding to the target object identifier as target cache data. The operation of querying in the cache may be performed by the routing layer in fig. 2.
In yet another embodiment of the present invention, the target inventory data includes a plurality of sub-inventory data and a database identification of the target database, wherein each of the sub-inventory data is stored in the corresponding target database.
The target databases are stored in the storage layer shown in fig. 2, the database identifiers are used for specifically distinguishing the target databases, specifically, the database identifiers may be routing information of the target databases, and the database agent shown in fig. 2 may call and operate the corresponding target databases according to the routing information.
Dividing the target stock data into a plurality of sub stock data, so that the target stock data are stored in each target database in a distributed manner, one target database correspondingly stores at least one sub stock data, and the sub stock data in each target database are combined to obtain the target stock data.
In yet another embodiment of the present invention, a target inventory data may be in the form of a key-value pair in the cache, the key-value pair being defined as follows: (Object _ ID, list (B));
wherein Object _ ID represents a target Object identification, list (B) represents target stock quantity data,
in yet another embodiment of the present invention, list (B) is data for a list phenotype, which can be expressed as:
list(B)=[route1/B1,...,routen/Bn];
where n represents the nth target database, routenRepresenting database routing information corresponding to the nth target database, BnRepresenting sub-inventory data stored in the nth target database;
in still another embodiment of the present invention, when a plurality of sub-inventory data are stored in the target database, BnMay also include Bn1、Bn2、...、Bnm,Bn1、Bn2、...、BnmRespectively corresponding to the mth sub-stock data stored in the nth target database.
In yet another embodiment of the present invention, the sub-inventory data is also synchronized in advance from each target database to the cache.
The synchronization process may be to update the cache according to the target database at regular time.
In yet another embodiment of the present invention, it may also be that the server cluster in fig. 2 reads out the sub-inventory data from the target database and writes the sub-inventory data into the cache after starting.
Before writing, the server cluster inquires stock data corresponding to the target object identifier in the cache, if the stock data are inquired, whether the inquired data are the same as sub-stock data in each target database is judged, and if the inquired data are not the same as the sub-stock data in each target database, the cache is updated; and if the data is not inquired, directly inserting the sub-stock data into the cache.
Considering that the reading and writing performance of the cache of the non-relational database is faster than that of the relational database, after the data operation request is received, the target stock data is directly obtained from the cache to respond, the data request processing efficiency under the concurrent environment can be improved, and the user experience is improved.
In another embodiment of the present invention, in addition to updating the cache every time the server cluster is started or at regular time, in order to ensure the accuracy of the data in the cache, the cache may be updated under the following condition, on one hand, when the data is first queried, because there is no relevant data in the cache, when the balance is first queried, the routing layer may select a target database to send a call request, and the target database returns the sub-inventory data stored therein, and simultaneously calls the services of other target databases to obtain the corresponding sub-inventory quantity. And after all the target databases are called, determining the sum of all the sub-stock data as the target total stock data, writing the target total stock data into a cache, and returning the target total stock data to the client.
On the other hand, when the operation returned by the target database is wrong, it can be characterized that the data in the cache is not updated in time, so that the data in the cache is inconsistent with the data in the target database. Among them, the operation error may be, for example, a sub-inventory data or target inventory data deficiency so as to reduce failure, a database call failure, or a database connection timeout.
In a further embodiment of the present invention, in consideration of the limitation of the storage amount of the cache, the validity period of the target inventory data in the cache may be set, and the data exceeding the validity period in the cache may be deleted periodically.
Step 103: and determining a database to be updated from the target database according to the operation information and all the sub stock data.
In one embodiment of the invention, the operation information may include operation types of the target stock data, and the operation types may include data query, data update, wherein the data update may include data increase, data decrease, data rollback and the like.
In another embodiment of the present invention, when the operation type is data query, the target total inventory data in the calculation can be directly calculated according to the target inventory data in the cache, and the target total inventory data is returned to the user without calling the target database.
In one embodiment of the invention, when the operation type is data update, the operation information further includes decrement data; the decrement data refers to a stock value that needs to be decremented from the target stock data, and when the target stock data is 100 and the decrement data is 20, the target stock data after data update should be 100-20 to 80.
Step 103 further comprises:
step 1031: and determining target total stock data according to all the sub stock data.
In one embodiment of the invention, the sum of all sub-inventory data is determined as the target total inventory data, for example, if there are 3 optional sub-inventory data B1B2 and B3, wherein B1=10、B2=25、B315, the target total stock data is 10+25+15 to 50.
Step 1032: and respectively comparing the decrement data with the target total stock data and the sub stock data.
In one embodiment of the present invention, the magnitude relationship between the decrement data and the target total stock amount data and the magnitude relationship between the decrement data and each sub-stock amount data are determined.
Therefore, whether the current target total stock data can be deducted from the decrement data or not is determined, and how many sub stock data need to be operated under the condition that the current target total stock data can be deducted, and the like are determined, so that a specific database calling strategy is determined, the concurrent access pressure on a single target database is reduced, the calling times of the whole target database are reduced as much as possible, and the high concurrent data processing efficiency is improved.
Step 1033: when the decrement data is smaller than the target total stock data and smaller than at least one of the sub-stock data, the sub-stock data larger than the decrement data is determined as optional sub-stock data.
In one embodiment of the present invention, when the decrement data is smaller than the target total stock amount data and smaller than the at least one sub-stock amount data, it indicates that the current target total stock amount data can be decremented while the decrement data can be decremented by the presence of a single sub-stock amount data.
Therefore, the sub-stock amount data on which the stock amount deduction operation is performed is determined from the sub-stock amount data larger than the decrement data.
Step 1034: and determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data.
In one embodiment of the invention, the ratio of all selectable sub-inventory data to the target total inventory data is determined as its corresponding calling weight.
For example, there are 3 optional sub-inventory data B1B2 and B3, wherein B1=10、B2=20、B3If 30, then B1The corresponding call weight is 10/50 ═ 0.2, and so on for other sub-inventory data.
Step 1035: and determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight.
In one embodiment of the invention, a weighted random number is generated according to the calling weight, all the calling weights are traversed, and the selectable sub-stock data corresponding to the calling weight of which the first is greater than the weighted random number is determined as the sub-stock data to be updated.
Therefore, compared with the routing algorithm without random weights and fixed weights in the prior art, the method and the device for selecting the routing algorithm determine the corresponding calling weights according to the sub-inventory data, and can distribute the inventory reduction requests to the sub-account services more evenly and reasonably, so that the low efficiency that a plurality of sub-inventory data are small, the reduction of the reduced data cannot be finished, and the data updating can be finished by calling a plurality of different target databases is avoided.
Step 1036: and determining the target database storing the sub-stock data to be updated as the database to be updated.
In yet another embodiment of the present invention, before step 1033, further comprising:
step 1037: determining whether the decrement data is smaller than the target total stock data and smaller than at least one of the sub stock data.
The decrement data is compared with the target total stock data and each sub stock data respectively, wherein the comparison result with the target total stock data is used for determining whether the current data reduction operation can be successfully executed, and the comparison result with each sub stock data is used for determining which one or more sub stock data are updated, so that the retrieval operation of the target stock data can be completed under the condition that the number of times of database operation is the minimum.
Step 1038: and when the decrement data is smaller than the target total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated.
In an embodiment of the present invention, when the decrement data is smaller than the target total stock amount data, that is, when the decrement data is larger than all of the sub stock amount data, it indicates that none of the sub stock amount data can individually complete the decrement data, and at this time, it is necessary to operate a plurality of sub stock amount data to jointly complete the decrement data.
In order to reduce the number of sub-stock data to be operated, the decrement data is first subtracted from the maximum sub-stock data to reduce the number of remaining operations to the maximum.
Step 1039: and updating the sub-stock data stored in the main database to be updated to zero.
Step 1040: and updating the decrement data according to the maximum sub-stock data.
In one embodiment of the present invention, the difference between the decrement data and the maximum sub-stock data is determined as the updated decrement data.
Step 1041: after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
In an embodiment of the present invention, after the decrement data is updated, it is determined again whether the updated decrement data is smaller than the target total stock data and smaller than at least one of the sub-stock data, where the decrement data being smaller than the target total stock data indicates that the decrement operation of the data can be completed, and the decrement data being smaller than the at least one sub-stock data indicates that the decrement operation can be completed only by updating one sub-stock data, and the plurality of sub-stock data do not need to be updated, and at this time, step 1033 and the subsequent steps can be executed, that is, one of the plurality of sub-stock data larger than the decrement data is determined to be updated.
In addition to deducting the target stock data, the target stock data can be increased in combination with actual business requirements, so that in a further embodiment of the invention, when the operation type is data updating, the operation information can also be incremental data; the increment data is used for determining data to be added aiming at the target stock quantity data, namely corresponding to decrement data, the increment data refers to a quantity value which needs to be added on the basis of the target stock quantity data, and if the target stock quantity data is 100 and the increment data is 30, the target stock quantity data after data updating is 100+ 30-130.
Step 103 further comprises:
step 1042: and respectively calculating the difference value between each sub-stock data and a preset stock data threshold value.
In an embodiment of the present invention, the inventory data threshold is used to represent an average level of sub-inventory data, and may be specifically determined according to the historical data operation information, the target total inventory, and the number of target databases.
Step 1043: and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
The method is different from the method for data deduction, the situation that stock data is insufficient or needs to be completed for multiple times may exist, when data increase is performed, the purpose of operating any target database can be achieved, however, if a task of data increase is distributed to one or a plurality of target databases, the size of sub stock data in each target database is unbalanced, and even the situation that a plurality of sub stock data are smaller than a stock data threshold value occurs, so that the subsequent data deduction operation needs to be completed by multiple database reading and writing.
Therefore, in one embodiment of the present invention, the distance between each sub-stock data and the stock data threshold is calculated, and the target database in which the sub-stock data with the smallest distance is stored is determined as the database to be updated, so that when the target stock data is increased, one sub-stock data is preferentially increased until the target stock data is greater than the stock data threshold, and then the rest sub-stock data is sequentially increased.
Step 104: and updating the database to be updated according to the operation information.
In consideration of the fact that generally a single row is adopted for updating a database in the prior art to record target stock data, when updating is performed, the row needs to be firstly indexed, a data lock is added, then writing is performed, and the data lock is released, so that the operation efficiency is low, the condition of the database row lock is easy to occur, the performance of the database is reduced, even the database connection is overtime, and the high-concurrency request cannot be responded.
In an embodiment of the present invention, a more efficient insertion operation mode may be adopted when updating the database to be updated according to the operation information, that is, a data change record corresponding to the operation information is inserted into the last bit of the data table of the inventory data in the database to be updated, the inserted records are merged at intervals of a preset time or according to a certain recorder merging strategy, so as to obtain the data change information after clearing, and the sub-inventory data in the database to be updated is updated according to the data change information.
Thus, in yet another embodiment of the present invention, step 104 further comprises:
step 1044: and determining the stock data change record according to the operation information.
In one embodiment of the present invention, each piece of operation information corresponds to a change record of inventory data, and the change record of inventory data includes change values, such as +10, -10, +30, etc., and corresponding change time.
Step 1045: and inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated.
In an embodiment of the invention, the database to be updated is accessed according to the database identifier of the database to be updated, and the stock data change record is inserted into the last bit of the data table of the sub-stock data stored in the database to be updated.
In yet another embodiment of the present invention, steps 1041-1042 may be accomplished by a database proxy as shown in FIG. 2, wherein the database proxy may include mycat or the like.
Step 1046: and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
In an embodiment of the present invention, the preset merging strategy includes merging every preset time interval in the non-high concurrency period, for example, merging every 1 hour, and may further include determining a merging timing according to the total number of records of the inventory data change record in the high concurrency period.
In another embodiment of the present invention, merging the inventory data change records includes counting all inventory data change records to obtain change merge information, and summing the sub-inventory data and the change merge information, thereby completing the update of the database to be updated.
In yet another embodiment of the present invention, after the merging of the data inventory change records is completed and the updated sub-inventory data is obtained, all the inventory data change records in the database to be updated are deleted.
In yet another embodiment of the present invention, the merging of inventory data change records may be performed by a background service in FIG. 2.
Thus, in yet another embodiment of the present invention, step 1046 further comprises:
step 461: determining a total number of records of the inventory data change record when the current time is in a high concurrency period.
In an embodiment of the present invention, the high concurrency period may be determined according to the number of historical operation requests and the number of database updates corresponding to each period.
Step 462: and when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information.
In one embodiment of the invention, change information in the stock data change records is counted to obtain change merging information. If +10, -10, +30 is counted to obtain +30 as the change merge information.
Step 463: and updating the sub-stock data in the database to be updated according to the change merging information.
In still another embodiment of the present invention, the sub-inventory data and the change merge information are determined as updated sub-inventory data.
In another embodiment of the present invention, in order to avoid a plurality of small amounts of sub-inventory data after the database update, so that it is inefficient to call a plurality of databases when performing a reduction operation on the target inventory data, after step 104, the method may further include:
step 401: and when at least two sub-stock data are smaller than a preset stock data threshold value, determining a target database in which the sub-stock data smaller than the stock data threshold value are stored as a database to be merged.
In an embodiment of the present invention, the inventory data threshold is the one described in step 1042, and is not described again.
Step 402: and determining a main database to be merged and at least one slave database to be merged from the databases to be merged.
In one embodiment of the present invention, the databases to be merged are sorted according to the descending order of the sizes of the stored sub-stock data, the database to be merged with the largest sub-stock data is determined as the master database to be merged, the cumulative sum of the sub-stock data stored in the remaining databases to be merged in the sequence is calculated in an accumulation manner until the sum of the cumulative sum and the sub-stock data of the master database to be merged is greater than the stock data threshold, and each database to be merged corresponding to the cumulative sum is determined as the slave database to be merged.
Step 403: and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
In one embodiment of the present invention, the sub-inventory data stored in each of the slave databases to be merged is updated to zero, and the sum of all the sub-inventory data stored in the slave databases to be merged is added to the sub-inventory data stored in the master database to be merged.
Different from the problem that row locking or concurrency pressure occurs on a certain database and is not suitable for a high concurrency environment in the prior art, the high concurrency data updating method provided by the embodiment of the invention can reduce the pressure frequently called by the database in the data updating under the high concurrency environment by distributively storing the target stock data as a plurality of sub stock data in the cache and determining the target database needing to be operated according to the sub stock data and the operation information, and reasonably select the database to be updated according to the quantity relationship between the current operation information and the sub stock data in each database, thereby improving the efficiency of high concurrency data updating.
Fig. 3 is a schematic structural diagram illustrating a high-concurrency data updating apparatus according to an embodiment of the present invention. As shown in fig. 3, the apparatus 200 includes: an acquisition module 201, a query module 202, a determination module 203, and an update module 204, wherein,
an obtaining module 201, configured to obtain a data processing request; the data processing request comprises a target object identifier and operation information;
the query module 202 is configured to query the cache according to the target object identifier, and determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; the sub-stock data are stored in a corresponding target database and are synchronized to the cache in advance;
a determining module 203, configured to determine a database to be updated from the target database according to the operation information and all the sub-stock data;
and the updating module 204 is configured to update the database to be updated according to the operation information and the database identifier of the database to be updated.
In an alternative, the operation information includes decrement data; the decrement data is used for determining data to be decremented for the target stock data; the determining module 203 is further configured to:
determining target total stock data according to all the sub stock data;
respectively comparing the decrement data with the target total stock data and the sub stock data;
determining the sub-inventory data larger than the decrement data as optional sub-inventory data when the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data;
determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight;
and determining the target database storing the sub-stock data to be updated as the database to be updated.
In an optional manner, the determining module 203 is further configured to:
determining whether the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
when the decrement data is smaller than the target total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated;
updating the sub-stock data stored in the main database to be updated to zero;
updating the decrement data according to the maximum sub-stock data;
after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
In an optional manner, the operation information includes incremental data; the determining module 203 is further configured to:
respectively calculating the difference value between each sub-stock data and a preset stock data threshold value;
and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
In an optional manner, the update module 204 is further configured to:
determining stock data change records according to the operation information;
inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated;
and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
In an optional manner, the update module 204 is further configured to:
when the current time is in a high concurrency period, determining the total number of records of the stock data change records;
when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information;
and updating the sub-stock data in the database to be updated according to the change merging information.
In an optional manner, the update module 204 is further configured to:
when at least two sub-stock data are smaller than a preset stock data threshold, determining a target database in which the sub-stock data smaller than the stock data threshold are stored as a database to be merged;
determining a main database to be merged and at least one slave database to be merged from the databases to be merged;
and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
Different from the problem that row locking or concurrency pressure occurs on a certain database and is not suitable for a high concurrency environment in the prior art, the high concurrency data updating device provided by the embodiment of the invention can store target stock data in a distributed manner as a plurality of sub-stock data in a cache, and determines the target database needing to be operated according to the sub-stock data and operation information, so that the pressure frequently called by the database in the data updating process in the high concurrency environment is reduced, the selection of the database to be updated is reasonably carried out according to the quantity relationship between the current operation information and the sub-stock data in each database, and the efficiency of updating the high concurrency data is improved.
Fig. 4 is a schematic structural diagram of a high-concurrency data updating device according to an embodiment of the present invention, and a specific embodiment of the present invention does not limit a specific implementation of the high-concurrency data updating device.
As shown in fig. 4, the high concurrency data update apparatus may include: a processor (processor)302, a communication Interface 304, a memory 306, and a communication bus 308.
Wherein: the processor 302, communication interface 304, and memory 306 communicate with each other via a communication bus 308. A communication interface 304 for communicating with network elements of other devices, such as clients or other servers. The processor 302, configured to execute the program 310, may specifically perform the relevant steps in the embodiment described above for the highly concurrent data updating method.
In particular, program 310 may include program code comprising computer-executable instructions.
The processor 302 may be a central processing unit CPU, or an Application Specific Integrated Circuit (ASIC), or one or more Integrated circuits configured to implement an embodiment of the present invention. The high concurrency data updating device comprises one or more processors which can be the same type of processor, such as one or more CPUs; or may be different types of processors such as one or more CPUs and one or more ASICs.
And a memory 306 for storing a program 310. Memory 306 may comprise high-speed RAM memory and may also include non-volatile memory (non-volatile memory), such as at least one disk memory.
Specifically, the program 310 may be invoked by the processor 302 to cause the highly concurrent data update device to perform the following operations:
acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
inquiring in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; the sub-stock data are stored in a corresponding target database and are synchronized to the cache in advance;
determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and updating the database to be updated according to the operation information and the database identifier of the database to be updated.
In an alternative, the operation information includes decrement data; the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
determining target total stock data according to all the sub stock data;
respectively comparing the decrement data with the target total stock data and the sub stock data;
determining the sub-inventory data larger than the decrement data as optional sub-inventory data when the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data;
determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight;
and determining the target database storing the sub-stock data to be updated as the database to be updated.
In an alternative manner, the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
determining whether the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
when the decrement data is smaller than the target total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated;
updating the sub-stock data stored in the main database to be updated to zero;
updating the decrement data according to the maximum sub-stock data;
after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
In an optional manner, the operation information includes incremental data; the incremental data is used for determining data to be added aiming at the target stock data; the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
respectively calculating the difference value between each sub-stock data and a preset stock data threshold value;
and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
In an alternative manner, the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
determining stock data change records according to the operation information;
inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated;
and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
In an alternative manner, the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
when the current time is in a high concurrency period, determining the total number of records of the stock data change records;
when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information;
and updating the sub-stock data in the database to be updated according to the change merging information.
In an alternative manner, the program 310 is invoked by the processor 302 to cause the high concurrency data update device to:
when at least two sub-stock data are smaller than a preset stock data threshold, determining a target database in which the sub-stock data smaller than the stock data threshold are stored as a database to be merged;
determining a main database to be merged and at least one slave database to be merged from the databases to be merged;
and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
Different from the problem that row locking or concurrency pressure occurs on a certain database and is not suitable for a high concurrency environment in the prior art, the high concurrency data updating device provided by the embodiment of the invention can store target stock data in a distributed manner as a plurality of sub-stock data in a cache, and determines the target database needing to be operated according to the sub-stock data and operation information, so that the pressure frequently called by the database in the data updating process in the high concurrency environment is reduced, the selection of the database to be updated is reasonably carried out according to the quantity relationship between the current operation information and the sub-stock data in each database, and the efficiency of high concurrency data updating is improved.
An embodiment of the present invention provides a computer-readable storage medium, where the storage medium stores at least one executable instruction, and when the executable instruction runs on a high concurrent data updating apparatus, the high concurrent data updating apparatus is enabled to execute a high concurrent data updating method in any method embodiment described above.
The executable instructions may be specifically configured to cause the high concurrency data update device to perform the following operations:
acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
inquiring in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; the sub-stock data are stored in a corresponding target database and are synchronized to the cache in advance;
determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and updating the database to be updated according to the operation information and the database identifier of the database to be updated.
In an alternative, the operation information includes decrement data; the decrement data is used for determining data to be decremented for the target stock data; the executable instructions may be specifically configured to cause the high concurrency data update device to perform the following operations:
determining target total stock data according to all the sub stock data;
respectively comparing the decrement data with the target total stock data and the sub stock data;
determining the sub-inventory data larger than the decrement data as optional sub-inventory data when the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data;
determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight;
and determining the target database storing the sub-stock data to be updated as the database to be updated.
In an alternative, the executable instructions cause the high concurrency data update device to:
determining whether the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
when the decrement data is smaller than the target' total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated;
updating the sub-stock data stored in the main database to be updated to zero;
updating the decrement data according to the maximum sub-stock data;
after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
In an optional manner, the operation information includes incremental data; the incremental data is used for determining data to be added aiming at the target stock data; the executable instructions cause the high concurrency data update device to:
respectively calculating the difference value between each sub-stock data and a preset stock data threshold value;
and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
In an alternative, the executable instructions cause the high concurrency data update device to:
determining stock data change records according to the operation information;
inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated;
and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
In an alternative, the executable instructions cause the high concurrency data update device to:
when the current time is in a high concurrency period, determining the total number of records of the stock data change records;
when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information;
and updating the sub-stock data in the database to be updated according to the change merging information.
In an alternative, the executable instructions cause the high concurrency data update device to:
when at least two sub-stock data are smaller than a preset stock data threshold, determining a target database in which the sub-stock data smaller than the stock data threshold are stored as a database to be merged;
determining a main database to be merged and at least one slave database to be merged from the databases to be merged;
and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
Different from the problem that row locking or concurrent pressure occurs on a certain database and is not suitable for a high-concurrency environment in the prior art, the computer storage medium provided by the embodiment of the invention can store target stock data in a distributed manner into a plurality of sub-stock data in the cache, and determines the target database needing to be operated according to the sub-stock data and the operation information, so that the pressure of frequent calling of the database in the high-concurrency environment is reduced, and the database to be updated is reasonably selected according to the quantity relationship between the current operation information and the sub-stock data in each database, so that the efficiency of high-concurrency data updating is improved.
The embodiment of the invention provides a high-concurrency data updating device, which is used for executing the high-concurrency data updating method.
Embodiments of the present invention provide a computer program, where the computer program can be called by a processor to enable a high concurrent data updating apparatus to execute a high concurrent data updating method in any of the above method embodiments.
Embodiments of the present invention provide a computer program product comprising a computer program stored on a computer-readable storage medium, the computer program comprising program instructions that, when run on a computer, cause the computer to perform the high concurrency data updating method in any of the above-mentioned method embodiments.
The algorithms or displays presented herein are not inherently related to any particular computer, virtual system, or other apparatus. Various general purpose systems may also be used with the teachings herein. The required structure for constructing such a system will be apparent from the description above. In addition, embodiments of the present invention are not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best mode of the invention.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the embodiments of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the invention and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be interpreted as reflecting an intention that: that the invention as claimed requires more features than are expressly recited in each claim.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. The modules or units or components of the embodiments may be combined into one module or unit or component, and may be divided into a plurality of sub-modules or sub-units or sub-components. All of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where at least some of such features and/or processes or elements are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names. The steps in the above embodiments should not be construed as limiting the order of execution unless specified otherwise.

Claims (10)

1. A method for high concurrency data update, the method comprising:
acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
inquiring in a cache according to the target object identifier to determine target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; each sub-stock data is stored in a corresponding target database and is synchronized to the cache in advance;
determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and updating the database to be updated according to the operation information and the database identifier of the database to be updated.
2. The method of claim 1, wherein the operational information includes decrement data; the decrement data is used for determining data to be decremented for the target stock data; determining a database to be updated from the target database according to the operation information and all the sub-stock data, wherein the determining comprises the following steps:
determining target total stock data according to all the sub stock data;
respectively comparing the decrement data with the target total stock data and the sub stock data;
determining the sub-inventory data larger than the decrement data as optional sub-inventory data when the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
determining the calling weight of the optional sub-stock data according to the optional sub-stock data and the target total stock data;
determining sub-stock data to be updated from the selectable sub-stock data according to the calling weight;
and determining the target database storing the sub-stock data to be updated as the database to be updated.
3. The method of claim 2, wherein prior to said determining said sub-inventory data that is greater than said decrement data as optional sub-inventory data, further comprising:
determining whether the decrement data is smaller than the target total inventory data and smaller than at least one of the sub-inventory data;
when the decrement data is smaller than the target total stock data and larger than all the sub stock data, determining a target database storing the largest sub stock data as a main database to be updated;
updating the sub-stock data stored in the main database to be updated to zero;
updating the decrement data according to the maximum sub-stock data;
after updating the decrement data, returning the decrement data to determine whether the decrement data is smaller than the target total stock data and smaller than at least one sub stock data and repeatedly executing until the decrement data is smaller than the target total stock data and smaller than at least one sub stock data.
4. The method of claim 1, wherein the operational information comprises incremental data; the incremental data is used for determining data to be added aiming at the target stock data; determining a database to be updated from the target database according to the operation information and all the sub-stock data, wherein the determining comprises the following steps:
respectively calculating the difference value between each sub-stock data and a preset stock data threshold value;
and determining the target database storing the sub-stock data with the minimum absolute value of the difference as the database to be updated.
5. The method according to claim 1, wherein the updating the database to be updated according to the operation information and the database identifier of the database to be updated comprises:
determining stock data change records according to the operation information;
inserting the stock data change record into the database to be updated according to the database identifier of the database to be updated;
and merging the stock data change records in the database to be updated according to a preset merging strategy so as to update the database to be updated.
6. The method according to claim 5, wherein the merging the inventory data change records in the target database according to a preset merging strategy to update the database to be updated comprises:
when the current time is in a high concurrency period, determining the total number of records of the stock data change records;
when the total number of records is greater than the threshold value of the number of records, merging the stock data change records to obtain change merging information;
and updating the sub-stock data in the database to be updated according to the change merging information.
7. The method according to claim 1, further comprising, after the updating the database to be updated according to the operation information and the database identifier of the database to be updated:
when at least two sub-stock data are smaller than a preset stock data threshold, determining a target database in which the sub-stock data smaller than the stock data threshold are stored as a database to be merged;
determining a main database to be merged and at least one slave database to be merged from the databases to be merged;
and merging the sub stock data stored in the slave database to be merged into the master database to be merged.
8. A high concurrency data update apparatus, the apparatus comprising:
the acquisition module is used for acquiring a data processing request; the data processing request comprises a target object identifier and operation information;
the query module is used for querying in the cache according to the target object identifier and determining target stock data; the target stock data comprises a plurality of sub stock data and a database identifier of a target database; each sub-stock data is stored in a corresponding target database and is synchronized to the cache in advance;
the determining module is used for determining a database to be updated from the target database according to the operation information and all the sub-stock data;
and the updating module is used for updating the database to be updated according to the operation information and the database identifier of the database to be updated.
9. A highly concurrent data update apparatus, comprising: the system comprises a processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface complete mutual communication through the communication bus;
the memory is configured to store at least one executable instruction that causes the processor to perform the operations of the high concurrency data update method of any one of claims 1-7.
10. A computer-readable storage medium having stored therein at least one executable instruction that, when run on a high concurrency data update device, causes the high concurrency data update device to perform the operations of the high concurrency data update method of any one of claims 1-7.
CN202110955497.2A 2021-08-19 2021-08-19 High-concurrency data updating method, device, equipment and computer storage medium Pending CN113626458A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110955497.2A CN113626458A (en) 2021-08-19 2021-08-19 High-concurrency data updating method, device, equipment and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110955497.2A CN113626458A (en) 2021-08-19 2021-08-19 High-concurrency data updating method, device, equipment and computer storage medium

Publications (1)

Publication Number Publication Date
CN113626458A true CN113626458A (en) 2021-11-09

Family

ID=78386743

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110955497.2A Pending CN113626458A (en) 2021-08-19 2021-08-19 High-concurrency data updating method, device, equipment and computer storage medium

Country Status (1)

Country Link
CN (1) CN113626458A (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012043338A (en) * 2010-08-23 2012-03-01 Nippon Telegr & Teleph Corp <Ntt> Cache management apparatus, cache management program and recording medium
CN106469166A (en) * 2015-08-18 2017-03-01 阿里巴巴集团控股有限公司 A kind of information processing method and device
CN107463693A (en) * 2017-08-11 2017-12-12 深圳乐信软件技术有限公司 A kind of data processing method, device, terminal and computer-readable recording medium
CN107463593A (en) * 2016-12-13 2017-12-12 阿里巴巴集团控股有限公司 Stock reduces method and its equipment
CN108874809A (en) * 2017-05-10 2018-11-23 北京京东尚科信息技术有限公司 Data processing method and device, electronic equipment, storage medium
CN109710698A (en) * 2018-12-28 2019-05-03 北京明朝万达科技股份有限公司 A kind of data assemblage method, device, electronic equipment and medium
CN109981774A (en) * 2019-03-22 2019-07-05 联想(北京)有限公司 Data cache method and data buffer storage
CN110310060A (en) * 2019-05-27 2019-10-08 阿里巴巴集团控股有限公司 Inventory management method and device based on fragment
CN111241195A (en) * 2020-01-02 2020-06-05 腾讯云计算(北京)有限责任公司 Database processing method, device, equipment and storage medium of distributed system
CN112347111A (en) * 2019-12-05 2021-02-09 北京沃东天骏信息技术有限公司 Data updating method and device

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012043338A (en) * 2010-08-23 2012-03-01 Nippon Telegr & Teleph Corp <Ntt> Cache management apparatus, cache management program and recording medium
CN106469166A (en) * 2015-08-18 2017-03-01 阿里巴巴集团控股有限公司 A kind of information processing method and device
CN107463593A (en) * 2016-12-13 2017-12-12 阿里巴巴集团控股有限公司 Stock reduces method and its equipment
CN108874809A (en) * 2017-05-10 2018-11-23 北京京东尚科信息技术有限公司 Data processing method and device, electronic equipment, storage medium
CN107463693A (en) * 2017-08-11 2017-12-12 深圳乐信软件技术有限公司 A kind of data processing method, device, terminal and computer-readable recording medium
CN109710698A (en) * 2018-12-28 2019-05-03 北京明朝万达科技股份有限公司 A kind of data assemblage method, device, electronic equipment and medium
CN109981774A (en) * 2019-03-22 2019-07-05 联想(北京)有限公司 Data cache method and data buffer storage
CN110310060A (en) * 2019-05-27 2019-10-08 阿里巴巴集团控股有限公司 Inventory management method and device based on fragment
CN112347111A (en) * 2019-12-05 2021-02-09 北京沃东天骏信息技术有限公司 Data updating method and device
CN111241195A (en) * 2020-01-02 2020-06-05 腾讯云计算(北京)有限责任公司 Database processing method, device, equipment and storage medium of distributed system

Similar Documents

Publication Publication Date Title
RU2557761C2 (en) Bottom-up optimised search system and method
CN111752957B (en) Sale locking method and system based on caching
JP5844333B2 (en) Sustainable data storage technology
KR20090085572A (en) System and method for providing high availability data
US7712096B2 (en) Method, system, and storage medium for dynamically reordering resource participation in two-phase commit to heuristically optimize for last-agent optimization
CN104065636B (en) Data processing method and system
CN112766907A (en) Service data processing method and device and server
CN106407244A (en) Multi-database-based data query method, system and apparatus
CN111722918A (en) Service identification code generation method and device, storage medium and electronic equipment
CN107798135B (en) Paging query method and device and electronic equipment
CN115422205A (en) Data processing method and device, electronic equipment and storage medium
CN111666289A (en) Data storage and query method and device, electronic equipment and readable storage medium
CN114282011A (en) Knowledge graph construction method and device, and graph calculation method and device
CN113626458A (en) High-concurrency data updating method, device, equipment and computer storage medium
CN111260272A (en) Method, device, equipment and storage medium for responding to user request based on inventory
CN111311360A (en) Resource return method and device, storage medium and electronic device
CN105978744A (en) Resource allocation method, device and system
CN110879900A (en) Data processing method and device based on block chain system
CN113556407B (en) Interface calling method and device for identification analysis node and electronic equipment
CN109783499A (en) A kind of data cache method, device and server
CN113298513A (en) Method and system for processing payment request
CN113935570A (en) Order processing method, device, equipment and storage medium
CN111314440B (en) Ring detection method and system on graph structure data
CN112825045A (en) Payment request processing method, system and storage medium
CN116701410B (en) Method and system for storing memory state data for data language of digital networking

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