CN112131496A - Webpage voting data processing method, device and equipment - Google Patents

Webpage voting data processing method, device and equipment Download PDF

Info

Publication number
CN112131496A
CN112131496A CN202010976529.2A CN202010976529A CN112131496A CN 112131496 A CN112131496 A CN 112131496A CN 202010976529 A CN202010976529 A CN 202010976529A CN 112131496 A CN112131496 A CN 112131496A
Authority
CN
China
Prior art keywords
voting
message queue
writing
result
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010976529.2A
Other languages
Chinese (zh)
Other versions
CN112131496B (en
Inventor
王东东
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Zhidemai Technology Co ltd
Original Assignee
Beijing Zhidemai 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 Beijing Zhidemai Technology Co ltd filed Critical Beijing Zhidemai Technology Co ltd
Priority to CN202010976529.2A priority Critical patent/CN112131496B/en
Publication of CN112131496A publication Critical patent/CN112131496A/en
Application granted granted Critical
Publication of CN112131496B publication Critical patent/CN112131496B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C13/00Voting apparatus

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a webpage voting data processing method, which has the conception that after a voting activity page is made from a cache, input information of users participating in voting is stored in a database by an intermediate queue and a timing consumption mode, voting results are asynchronously counted based on stored voting requests after activity time is up, and the processing of voting data is automatically completed by the intermediate queue and the timing consumption mode respectively in the final result calculation and result publishing stages. The invention can achieve the purpose of quick response of the system, can homogenize a large number of requests and calculation when processing the high concurrent service of the voting request, greatly reduces the system load, not only ensures that the interactive experience is more friendly and the system is more robust, but also effectively relieves the working pressure of operators by automatically counting at regular time and publishing the voting result.

Description

Webpage voting data processing method, device and equipment
Technical Field
The present invention relates to the field of web page data processing, and in particular, to a method, an apparatus, and a device for processing web page voting data.
Background
With the rapid development of the internet community, competition among all parties of the online community is intensified, various types of user voting activities become a common community user survival promoting mode, for example, by setting a very topical problem, users are triggered to vote station teams and discuss fiercely, and the method is one of effective means for promoting user retention.
With the gradual increase of the number of users participating, on one hand, the voting activity in a short time can cause the dramatic increase of the system access amount, the system pressure can be gradually increased, the system response is often slowed down, and the request of the users can not be processed in time; on the other hand, with the increase of the number of the participating users, the program processing in the final result publishing stage becomes very slow, and even the result can not be published; particularly, the current voting mechanism is a synchronous processing mode depending on operation manpower, which not only causes too much server pressure, but also causes problems of increased labor cost and decreased business processing efficiency.
Disclosure of Invention
In view of the foregoing, the present invention provides a method, an apparatus, and a device for processing webpage voting data, and accordingly provides a computer-readable storage medium and a computer program product for solving the problems of high system pressure and low manual efficiency in a centralized voting process of a user.
The technical scheme adopted by the invention is as follows:
in a first aspect, the present invention provides a method for processing webpage voting data, including:
writing voting activity configuration stored in a database in advance into a cache;
taking out the voting activity configuration from the cache, and generating a voting activity webpage for showing to a user;
continuously monitoring and receiving voting request data input by a user on the voting event page;
writing the voting request data into a first message queue;
regularly writing the voting request data in the first message queue into a database;
after the preset time is reached, extracting the voting request data from a database, and carrying out voting statistics;
writing the voting statistical data into a second message queue;
extracting the voting statistical data from the second message queue at regular time, and matching the voting statistical data with the personal information of the users in the voting request data to obtain the final voting result of the corresponding users;
writing the final voting result into a third message queue;
and pushing the final voting result in the third message queue to a user at regular time.
In at least one possible implementation manner, the writing of the voting statistic data into the second message queue refers to writing the voting statistic result data into a database, where the second message queue refers to a message queue abstracted from the database; and/or
The writing of the final voting result into a third message queue refers to writing the voting result into a database, where the third message queue refers to a message queue abstracted from the database.
In at least one possible implementation, the voting statistics include the number of participating users, the number of votes obtained for each voting choice, the number of winners and losers based on the number of votes obtained, and the number of virtual assets awarding the winners.
In at least one possible implementation manner, the voting campaign configuration comprises a set result publishing time;
the reaching of the preset time comprises:
scanning whether the result publishing time is reached or not at regular time according to a set scanning period;
if yes, the preset time is judged to be reached.
In a second aspect, the present invention provides a web page voting data processing apparatus, including:
the buffer voting activity configuration module is used for writing the voting activity configuration stored in the database in advance into a buffer;
the activity webpage rendering module is used for taking out the voting activity configuration from the cache and generating a voting activity webpage for showing to a user;
the voting request acquisition module is used for continuously monitoring and receiving voting request data input by a user on the voting event page;
the first writing module is used for writing the voting request data into a first message queue;
the voting request storage module is used for regularly writing the voting request data in the first message queue into a database;
the voting counting module is used for extracting the voting request data from the database after the preset time is reached and carrying out voting counting;
the second writing module is used for writing the voting statistical data into a second message queue;
a final result generation module, configured to extract the voting statistical data from the second message queue at regular time, and match the voting statistical data with the user personal information in the voting request data to obtain a final voting result of the corresponding user;
a third writing module, configured to write the final voting result into a third message queue;
and the result publishing module is used for regularly pushing the final voting result in the third message queue to the user.
In at least one possible implementation manner, the second message queue and/or the third message queue refers to a message queue abstracted by a database.
In at least one possible implementation, the voting statistics include the number of participating users, the number of votes obtained for each voting choice, the number of winners and losers based on the number of votes obtained, and the number of virtual assets awarding the winners.
In at least one possible implementation manner, the voting campaign configuration comprises a set result publishing time;
the voting statistic module specifically comprises:
the timing scanning unit is used for regularly scanning whether the result publishing time is reached or not according to a set scanning period;
and the time judging unit is used for judging that the preset time is reached if the output of the timing scanning unit is yes.
In a third aspect, the present invention provides a web page voting data processing device, including:
one or more processors, memory which may employ a non-volatile storage medium, and one or more computer programs stored in the memory, the one or more computer programs comprising instructions which, when executed by the apparatus, cause the apparatus to perform the method as in the first aspect or any possible implementation of the first aspect.
In a fourth aspect, the present invention provides a computer-readable storage medium having stored thereon a computer program which, when run on a computer, causes the computer to perform the method as described in the first aspect or any possible implementation manner of the first aspect.
In a fifth aspect, the present invention also provides a computer program product for performing the method of the first aspect or any possible implementation manner of the first aspect, when the computer program product is executed by a computer.
In a possible design of the fifth aspect, the relevant program related to the product may be stored in whole or in part on a memory packaged with the processor, or may be stored in part or in whole on a storage medium not packaged with the processor.
The invention has the conception that after a voting activity page is made from a cache, input information of users participating in voting is stored in a database by means of an intermediate queue and a timed consumption mode, voting results are asynchronously counted based on stored voting requests after the activity time is up, and the voting data are automatically processed by means of the intermediate queue and the timed consumption mode in the final result calculation and result publishing stages respectively. The invention can achieve the purpose of quick response of the system, can homogenize a large number of requests when processing the high concurrent service of the voting request, greatly reduces the system load, not only ensures that the interactive experience is more friendly and the system is more robust, but also effectively relieves the working pressure of operators by automatically counting at regular time and publishing the voting result.
Furthermore, the invention provides that the database is taken as an abstracted queue in the statistics and publishing stage, namely, the existing resources are subjected to function expansion without redundant construction.
Drawings
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be further described with reference to the accompanying drawings, in which:
FIG. 1 is a flowchart of an embodiment of a method for processing webpage voting data according to the present invention;
fig. 2 is a block diagram of an embodiment of a device for processing webpage voting data according to the present invention.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are illustrative only and should not be construed as limiting the invention.
The prior art for realizing voting generally writes user voting data into a database directly through an Http interface, and the implementation technology for counting results and publishing results generally sends a request by an operator, and a background calls a corresponding process to perform corresponding calculation in a synchronous mode through the Http interface.
In the above manner, a strong dependency is generated on the database when the voting request is processed, because most of the current internet companies rely on the MySQL database, and MySQL is not a distributed system, there is a performance upper limit, conditions such as high CPU utilization rate and response delay easily occur at high concurrency, and many query and write requests cannot be processed, so that system response timeout is caused, user experience is very poor, even the whole system is crashed due to too much server pressure, and in addition, the work efficiency of an operator is also affected, and the operator has to pay much attention to publishing and pushing of the voting result.
In view of the above, the present invention aims to provide an automatic voting activity processing scheme for relieving system pressure and reducing manual dependence, that is, a high-concurrency request during user centralized voting is carried through a set intermediate queue and a queue abstracted by a database, and the processing manner of voting statistics, result calculation and publishing and pushing stages is improved from synchronous to asynchronous.
Thus, the present invention provides at least one embodiment of a method for processing webpage voting data, as shown in fig. 1, which may include the following steps:
step S1, writing the voting event configuration stored in the database in advance into a cache;
and step S2, taking the voting event configuration from the cache, and generating a voting event webpage for showing to the user.
In practice, a voting activity may be created in the background in advance, for example, topics and various answer options may be filled out by the operator, the type of virtual assets (such as points/coins, etc.) participating in consumption and the number of virtual assets are set, the activity type is selected, the dead time or result publishing time of the activity is set, and the like.
And then storing the activity configuration information in a database, and when the activity needs to be started, taking the voting activity configuration from the redis cache, and of course, if the activity configuration does not exist in the redis cache (first reading and end of life of the cache), taking the voting activity configuration from the database (such as MySQL) first, and then rendering the activity configuration data into a webpage through a Vue js framework for showing to a user.
In some embodiments, the cache module redis may be utilized, and the cache voting activities are configured in the memory through the cache redis module, so as to achieve the purpose of fast response of the system, and to assist in reducing the system pressure to a certain extent when the present invention processes the high concurrency service of voting. The redis server has the advantages that the redis server supports relatively more stored value types, the shortage of key-value storage such as memcached is compensated, the redis server is distributed in each node in the redis cluster according to the preset rule, and the pressure of a single node can be reduced.
Step S3, continuously monitoring and receiving voting request data input by the user on the voting event page;
step S4, writing the voting request data into a first message queue;
and step S5, periodically writing the voting request data in the first message queue into a database.
In practical operation, the user may select a preferred voting option, for example, it is monitored that the user writes voting request data including the identity information and the selected answer through an external interface, but it should be emphasized that the writing operation is not directly written into the database, but is written into a first message queue (for example, a RabbitMq queue with excellent processing capability may be preferred), and then a consuming process is started through a timing task such as a linux system, that is, the voting request data in the RabbitMq message queue is consumed into the database according to a certain time period (for example, 1 minute), and more preferably, the voting request data may be converted into a json format when being written into the database, so as to facilitate the structuring of the stored voting records.
It should be noted that, the invention processes the synchronous request asynchronously through the combination of the timing task technology and the message queue (with strong processing capability and technology), so that the voting request of the user can be homogenized in the high concurrency period, the interactive experience effect between the system and the user is better, and the system is more robust.
Step S6, after the preset time is reached, extracting the voting request data from the database, and carrying out voting statistics;
step S7, writing the voting statistic data into a second message queue;
and step S8, extracting the voting statistic data from the second message queue at regular time, and matching the voting statistic data with the user personal information in the voting request data to obtain the final voting result of the corresponding user.
With reference to the foregoing example, in an actual operation, whether the result publishing time is reached may also be periodically scanned according to a set scanning period based on a timing task, and if so, it may be determined that the preset time is reached. The voting records stored in the database may then be retrieved and statistically calculated, such as, but not limited to, the number of participating users, the number of votes obtained for each voting choice, the number of winners and losers based on the number of votes obtained, and the number of virtual assets awarding the winners, etc. Then, these voting statistics are written into the second message queue, where it should be noted that this process is not a storage operation, but needs to cooperate with a timing consumption mechanism designed later to perform final configuration on the voting statistics, that is, the voting statistics are taken out from the second message queue according to a set period, and are matched with entry data (which may be included in the voting request data, such as user ID, etc.) of the user, so that specific users may be obtained which have selected correct answers, and specific users may be obtained which have selected incorrect answers.
The concept and effect of the second message queue and the timed task are consistent with those of the first message queue and the timed task mentioned above, and are all used to reduce the system load at the high concurrency stage and relieve the statistical computation pressure, and the description of the present invention is omitted, but it can be further explained that, in the actual operation, the second message queue refers to a message queue abstracted by the database, and the writing of the voting statistical data into the second message queue refers to writing the voting statistical result data into the database, but it is reiterated that the essence of the process is not storage, but the statistical result is temporarily written into MySQL by using the existing database resources in order to cooperate with the subsequent timed consumption.
Step S9, writing the final voting result into a third message queue;
and step S10, regularly pushing the final voting result in the third message queue to the user.
In the foregoing, the final voting result including the user information is written into the second message queue again, where it should be noted that this process is also not a storage operation, and is also a timing consumption mechanism designed later to push the final voting result (and corresponding rewards, etc.) to the user. This principle is in accordance with the foregoing, and more preferably, the queue abstracted from the database can be used as the third message queue, for example, in actual operation, the queue in MySQL is consumed by the timed task to issue a corresponding reward (such as a virtual asset) to the voting winner, and the Redis and the internal interface provided by the independent push system push the corresponding final voting result messages to the voting loser and the winner respectively.
In summary, the idea of the present invention is that after a voting event page is made from a cache, input information of users participating in voting is stored in a database by means of an intermediate queue and a timed consumption manner, and after an event time arrives, voting results are asynchronously counted based on stored voting requests, and in a final result calculation and result publishing stage, processing of voting data is automatically completed by means of the intermediate queue and the timed consumption manner, respectively. The invention can achieve the aim of quick response of the system, can homogenize a large number of requests when processing the high concurrent service of the voting request, greatly reduces the system load, not only ensures that the interactive experience is more friendly and the system is more robust, but also effectively relieves the working pressure of operators by automatically counting at regular time and publishing the voting result, namely, the energy of the operators can be liberated from activity monitoring by the automatic voting result processing technology provided by the invention, thereby improving the overall working efficiency.
The foregoing embodiments and preferred embodiments may be implemented by formulating a corresponding PK system in actual operation, and the PK system may include, for example, an application front end, a load balancing server, an application server, a redis cluster, a relational database, and a RabbitMq message queue, which is not limited in this respect.
Corresponding to the above embodiments and preferred solutions, the present invention further provides an embodiment of a web page voting data processing apparatus, as shown in fig. 2, which may specifically include the following components:
a buffer voting activity configuration module 1, configured to write voting activity configurations stored in the database in advance into a buffer;
the activity webpage rendering module 2 is used for taking out the voting activity configuration from the cache and generating a voting activity webpage for showing to a user;
the voting request acquisition module 3 is used for continuously monitoring and receiving voting request data input by a user on the voting event page;
a first writing module 4, configured to write the voting request data into a first message queue;
a voting request storage module 5, configured to write the voting request data in the first message queue into a database at regular time;
the voting statistic module 6 is used for extracting the voting request data from the database after the preset time is reached, and carrying out voting statistics;
a second writing module 7, configured to write the voting statistical data into a second message queue;
a final result generation module 8, configured to extract the voting statistical data from the second message queue at regular time, and match the voting statistical data with the user personal information in the voting request data to obtain a final voting result of the corresponding user;
a third writing module 9, configured to write the final voting result into a third message queue;
and a result publishing module 10, configured to push the final voting result in the third message queue to the user at regular time.
In at least one possible implementation manner, the second message queue and/or the third message queue refers to a message queue abstracted by a database.
In at least one possible implementation, the voting statistics include the number of participating users, the number of votes obtained for each voting choice, the number of winners and losers based on the number of votes obtained, and the number of virtual assets awarding the winners.
In at least one possible implementation manner, the voting campaign configuration comprises a set result publishing time;
the voting statistic module specifically comprises:
the timing scanning unit is used for regularly scanning whether the result publishing time is reached or not according to a set scanning period;
and the time judging unit is used for judging that the preset time is reached if the output of the timing scanning unit is yes.
It should be understood that the division of each component in the web page voting data processing device shown in fig. 2 is merely a division of logical functions, and the actual implementation can be wholly or partially integrated into one physical entity or physically separated. And these components may all be implemented in software invoked by a processing element; or may be implemented entirely in hardware; and part of the components can be realized in the form of calling by the processing element in software, and part of the components can be realized in the form of hardware. For example, a certain module may be a separate processing element, or may be integrated into a certain chip of the electronic device. Other components are implemented similarly. In addition, all or part of the components can be integrated together or can be independently realized. In implementation, each step of the above method or each component above may be implemented by an integrated logic circuit of hardware in a processor element or an instruction in the form of software.
For example, the above components may be one or more integrated circuits configured to implement the above methods, such as: one or more Application Specific Integrated Circuits (ASICs), one or more microprocessors (DSPs), one or more Field Programmable Gate Arrays (FPGAs), etc. For another example, these components may be integrated together and implemented in the form of a System-On-a-Chip (SOC).
In view of the foregoing examples and their preferred embodiments, it will be appreciated by those skilled in the art that in practice, the invention may be practiced in a variety of embodiments, and that the invention is illustrated schematically in the following vectors:
(1) a web page voting data processing apparatus, which may comprise:
one or more processors, memory, and one or more computer programs, wherein the one or more computer programs are stored in the memory, the one or more computer programs comprising instructions, which when executed by the apparatus, cause the apparatus to perform the steps/functions of the foregoing embodiments or equivalent implementations.
The device may be an electronic device or a circuit device built in the electronic device. The electronic device can be a PC, a server, a smart terminal (a mobile phone, a tablet, etc.), and the like. The embodiment does not limit the specific form of the web page voting data processing device.
(2) A readable storage medium, on which a computer program or the above-mentioned apparatus is stored, which, when executed, causes the computer to perform the steps/functions of the above-mentioned embodiments or equivalent implementations.
In the several embodiments provided by the present invention, any function, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in a computer readable storage medium. Based on this understanding, some aspects of the present invention may be embodied in the form of software products, which are described below, or portions thereof, which substantially contribute to the art.
(3) A computer program product (which may include the above apparatus) which, when run on a terminal device, causes the terminal device to execute the web voting data processing method of the foregoing embodiment or equivalent embodiments.
From the above description of the embodiments, it is clear to those skilled in the art that all or part of the steps in the above implementation method can be implemented by software plus a necessary general hardware platform. With this understanding, the above-described computer program products may include, but are not limited to, refer to APP; continuing on, the aforementioned device/terminal may be a computer device (e.g., a mobile phone, a PC terminal, a cloud platform, a server cluster, or a network communication device such as a media gateway). Moreover, the hardware structure of the computer device may further specifically include: at least one processor, at least one communication interface, at least one memory, and at least one communication bus; the processor, the communication interface and the memory can all complete mutual communication through the communication bus. The processor may be a central Processing unit CPU, a DSP, a microcontroller, or a digital Signal processor, and may further include a GPU, an embedded Neural Network Processor (NPU), and an image Signal processor (lmage Signal Processing; lSP), and may further include a specific integrated circuit ASIC, or one or more integrated circuits configured to implement the embodiments of the present invention, and the processor may further have a function of operating one or more software programs, and the software programs may be stored in a storage medium such as a memory; and the aforementioned memory/storage media may comprise: non-volatile memories (non-volatile memories) such as non-removable magnetic disks, U-disks, removable hard disks, optical disks, etc., and Read-Only memories (ROM), Random Access Memories (RAM), etc.
In the embodiments of the present invention, "at least one" means one or more, "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, and means that there may be three relationships, for example, a and/or B, and may mean that a exists alone, a and B exist simultaneously, and B exists alone. Wherein A and B can be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" and similar expressions refer to any combination of these items, including any combination of singular or plural items. For example, at least one of a, b, and c may represent: a, b, c, a and b, a and c, b and c or a and b and c, wherein a, b and c can be single or multiple.
Those of skill in the art will appreciate that the various modules, elements, and method steps described in the embodiments disclosed in this specification can be implemented as electronic hardware, combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In addition, the embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments may be referred to each other. In particular, for embodiments of devices, apparatuses, etc., since they are substantially similar to the method embodiments, reference may be made to some of the descriptions of the method embodiments for their relevant points. The above-described embodiments of devices, apparatuses, etc. are merely illustrative, and modules, units, etc. described as separate components may or may not be physically separate, and may be located in one place or distributed in multiple places, for example, on nodes of a system network. Some or all of the modules and units can be selected according to actual needs to achieve the purpose of the above-mentioned embodiment. Can be understood and carried out by those skilled in the art without inventive effort.
The structure, features and effects of the present invention have been described in detail with reference to the embodiments shown in the drawings, but the above embodiments are merely preferred embodiments of the present invention, and it should be understood that technical features related to the above embodiments and preferred modes thereof can be reasonably combined and configured into various equivalent schemes by those skilled in the art without departing from and changing the design idea and technical effects of the present invention; therefore, the invention is not limited to the embodiments shown in the drawings, and all the modifications and equivalent embodiments that can be made according to the idea of the invention are within the scope of the invention as long as they are not beyond the spirit of the description and the drawings.

Claims (10)

1. A webpage voting data processing method is characterized by comprising the following steps:
writing voting activity configuration stored in a database in advance into a cache;
taking out the voting activity configuration from the cache, and generating a voting activity webpage for showing to a user;
continuously monitoring and receiving voting request data input by a user on the voting event page;
writing the voting request data into a first message queue;
regularly writing the voting request data in the first message queue into a database;
after the preset time is reached, extracting the voting request data from a database, and carrying out voting statistics;
writing the voting statistical data into a second message queue;
extracting the voting statistical data from the second message queue at regular time, and matching the voting statistical data with the personal information of the users in the voting request data to obtain the final voting result of the corresponding users;
writing the final voting result into a third message queue;
and pushing the final voting result in the third message queue to a user at regular time.
2. The method for processing webpage voting data according to claim 1, wherein the writing of the voting statistical data into the second message queue refers to writing the voting statistical result data into a database, wherein the second message queue refers to a message queue abstracted from the database; and/or
The writing of the final voting result into a third message queue refers to writing the voting result into a database, where the third message queue refers to a message queue abstracted from the database.
3. A web voting data processing method according to claim 1, wherein the voting statistics include the number of participating users, the number of votes obtained for each voting choice, the number of winners and losers based on the number of votes obtained, and the number of virtual assets awarding the winners.
4. A web voting data processing method according to any one of claims 1 to 3, wherein the voting campaign configuration comprises a set result publication time;
the reaching of the preset time comprises:
scanning whether the result publishing time is reached or not at regular time according to a set scanning period;
if yes, the preset time is judged to be reached.
5. A web voting data processing apparatus, comprising:
the buffer voting activity configuration module is used for writing the voting activity configuration stored in the database in advance into a buffer;
the activity webpage rendering module is used for taking out the voting activity configuration from the cache and generating a voting activity webpage for showing to a user;
the voting request acquisition module is used for continuously monitoring and receiving voting request data input by a user on the voting event page;
the first writing module is used for writing the voting request data into a first message queue;
the voting request storage module is used for regularly writing the voting request data in the first message queue into a database;
the voting counting module is used for extracting the voting request data from the database after the preset time is reached and carrying out voting counting;
the second writing module is used for writing the voting statistical data into a second message queue;
a final result generation module, configured to extract the voting statistical data from the second message queue at regular time, and match the voting statistical data with the user personal information in the voting request data to obtain a final voting result of the corresponding user;
a third writing module, configured to write the final voting result into a third message queue;
and the result publishing module is used for regularly pushing the final voting result in the third message queue to the user.
6. The apparatus for processing webpage voting data according to claim 5, wherein the second message queue and/or the third message queue refers to a message queue abstracted from a database.
7. A web voting data processing apparatus according to claim 5, wherein the voting statistics include the number of participating users, the number of votes obtained for each voting choice, the number of winning and losing parties based on the number of votes obtained, and the number of virtual assets awarding the winning party.
8. A web voting data processing apparatus according to any one of claims 5 to 7, wherein the voting campaign configuration comprises a set result publication time;
the voting statistic module specifically comprises:
the timing scanning unit is used for regularly scanning whether the result publishing time is reached or not according to a set scanning period;
and the time judging unit is used for judging that the preset time is reached if the output of the timing scanning unit is yes.
9. A computer-readable storage medium, in which a computer program is stored, which, when run on a computer, causes the computer to execute the web page voting data processing method according to any one of claims 1 to 4.
10. A web voting data processing apparatus, comprising:
one or more processors, memory, and one or more computer programs, wherein the one or more computer programs are stored in the memory, the one or more computer programs comprising instructions which, when executed by the apparatus, cause the apparatus to perform the method of web page voting data processing according to any one of claims 1 to 4.
CN202010976529.2A 2020-09-15 2020-09-15 Webpage voting data processing method, device and equipment Active CN112131496B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010976529.2A CN112131496B (en) 2020-09-15 2020-09-15 Webpage voting data processing method, device and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010976529.2A CN112131496B (en) 2020-09-15 2020-09-15 Webpage voting data processing method, device and equipment

Publications (2)

Publication Number Publication Date
CN112131496A true CN112131496A (en) 2020-12-25
CN112131496B CN112131496B (en) 2024-04-12

Family

ID=73845927

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010976529.2A Active CN112131496B (en) 2020-09-15 2020-09-15 Webpage voting data processing method, device and equipment

Country Status (1)

Country Link
CN (1) CN112131496B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113034207A (en) * 2021-04-20 2021-06-25 青岛冠成软件有限公司 Lottery information processing method, device, server and readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020129296A1 (en) * 2001-03-08 2002-09-12 Kwiat Kevin A. Method and apparatus for improved security in distributed-environment voting
CN103955984A (en) * 2014-03-24 2014-07-30 广州华多网络科技有限公司 Method, server, voting processing node and system for achieving interconnection network voting
CN111045806A (en) * 2019-12-16 2020-04-21 云南优鸟科技有限公司 Method and system for realizing delay message queue
CN111104235A (en) * 2019-12-06 2020-05-05 江苏苏宁物流有限公司 Queue-based asynchronous processing method and device for service requests

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020129296A1 (en) * 2001-03-08 2002-09-12 Kwiat Kevin A. Method and apparatus for improved security in distributed-environment voting
CN103955984A (en) * 2014-03-24 2014-07-30 广州华多网络科技有限公司 Method, server, voting processing node and system for achieving interconnection network voting
CN111104235A (en) * 2019-12-06 2020-05-05 江苏苏宁物流有限公司 Queue-based asynchronous processing method and device for service requests
CN111045806A (en) * 2019-12-16 2020-04-21 云南优鸟科技有限公司 Method and system for realizing delay message queue

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
奔跑吧笨笨: "基于redis的高并发投票设计", pages 1 - 6, Retrieved from the Internet <URL:https://blog.csdn.net/qq_37837134/article/details/80151171> *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113034207A (en) * 2021-04-20 2021-06-25 青岛冠成软件有限公司 Lottery information processing method, device, server and readable storage medium

Also Published As

Publication number Publication date
CN112131496B (en) 2024-04-12

Similar Documents

Publication Publication Date Title
CN106407190B (en) Event record query method and device
CN105022670B (en) Heterogeneous distributed task processing system and its processing method in a kind of cloud computing platform
CN106598735B (en) A kind of distributed computing method, main controlled node and computing system
CN108492150B (en) Method and system for determining entity heat degree
CN111651510A (en) Data processing method and device, electronic equipment and computer readable storage medium
CN106815254A (en) A kind of data processing method and device
CN112581178A (en) Rights and interests issuing method and device, electronic equipment and computer readable medium
CN115150471B (en) Data processing method, apparatus, device, storage medium, and program product
CN112131496A (en) Webpage voting data processing method, device and equipment
CN106484459A (en) It is applied to flow control method and the device of JavaScript
CN111210340A (en) Automatic task processing method and device, server and storage medium
CN113360581A (en) Data processing method, device and storage medium
CN113760983A (en) Data processing method, system and non-transitory computer readable storage medium
CN111104384A (en) Data preprocessing method, device, equipment and storage medium
CN115563160A (en) Data processing method, data processing device, computer equipment and computer readable storage medium
CN109214874B (en) IP product operation data processing method, device, equipment and readable storage medium
CN104615763B (en) Middle table updating method and device
CN112162988A (en) Distributed transaction processing method and device and electronic equipment
CN111352924A (en) Method and device for solving data tilt problem
CN110413499A (en) Information on services monitoring method, device, equipment and storage medium
CN110430263B (en) Value added service processing system and method
CN111314440A (en) Ring detection method and system on graph structure data
CN112491589B (en) Object storage network early warning method, system, terminal and storage medium
CN111563091B (en) Method and system for batch updating MongoDB in non-round-trip mode
CN115408061B (en) Hardware acceleration method, device, chip and storage medium for complex matrix operation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant