Method and system for voting and tabulating a meeting of creditors in bankruptcy
By assigning integer entity sequence IDs to creditors and storing them using binary bitmaps, the problems of soaring memory consumption and low computational efficiency in large-scale bankruptcy creditors' meetings are solved, achieving efficient voting and statistics.
Patent Information
- Application Number
- CN202511158065.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-19
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2045-08-19
AI Technical Summary
Existing technologies suffer from problems such as increased memory consumption and low efficiency of aggregate operations in large-scale bankruptcy creditors' meetings, which cannot meet the timeliness requirements of legal procedures.
Instead of the original long integer identifier, an integer entity sequence number ID combined with a binary bitmap is used for storage. By assigning a continuously increasing integer entity sequence number ID to each creditor and establishing an initial bitmap for the participation status, voting status, and voting result status, bit operations are performed to improve efficiency.
It effectively reduces memory usage in large-scale bankruptcy creditors' meetings, improves the efficiency of aggregated operations, solves memory pressure and response latency issues, and meets the timeliness requirements of legal procedures.
Smart Images

Figure CN120724037B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of data statistics, and particularly relates to a voting and statistics method and system for a bankruptcy creditor meeting. BACKGROUND
[0002] The current bankruptcy creditor meeting system has significant performance bottlenecks when dealing with large-scale meeting scenarios. The existing technology uses a double cache list mechanism for voting management: before the meeting, the business identifiers (long integer, 8 bytes per person) of all creditors in a single item grouping are preloaded into a cache list. Taking a ten-thousand-person grouping as an example, storing this list alone occupies 80 KB of memory space. During the meeting, another independent list is used to record the people who have voted, and set operations (such as difference set calculation of non-voters) need to be performed in real time.
[0003] When the meeting size reaches tens of thousands of people, this architecture exposes serious flaws: in terms of storage, the long integer identifier causes the memory usage to increase linearly with the number of people, and the memory pressure is amplified exponentially in the case of multiple groupings and multiple items. In terms of computation, the set operation has high time complexity, and the efficiency of traversing ten-thousand-person data deteriorates dramatically, resulting in significant real-time statistics delay. This design makes both cache preheating and real-time updating processes fall into a performance quagmire, and the operation time for ten-thousand-person scale can reach minutes, which cannot meet the stringent requirements of the bankruptcy meeting legal procedure for timeliness. SUMMARY
[0004] Therefore, it is necessary to provide a voting and statistics method and system for a bankruptcy creditor meeting to solve the above technical problems.
[0005] In a first aspect, the application provides a voting and statistics method for a bankruptcy creditor meeting, which includes:
[0006] Obtaining original creditor data in a production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of a meeting state, a voting state, and a voting result state to obtain an initial creditor state bitmap set;
[0007] According to the meeting voting items and the time of holding the meeting, meeting data carrying the initial creditor state bitmap set is loaded into a remote cache to obtain remote intermediate structure data;
[0008] According to the meeting voting items and the time of holding the meeting, meeting data carrying the initial creditor state bitmap set is loaded into a remote cache to obtain remote intermediate structure data;
[0009] According to the state bitmap set and a current service scenario, bit operation is performed in remote intermediate structure data, and original creditor details data corresponding to the state bitmap set is obtained to obtain a final result.
[0010] In some implementable manners, the step of obtaining original creditor data in the production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state, and voting result state to obtain an initial creditor state bitmap set includes:
[0011] A continuously increasing integer entity serial number is assigned to each original creditor in the original creditor data to obtain an integer entity serial number ID of the original creditor.
[0012] Three independent bitmap storage spaces are created according to the entity serial number ID, wherein the three independent bitmap storage spaces respectively store an initial bitmap of attendance state, an initial bitmap of voting state, and an initial bitmap of voting result state.
[0013] An initial creditor state bitmap set is obtained according to the initial bitmap of attendance state, the initial bitmap of voting state, and the initial bitmap of voting result state corresponding to the three independent bitmap storage spaces.
[0014] In some implementable manners, the step of creating three independent bitmap storage spaces for the entity serial number ID includes:
[0015] In the initial bitmap of attendance state, 1 bit is stored for each creditor.
[0016] In the initial bitmap of voting state, 1 bit is stored for each creditor.
[0017] In the initial bitmap of voting result state, 2 bits are stored for each creditor.
[0018] In some implementable manners, the step of obtaining original creditor data, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state, and voting result state to obtain an initial creditor state bitmap set further includes:
[0019] An association mapping of original creditors under jurisdiction of staff is established according to the entity serial number ID to obtain a staff-creditor association mapping table.
[0020] A grouping-transaction association mapping table is obtained according to a mapping relationship between the entity serial number ID and a voting transaction corresponding to the original creditor.
[0021] In some embodiments, the step of loading the conference data carrying the initial creditor state bitmap set into the remote cache according to the conference voting items and the meeting time to obtain the remote intermediate structure data comprises:
[0022] According to the conference voting items and the meeting time, the conference data is filtered in the production database to obtain target conference data, wherein the target conference data includes an original creditor list and its integer entity serial number ID, the staff-creditor association mapping table and the grouping-item association mapping table;
[0023] The creditor state bitmap set and the target conference data are combined to obtain intermediate structure data;
[0024] The intermediate structure data is loaded into the remote cache to obtain the remote intermediate structure data, and the target conference data is synchronously written into the statistical database.
[0025] In some embodiments, the step of updating the participation state, the voting state and the voting result state in the initial bitmap according to the participation state and the voting state of the current creditor and the voting result state, respectively, to obtain a state bitmap set comprises:
[0026] According to the actual participation of the current creditor, the corresponding bit value in the participation state initial bitmap is updated to generate a participation state target bitmap;
[0027] In response to the voting operation completion event of the current creditor, the corresponding bit value in the voting state initial bitmap is updated to generate a voting state target bitmap;
[0028] According to the participation state target bitmap and the voting state target bitmap, the corresponding voting result state type is obtained to generate a voting result state target bitmap;
[0029] According to the participation state target bitmap, the voting state target bitmap and the voting result state target bitmap, a state bitmap set is obtained.
[0030] In some embodiments, the step of performing bit operation in the remote intermediate structure data according to the state bitmap set and the current business scenario, and the original creditor detail data corresponding to the state bitmap set to obtain the final result comprises:
[0031] According to the current business scenario, a state filtering condition is determined, wherein the current business scenario includes a logical combination of the participation state, the voting state and the voting result state;
[0032] In the remote intermediate structure data, based on the state filtering condition, bit operation processing is performed on the state bitmap set to obtain a target creditor serial number list, wherein the bit operation includes at least one of bitwise AND, bitwise OR, and bitwise NOT;
[0033] According to the entity serial number ID of the target creditor serial number list, addressing is performed in the remote cache to load corresponding original creditor detail data to form an original creditor data subset, wherein the original creditor data subset includes original creditor basic information and associated staff information;
[0034] According to the original creditor data subset and the corresponding state bitmap set, the final result for interface display is obtained.
[0035] In some implementable manners, after the step of obtaining original creditor data in the production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of participation state, voting state, and voting result state to obtain an initial creditor state bitmap set, the following steps are included:
[0036] The production database is listened to to obtain data change events to form a WAL log;
[0037] When the production database is abnormal, data recovery is performed using the WAL log.
[0038] In some implementable manners, the step of obtaining the final result for interface display according to the original creditor data subset and the corresponding state bitmap set includes:
[0039] The multi-table data corresponding to the WAL is combined into single-table data to obtain data conforming to the statistical database structure;
[0040] The data conforming to the statistical database structure is written into the statistical database to obtain a real-time updated statistical database;
[0041] According to the real-time updated statistical database, real-time statistical index calculation is performed to obtain statistical indexes;
[0042] According to the statistical indexes, the state bitmap set, and the original creditor data subset, the final result for interface display is obtained.
[0043] In a second aspect, the application provides a system for voting and statistics of a bankruptcy creditor meeting, which is applied to the steps of the foregoing method, and the system includes:
[0044] The acquisition unit is used for acquiring original creditor data in a production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of a participation state, a voting state and a voting result state to obtain an initial creditor state bitmap set;
[0045] The intermediate structure unit is used for loading conference data carrying the initial creditor state bitmap set into a remote cache according to a conference voting matter and a holding time to obtain remote intermediate structure data.
[0046] The updating unit is used for updating the participation state, the voting state and the voting result state in the initial bitmap according to the participation state and the voting state of the current creditor and the voting result state to obtain a state bitmap set.
[0047] The result unit is used for performing bit operation in the remote intermediate structure data according to the state bitmap set and a current business scenario and original creditor detailed data corresponding to the state bitmap set to obtain a final result.
[0048] Beneficial effects: The application provides a voting and statistics method for a bankruptcy creditor conference, which comprises the following steps: acquiring original creditor data in a production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of a participation state, a voting state and a voting result state to obtain an initial creditor state bitmap set; loading conference data carrying the initial creditor state bitmap set into a remote cache according to a conference voting matter and a holding time to obtain remote intermediate structure data; updating the participation state, the voting state and the voting result state in the initial bitmap according to the participation state and the voting state of the current creditor and the voting result state to obtain a state bitmap set; and performing bit operation in the remote intermediate structure data according to the state bitmap set and a current business scenario and original creditor detailed data corresponding to the state bitmap set to obtain a final result. The above method uses an integer entity serial number ID in combination with binary bitmap storage to replace the original long integer identifier, reduces the memory occupation of a large number of participants in a group, and solves the problems of rapid increase of memory occupation, low efficiency of set operation and response delay of dynamic adjustment in a large-scale bankruptcy creditor conference scenario. BRIEF DESCRIPTION OF DRAWINGS
[0049] In order to more clearly illustrate the technical solutions in the embodiments of the application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or the prior art description. Obviously, the drawings in the following description only constitute some embodiments of the application, and for those skilled in the art, other drawings can also be obtained without creative labor based on these drawings.
[0050] Figure 1 A flowchart of a method for voting and statistics of a meeting of creditors in bankruptcy in one embodiment. DETAILED DESCRIPTION
[0051] For the purpose of understanding the present application, a more complete description of the application will be provided in conjunction with the relevant drawings. The drawings provided herein are intended to illustrate the embodiments of the present application. However, the present application can be implemented in many different forms and is not limited to the embodiments described herein. Rather, the purpose of providing these embodiments is to make the disclosure of the present application more thorough and comprehensive.
[0052] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used in the description of the application herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items.
[0053] It can be understood that the terms "first", "second", etc. used in the present application can be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from another element.
[0054] Some terms related to the present application are explained below to facilitate understanding of the present application:
[0055] A bitmap, also known as a bit array or bitset, is an efficient data structure for storing data based on binary bits.
[0056] Mutually exclusive update refers to the concurrent modification operation of the same group of creditor state bitmaps (such as attendance state, voting state) within the same time window, which must be executed in series to ensure data consistency.
[0057] WAL (Write-Ahead Logging) is a database transaction processing mechanism that requires all data modifications to be written to a persistent log first and then applied to the actual data file.
[0058] Atomic transaction mechanism refers to a group of database operations that are executed as an indivisible unit, either all succeed or all roll back, ensuring data consistency. In the meeting of creditors system, it is used to ensure the integrity and reliability of key operations such as modification and statistical calculation of creditor state bitmaps (such as voting and attendance state).
[0059] The bankruptcy creditor meeting system is special software in a specific field, and the application scenario has a feature that the traffic may not be very large at ordinary times, and the traffic will be very high during the meeting because the number of meeting participants ranges from dozens to hundreds or even hundreds of thousands. During the voting process on various issues at the same time, the meeting software tracks and monitors the voting process, and counts the number of voters, non-voters, and the number of supporters, opponents, and abstainers. At present, the meeting for this matter will have several groups, and these people are sorted before the meeting, that is, the preheating process of the cache. All the data used for voting are loaded during preheating, but the storage structure uses a list in the memory, for example, 100 people are needed to vote on this matter, and the data of the 100 people on this matter are first added to the cache, which is all the people who can vote. During the voting process, who has voted is recorded in another cache record. Thus, the two caches are combined to calculate who has not voted. In small meetings with dozens, hundreds, or even thousands of people, such cooperation is not a problem and runs very smoothly.
[0060] However, whether it is the preheating process of the cache or the change process of the cache, the cache is constantly changing during the meeting.
[0061] First, the voting state of the meeting participant changes, that is, the voting is completed, resulting in a change in the cache.
[0062] Second, the manager may adjust the data of the cache at any time during the meeting, for example, adding or deleting meeting participants or increasing or decreasing groups.
[0063] Thus, once the scale of the meeting is large, reaching tens of thousands or even hundreds of thousands of people, the number of people in a single group for a single matter may reach tens of thousands. During the data preparation stage in the document, since the current business identifier is a long integer of eight bytes, if there are ten thousand people, ten thousand multiplied by eight is 80,000 bytes. The data is about 80K of data, which is only a storage space of a single list (a group). For a meeting, there are many storage spaces of such a large scale, and the efficiency will be very low when the 80K data is operated. Therefore, whether it is the preheating process of the cache or the change process of the cache, the process is very slow.
[0064] Based on the above reasons, the present application provides a method for voting and counting of a bankruptcy creditor meeting, and the specific content is as follows:
[0065] For example, Figure 1As shown in the first aspect, the application provides a method for voting and statistics of a bankruptcy creditor meeting, comprising:
[0066] S100, obtaining original creditor data in a production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and establishing initial bitmaps of attendance state, voting state and voting result state respectively to obtain an initial creditor state bitmap set.
[0067] Establish a secure connection with the production database, query and obtain the complete original creditor data of the current meeting, which can include the original creditor business ID (long integer), creditor amount, group to which it belongs, proxy relationship and other core fields.
[0068] Specifically, obtaining the initial creditor state bitmap set can include the following steps:
[0069] S101, assigning a continuously increasing integer entity serial number to each original creditor in the original creditor data to obtain the integer entity serial number ID of the original creditor.
[0070] Specifically, in memory, traverse the original creditor data, and assign a unique identification of business data to each original creditor, which is a long integer (8 bytes). All data entities increase an integer entity serial number attribute (4 bytes) on the basis of a redundant business identification, that is, assign a continuous integer serial number ID (4 bytes), which is initially 1. Illustratively, assign serial numbers (1, 2, 3…N) in turn according to the loading order of the original creditor data, and establish a mapping between the serial number ID and the creditor business ID. For multiple creditors associated with staff, a continuous serial number block can be assigned (such as staff A associated serial numbers 101-103).
[0071] S102, creating three independent bitmap storage spaces according to the entity serial number ID.
[0072] Among them, the three independent bitmap storage spaces store the initial attendance state bitmap, the initial voting state bitmap and the initial voting result state bitmap respectively.
[0073] Illustratively, in the initial attendance state bitmap, the creditor attendance state is stored as 1 bit / creditor; in the initial voting state bitmap, the voting state is stored as 1 bit / creditor; and in the initial voting result state bitmap, the voting result is stored as 2 bits / creditor.
[0074] In the initial attendance state bitmap, the creditor attendance state is stored as 1 bit / creditor, and the attendance state bitmap: each creditor occupies 1 bit, 0=not attended, 1=attended, and the initial value is all 0.
[0075] The voting state initial bitmap stores the voting state as 1 bit per creditor. The voting state bitmap: each creditor occupies 1 bit, 0 = not voted, 1 = voted, and the initial is all 0.
[0076] The voting result state initial bitmap stores the voting result as 2 bits per creditor. The voting result bitmap: each creditor occupies 2 bits, initialized as 00 (abstain), and the coding rule is: 00: abstain, 01: agree, 10: oppose, and 11: reserve (or custom state).
[0077] The bitmap space is pre-allocated according to the maximum number of creditors, and the offset calculation formula is: (entity serial number ID - 1) * bit number.
[0078] S103, obtaining an initial creditor state bitmap set according to the participation state initial bitmap, the voting state initial bitmap, and the voting result state initial bitmap corresponding to the three independent bitmap storage spaces.
[0079] Specifically, the participation state initial bitmap, the voting state initial bitmap, and the voting result state initial bitmap are combined to obtain the initial creditor state bitmap set, which is convenient for use in subsequent steps.
[0080] In addition, obtaining the initial creditor state bitmap set can further include the following steps:
[0081] S104, establishing an association mapping of original creditors under the jurisdiction of the staff according to the entity serial number ID to obtain a staff-creditor association mapping table.
[0082] Specifically, all original creditor data are traversed to identify the staff information corresponding to each original creditor. For the original creditor who specifies the staff, the entity serial number ID of the original creditor is associated with the ID of the corresponding staff. For the case where the staff is not specified, it is marked as self-agency. Next, all original creditors belonging to the same staff are sorted by the entity serial number ID, and the continuous serial numbers are merged into blocks (for example, the original creditors 101, 102, and 103 associated with staff A are merged into a 101-103 block), and a bidirectional mapping relationship is established: the forward mapping records the original creditor serial number block list corresponding to each staff, and the reverse mapping records the staff identifier associated with the entity serial number ID of each original creditor.
[0083] Each staff generates a staff bitmap, in which the entity serial number positions of all original creditors under the jurisdiction of the staff are marked as 1, forming a complete staff-creditor association mapping system.
[0084] The staff-creditor association mapping system is used to adjust the original creditors through the staff bitmap.
[0085] The purpose of generating a special bitmap for the staff is to achieve efficient management and precise control of the bankruptcy creditor meeting through binary marking technology. This design converts the serial number of the creditors under the jurisdiction of each staff into a compact bitmap structure (1 represents jurisdiction / 0 represents no association), which improves the voting operation efficiency of the multi-person creditor meeting. When the staff submits a batch vote, there is no need to traverse the list, and the status of hundreds of creditors can be updated simultaneously through bitwise operations; in addition, when the court checks, it only needs to compare the staff bitmap with the voting bitmap to immediately confirm the legality of its operation.
[0086] S105, according to the voting matter corresponding to the original creditor, the mapping relationship between the entity serial number ID and the voting matter is obtained, and the grouping and matter association mapping table is obtained.
[0087] Specifically, first, load the pre-defined voting matter configuration, which can include voting matter ID, name, time range and applicable rules (such as creditor type requirement, amount threshold, etc.). For each original creditor, according to its attributes (creditor type, amount, region, etc.), match the applicable rules to determine the set of voting matters it participates in, establish the association mapping of entity serial number ID to voting matter ID set, in addition, also need to increase the time attribute, that is, when the voting matter ID and the entity serial number ID are associated, the time attribute needs to be added, that is, the association of the voting matter ID and the entity serial number ID has a time dimension.
[0088] In addition, based on the grouping and matter association mapping table, a special bitmap can be generated for each voting matter, such as the voting matter bitmap.
[0089] Use the voting matter bitmap to adjust the associated original creditors.
[0090] In this voting matter bitmap, the original creditor serial number position participating in the matter is marked as 1. At the same time, the association mapping table of grouping and voting matter is constructed: the dimensions such as staff grouping and creditor type grouping are associated with specific voting matters (for example, staff A grouping is associated with asset disposal matter). This mapping table supports quick retrieval of the matters that can be operated by the staff grouping, providing a complete framework for subsequent grouping voting. The snapshot version of the rule matching needs to be saved to ensure that the historical state can be traced back during judicial audit.
[0091] Exemplarily, a staff-specific permission profile can be established, which is directly associated with the voting item IDs that the staff can operate; at the same time, an independent original creditor participation list is maintained for each voting item, which records the serial numbers of the creditors entitled to participate in the form of a binary bit sequence. When the staff initiates an operation request, the staff's permission profile is first retrieved to obtain a set of voting item IDs, and then the participation list of the corresponding voting item is called to filter out the effective original creditors within the jurisdiction of the staff through bit operation. All permission changes generate time-stamped version records, which are stored in an encrypted chain to form a verifiable historical track.
[0092] For example, a bankruptcy case involves two voting items, debt restructuring (item A) and asset disposal (item B). The staff is responsible for the creditors of three financial institutions (serial numbers 101-103).
[0093] The system is configured as follows:
[0094] The staff's permission profile is associated with the voting item A and B identifiers; the participation list of voting item A is marked with serial numbers 50-200 as 1; and the participation list of voting item B is marked with serial numbers 1-150 as 1.
[0095] When the staff logs into the system: retrieve the permission profile to know that voting items A and B can be operated; when voting item A is selected, the system calculates: staff jurisdiction bitmap (101-103) AND voting item A participation bitmap (50-200) = effective operation bitmap (101-103); the interface displays the operation options of the three financial institutions under its jurisdiction.
[0096] When a financial institution creditor No. 104 participates in voting item A is added during the meeting, the administrator updates the participation list of voting item A (104 is set to 1); the system rebuilds the effective operation bitmap of the staff (extended to 101-104); and the change record generates an encrypted version snapshot.
[0097] This mechanism realizes precise range control of staff operation through the double-layer coupling of permission profile and voting item list, and ensures real-time synchronization and judicial traceability of permission changes.
[0098] S200, load the meeting data carrying the initial creditor status bitmap set into the remote cache to obtain remote intermediate structure data.
[0099] Specifically, obtaining the remote intermediate structure data can include the following steps:
[0100] S201, according to the conference voting items and the time of holding, the conference data is screened in the production database to obtain target conference data, wherein the target conference data includes the original creditor list and its integer entity serial number ID, the staff and creditor association mapping table and the grouping and item association mapping table.
[0101] Specifically, according to the conference voting items and the time of holding, the data of the corresponding original creditor is screened in the production database, and then the original creditor list is obtained, which can be screened by the mapping relationship of the grouping and item association mapping table. Next, the staff is determined according to the staff and creditor association mapping table formed by the original creditor.
[0102] It should be noted that each voting item is bound with its applicable creditor range rule (such as creditor type = guarantee, amount ≥ 1 million) when created, and is bound with the time of holding. When the screening is performed, the conference data is screened in the production database based on the grouping and item association mapping table, and then the target conference data is formed.
[0103] S202, the creditor state bitmap set and the target conference data are combined to obtain intermediate structure data.
[0104] Specifically, the creditor state bitmap set and the target conference data are combined and encapsulated to obtain intermediate structure data.
[0105] S203, the intermediate structure data is loaded into the remote cache to obtain the remote intermediate structure data, and the target conference data is synchronously written into the statistical database.
[0106] Specifically, after the intermediate structure data is encapsulated, it is loaded into the remote cache. The remote cache can refer to a centralized memory storage layer (such as Redis Cluster or Memcached cluster) accessed through the network, which is physically isolated from the core business server but low-latency intercommunication. Next, the target conference data is synchronously written into the statistical database, which not only enables traceability in the event of system crash or downtime, but also enables real-time calculation of statistical indicators, facilitates subsequent steps, and forms a traceable blockchain anchoring interface to realize verifiable backtracking of bitmap state.
[0107] The statistical database can be deployed in a dedicated computer room or deployed in the cloud, and the present application does not limit it.
[0108] S300, according to the current creditor's participation state and voting state, and the voting result state, the participation state, the voting state and the voting result state in the initial bitmap are updated respectively to obtain a state bitmap set.
[0109] Specifically, obtaining the state bitmap set can include the following steps:
[0110] S301, updating the corresponding bit value in the initial attendance state bitmap according to the actual attendance of the current creditor, to generate a target attendance state bitmap.
[0111] Specifically, according to the actual attendance of the current creditor, the offset is calculated, offset = entity serial number - 1.
[0112] In the initial attendance state bitmap, the corresponding bit value is updated, such as attendance, the bit value is set to 1, otherwise the bit value is set to 0, and finally the updated target attendance state bitmap is output.
[0113] It should be noted that when a new creditor is added, the bitmap length is automatically extended (Redis SETBIT supports dynamic expansion).
[0114] S302, in response to the voting operation completion event of the current creditor, updating the corresponding bit value in the initial voting state bitmap to generate a target voting state bitmap.
[0115] Specifically, in response to the voting operation completion event of the current creditor, that is, the operation performed by the current creditor on the terminal such as computer, mobile phone and tablet, the corresponding bit value in the initial voting state bitmap is set to 1, and the updated target voting state bitmap is generated.
[0116] S303, according to the target attendance state bitmap and the target voting state bitmap, the corresponding voting result state type is obtained to generate a target voting result state bitmap.
[0117] Specifically, based on the double verification (confirming that the corresponding bit value is 1) of the target attendance state bitmap and the target voting state bitmap, according to the specific voting result type (approval / opposition / abstention) submitted by the current creditor, mutual exclusion update is performed in the initial voting result bitmap: the bit value of the target voting result bitmap is set to 1, and the bit value of the same serial number in the other two types of result bitmap is set to zero, to generate the updated target voting result bitmap.
[0118] In addition, in order to ensure the integrity and consistency of the creditor state update, all bitmap update operations (attendance state, voting state and voting result) are executed by using atomic transaction mechanism: the attendance state update, voting state update and voting result update operations are combined into an indivisible operation sequence. All operations are submitted at one time to ensure that all operations are successfully executed or not executed, and when it is detected that the lock key is modified, the current operation sequence is terminated.
[0119] S304, obtaining a state bitmap set according to the participation state target bitmap, the voting state target bitmap and the voting result state target bitmap.
[0120] Specifically, the participation state target bitmap, the voting state target bitmap and the voting result state target bitmap are combined to obtain the state bitmap set.
[0121] S400, performing bit operation in the remote intermediate structure data according to the state bitmap set and a current business scenario, and obtaining a final result according to the state bitmap set and corresponding original creditor details data.
[0122] Specifically, obtaining the final result can include the following steps:
[0123] S401, determining a state filtering condition according to the current business scenario.
[0124] The current business scenario includes a logical combination of the participation state, the voting state and the voting result state.
[0125] Specifically, the filtering condition is determined according to the current business scenario, such as the non-voting creditor and the approval vote details. The state filtering condition will be used as the filtering condition of the final result, and the final result is presented in the final step.
[0126] S402, performing bit operation processing on the state bitmap set in the remote intermediate structure data based on the state filtering condition to obtain a target creditor serial number list.
[0127] The bit operation includes at least one of the bitwise AND, the bitwise OR and the bitwise NOT.
[0128] Specifically, the state filtering condition is used to filter in the remote intermediate structure data. In the remote intermediate structure data, the meeting voting item + the meeting time composite key is used to load three bitmaps from the remote intermediate structure data. Next, the three bitmaps are filtered based on the state filtering condition, and the filtering method is the bit operation. According to the bit operation processing result, the target creditor serial number list is obtained.
[0129] S403, loading corresponding original creditor details data according to the entity serial number ID of the target creditor serial number list to form an original creditor data subset.
[0130] The original creditor data subset includes original creditor basic information and associated staff information.
[0131] Specifically, according to the entity serial number ID of the target creditor serial number list, the remote cache is addressed, if not hit, the statistical database can be loaded and backfilled. In this way, the corresponding original creditor detail data is loaded in the remote cache, thereby forming an original creditor data subset.
[0132] S404, according to the original creditor data subset, and the corresponding state bitmap set, the final result for interface display is obtained.
[0133] Specifically, after obtaining the original creditor data subset in the foregoing steps, the original creditor data subset can also be processed, such as screening, sorting, filtering and grouping operations, thereby obtaining a processed original creditor data subset. Next, using the processed original creditor data subset and the corresponding state bitmap set combination, an interface for displaying the final result is formed.
[0134] In one embodiment, after the step of obtaining original creditor data in the production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state and voting result state to obtain an initial creditor state bitmap set, the step includes:
[0135] Listen to the production database to obtain data change events and form a WAL log;
[0136] When the production database is abnormal, data recovery is performed using the WAL log.
[0137] Specifically, the production database is monitored to obtain data change events. The data change event refers to the change formed when the transaction is submitted or other event triggers. For example, it can be a voting state change, a creditor grouping change, an original creditor change or a filtering invalid event. According to the data change time, the WAL log can be obtained. Next, when the production database is abnormal, data recovery is performed using the WAL log.
[0138] In one embodiment, the step of obtaining the final result for interface display according to the original creditor data subset and the corresponding state bitmap set includes:
[0139] The multi-table data corresponding to the WAL is combined into single-table data to obtain data conforming to the statistical database structure.
[0140] Specifically, the WAL log stream of the production database is parsed in real time to extract data change events, such as identifying changes, deletions or insertions of creditor tables, agent tables, creditor tables and the like. Related changes of the same business event can be associated through transaction ID (such as changes in creditor information and its agent information). Next, the associated data is reorganized into a single wide table record containing creditor basic information, creditor details and agent information. Thus, the integrated wide table data is generated, which conforms to the statistical database structure and can be written into the statistical database.
[0141] For example, there are creditor tables (creditor identifier, creditor name), creditor grouping tables (creditor identifier, grouping identifier), participant tables (participant identifier, participant name), creditor & participant association tables (creditor identifier, participant identifier), voting matter tables (matter identifier, matter name), voting result tables (matter identifier, creditor identifier, voting result, submitter identifier) in the business. After using the wide table, the six tables mentioned above are combined into a wide table according to the association conditions (creditor identifier, participant identifier, matter identifier, etc.). The wide table records the creditor's check-in information and the specific voting result under a certain matter and the voting submitter.
[0142] The data conforming to the statistical database structure is written into the statistical database to obtain a real-time updated statistical database.
[0143] Specifically, the integrated wide table data is written into the optimized statistical database in real time, so that the wide table data is used to update the statistical database, so that the data in the statistical database is real-time data.
[0144] According to the real-time updated statistical database, real-time statistical index calculation is performed to obtain a statistical index.
[0145] Specifically, the key fields in the wide table, such as creditor serial number, creditor amount, voting status and the like, are extracted and standardized events are generated. Next, the standardized events can be processed, for example, real-time index trend charts, statistical total number and other mathematical operations are generated.
[0146] According to the statistical index, the state bitmap set and the original creditor data subset, the final result for interface display is obtained.
[0147] Specifically, after obtaining the statistical index, the state bitmap set and the original creditor data subset in the foregoing steps, the data is combined and then displayed on the interface to form the final result. Embodiments
[0148] A method for voting and statistics of a bankruptcy creditor meeting, which realizes statistics and calculation of various data in voting through a bitmap. The technical solution is as follows:
[0149] S1, data preparation
[0150] The system allocates a unique identifier of a business data to each creditor personnel of each meeting, which is a long integer (8 bytes). All data entities increase an integer entity serial number attribute (4 bytes) on the basis of a redundant business identifier. The attribute is incremented from 1 in each meeting. All creditors are grouped, and the creditors represented by the attendees are associated with the corresponding group for each voting matter;
[0151] According to the coding order, a bit of cache space is allocated to each corresponding creditor for storing the attendance state (1 for attending and 0 for not attending). A bit of cache space is allocated to each creditor for storing the voting state (1 for having voted and 0 for not having voted). A bit of cache space is allocated to each creditor for storing the voting result bit. The data on the bit is updated in real time (less than one minute) and calculated. For those who have not voted, the corresponding two groups of bitmap data are subjected to AND operation.
[0152] Manager modifies cache data:
[0153] (1) Creditor personnel removal: change the state of the corresponding bit for storing the attendance state to 0; no need to traverse each table to delete the creditor;
[0154] (2) Batch modification or removal: directly find the corresponding bit according to the entity serial number code to modify simultaneously; no need to traverse;
[0155] (3) According to the existing code, the sequential entity serial number code is encoded, and the bit and the initial state on the bit are allocated;
[0156] S2, cache preheating
[0157] According to the time of the creditor meeting, the data of the meeting held on the same day is loaded into the remote cache. At this time, the data loaded into the cache is intermediate data, which is not the final data that can be used by the presentation layer.
[0158] S3, data change listening
[0159] The service layer listens to data change event notifications. When the concerned entity data changes, the entity is obtained according to the cache change rule, and then the corresponding cache is updated (delete existing cache, local update update cache, and reload specific cache) according to the rule.
[0160] S4, presentation layer data query
[0161] The presentation layer is loaded from the remote cache to the intermediate structure data according to the participant identifier, the conference identifier and the specific business scenario, then the remote intermediate structure data is operated, the corresponding detailed data is loaded from the remote cache according to the operation result, and then the final result is obtained by performing filtering, sorting, grouping and other operations on the loaded detailed data.
[0162] Data real-time update, i.e., synchronization to the statistical database: based on the low real-time of the timing task, and based on the WAL data to meet the requirements of data real-time update;
[0163] The production database has a mechanism called WAL log for database security guarantee service. If the database crashes or goes down at any time, the production data can be recovered as long as there is a WAL log.
[0164] S4.1, the changed database is parsed from the WAL of the production database;
[0165] S4.2, the parsed data is reassembled to obtain data meeting the structure requirements of the statistical database (change a plurality of tables into one table, i.e., a wide table);
[0166] S4.3, the wide table data after assembly is written into the statistical database;
[0167] S4.4, based on the statistical database data, real-time calculation of each statistical index is performed;
[0168] In summary, the method for voting and statistics of the bankruptcy creditor meeting provided in the application has the following advantages compared with using a long integer and a redis native data structure by adding a shaping sequence number attribute and using a bitmap data structure:
[0169] 1. Save storage space
[0170] Using a bitmap to do data caching can save a lot of storage space compared with using a native collection data structure to store data. For a proxy of 10,000 participants, if the original data structure list is used for storage, the storage space occupied is about 80k (8*10000 / 1000); if the sequence number is combined with the bitmap storage, the storage space occupied is about 1.25k (10000 / 8 / 1000).
[0171] 2. High data storage density
[0172] Compared with the bitmap and the entity unique identifier, the storage density of the stored data is higher in combination with the bitmap and the entity serial number (each data entity of each meeting is incremented from 1). The data entity unique identifier is generated based on a timestamp. Even if the function prefix of the same type of entity unique identifier is separated to improve the data storage density, the public prefix method is not stable (cross-month and cross-year need to be considered) because the timestamp is growing.
[0173] 3. Reduce the time complexity of calculation
[0174] The intermediate data stored in the cache needs to be operated twice in specific business scenarios. Most of the secondary operations are set operations on two intermediate data, not set operations between two lists.
[0175] In a second aspect, the application provides a system for voting and statistics of a bankruptcy creditor meeting, applied to the steps of the method, and the system comprises:
[0176] An acquisition unit is configured to acquire original creditor data in a production database, assign a continuously increasing integer entity serial number ID to each original creditor, and respectively establish initial bitmaps of a participation state, a voting state and a voting result state to obtain an initial creditor state bitmap set.
[0177] An intermediate structure unit is configured to load meeting data carrying the initial creditor state bitmap set into a remote cache according to a meeting voting matter and a meeting time to obtain remote intermediate structure data.
[0178] An update unit is configured to update the participation state, the voting state and the voting result state in the initial bitmap according to the participation state and the voting state of a current creditor and the voting result state to obtain a state bitmap set.
[0179] A result unit is configured to perform bit operation in the remote intermediate structure data according to the state bitmap set and a current business scenario, and obtain a final result according to original creditor detail data corresponding to the state bitmap set.
[0180] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when the computer program is executed, the processes of the above-mentioned embodiments of the methods can be included. Any reference to memory, storage, database or other medium used in the embodiments provided in the present application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration but not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0181] The various embodiments in the present disclosure are described in a progressive manner, and the same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on the difference from other embodiments.
[0182] The scope of protection of the present disclosure is not limited to the above-mentioned embodiments. Obviously, those skilled in the art can make various modifications and changes to the present disclosure without departing from the scope and spirit of the present disclosure. If these modifications and changes belong to the scope of the claims of the present disclosure and its equivalent technologies, the present disclosure also includes these modifications and changes.
Claims
1. A method of voting and tabulating a meeting of creditors in a bankruptcy, comprising: The method comprises: obtaining original creditor data in a production database, assigning a continuous and increasing integer entity serial number ID to each original creditor, and establishing initial bitmaps of attendance state, voting state and voting result state respectively to obtain an initial creditor state bitmap set; loading conference data carrying the initial creditor state bitmap set into a remote cache according to conference voting items and meeting time to obtain remote intermediate structure data, wherein the remote intermediate structure data indicates that the intermediate structure data is encapsulated and loaded into the remote cache, and the remote cache refers to a centralized memory storage layer accessed through a network; updating the attendance state, the voting state and the voting result state in the initial bitmap according to the attendance state and the voting state of the current creditor and the voting result state to obtain a state bitmap set; performing bit operation in the remote intermediate structure data according to the state bitmap set and the current business scenario, and obtaining the final result according to the original creditor detail data corresponding to the state bitmap set; wherein the step of loading conference data carrying the initial creditor state bitmap set into a remote cache according to conference voting items and meeting time to obtain remote intermediate structure data comprises: screening conference data in the production database according to conference voting items and meeting time to obtain target conference data, wherein the target conference data includes an original creditor list and its integer entity serial number ID, an agent-creditor association mapping table and a grouping-item association mapping table; combining the creditor state bitmap set and the target conference data to obtain intermediate structure data; loading the intermediate structure data into the remote cache to obtain the remote intermediate structure data, and synchronously writing the target conference data into a statistical database; the step of performing bit operation in the remote intermediate structure data according to the state bitmap set and the current business scenario, and obtaining the final result according to the original creditor detail data corresponding to the state bitmap set comprises: determining a state filtering condition according to the current business scenario, wherein the current business scenario includes a logical combination of attendance state, voting state and voting result state; performing bit operation processing on the state bitmap set in the remote intermediate structure data based on the state filtering condition to obtain a target creditor serial number list, wherein the bit operation includes at least one of bitwise AND, bitwise OR and bitwise NOT; addressing the remote cache according to the entity serial number ID of the target creditor serial number list to load corresponding original creditor detail data to form an original creditor data subset, wherein the original creditor data subset includes original creditor basic information and associated agent information; obtaining the final result for interface display according to the original creditor data subset and the corresponding state bitmap set; the step of obtaining the final result for interface display according to the original creditor data subset and the corresponding state bitmap set comprises: Combining the multi-table data corresponding to the WAL into single-table data to obtain data conforming to a statistical database structure; Writing the data conforming to the statistical database structure into the statistical database to obtain a real-time updated statistical database; Performing real-time statistical index calculation according to the real-time updated statistical database to obtain statistical indexes; According to the statistical indexes, the state bitmap set and the processed original creditor data subset, the final result for interface display is obtained.
2. The method of voting and tabulation of a meeting of creditors in bankruptcy of claim 1, wherein, The step of obtaining original creditor data in the production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state and voting result state to obtain an initial creditor state bitmap set, includes: Assigning a continuously increasing integer entity serial number to each original creditor in the original creditor data to obtain an integer entity serial number ID of the original creditor; According to the entity serial number ID, three independent bitmap storage spaces are created, wherein the three independent bitmap storage spaces respectively store the initial bitmap of attendance state, the initial bitmap of voting state and the initial bitmap of voting result state; According to the initial bitmap of attendance state, the initial bitmap of voting state and the initial bitmap of voting result state corresponding to the three independent bitmap storage spaces, an initial creditor state bitmap set is obtained.
3. The method of voting and tabulation of a meeting of creditors in bankruptcy of claim 2, wherein, The step of creating three independent bitmap storage spaces according to the entity serial number ID includes: In the initial bitmap of attendance state, the attendance state of the creditor is stored as 1 bit / creditor; In the initial bitmap of voting state, the voting state is stored as 1 bit / creditor; In the initial bitmap of voting result state, the voting result is stored as 2 bits / creditor.
4. The method of voting and tabulation of a meeting of creditors in bankruptcy of claim 1, wherein, The step of obtaining original creditor data, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state and voting result state to obtain an initial creditor state bitmap set, further includes: According to the entity serial number ID, an association mapping of original creditors under the jurisdiction of the agent is established to obtain an agent-debtor association mapping table; According to the voting matters corresponding to the original creditors, a mapping relationship between the entity serial number ID and the voting matters is established to obtain a grouping-matter association mapping table.
5. The method of voting and tabulation of a meeting of creditors in bankruptcy of claim 1, wherein, The step of updating the initial bitmap according to the attendance state and the voting state of the current creditor, and the voting result state, respectively, to obtain a state bitmap set includes: According to the actual attendance of the current creditor, the corresponding bit value in the initial bitmap of attendance state is updated to generate a target bitmap of attendance state; In response to the voting operation completion event of the current creditor, the corresponding bit value in the initial bitmap of voting state is updated to generate a target bitmap of voting state; According to the target bitmap of attendance state and the target bitmap of voting state, a voting result state type corresponding to the target bitmap of voting result state is obtained; According to the target bitmap of attendance state, the target bitmap of voting state and the target bitmap of voting result state, a state bitmap set is obtained.
6. The method of voting and tabulation of a meeting of creditors in bankruptcy of claim 1, wherein, The step after the step of obtaining original creditor data in the production database, assigning a continuously increasing integer entity serial number ID to each original creditor, and respectively establishing initial bitmaps of attendance state, voting state and voting result state to obtain an initial creditor state bitmap set includes: Monitoring the production database to obtain data change events and form a WAL log; When the production database is abnormal, using the WAL log to perform data recovery.
7. A system for voting and tabulation of a creditors' meeting in bankruptcy, characterized by The system applied to the steps of the method in any one of claims 1 to 6 comprises: An obtaining unit configured to obtain original creditor data in a production database, assign a continuously increasing integer entity serial number ID to each original creditor, and respectively establish initial bitmaps of attendance state, voting state and voting result state to obtain an initial creditor state bitmap set; An intermediate structure unit configured to load conference data carrying the initial creditor state bitmap set into a remote cache according to a conference voting matter and a time of holding the conference to obtain remote intermediate structure data; An updating unit configured to update the attendance state, the voting state and the voting result state in the initial bitmaps according to the attendance state and the voting state of a current creditor and the voting result state to obtain a state bitmap set; A result unit configured to perform bit operation in the remote intermediate structure data according to the state bitmap set and a current business scenario and obtain a final result according to original creditor detail data corresponding to the state bitmap set.
Citation Information
Patent Citations
Computerized voting system
CA3038506A1
Multimedia conference discussion system
CN108391079A