CN116846980A - Integral issuing and using method, system and equipment - Google Patents

Integral issuing and using method, system and equipment Download PDF

Info

Publication number
CN116846980A
CN116846980A CN202311112218.1A CN202311112218A CN116846980A CN 116846980 A CN116846980 A CN 116846980A CN 202311112218 A CN202311112218 A CN 202311112218A CN 116846980 A CN116846980 A CN 116846980A
Authority
CN
China
Prior art keywords
integral
user
data
point
request
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
CN202311112218.1A
Other languages
Chinese (zh)
Other versions
CN116846980B (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.)
Suzhou Yingtiandi Information Technology Co ltd
Original Assignee
Suzhou Yingtiandi Information 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 Suzhou Yingtiandi Information Technology Co ltd filed Critical Suzhou Yingtiandi Information Technology Co ltd
Priority to CN202311112218.1A priority Critical patent/CN116846980B/en
Publication of CN116846980A publication Critical patent/CN116846980A/en
Application granted granted Critical
Publication of CN116846980B publication Critical patent/CN116846980B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/018Certifying business or products
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0224Discounts or incentives, e.g. coupons or rebates based on user history
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0226Incentive systems for frequent usage, e.g. frequent flyer miles programs or point systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles
    • H04L67/306User profiles
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/54Presence management, e.g. monitoring or registration for receipt of user log-on information, or the connection status of the users
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/40Network security protocols

Abstract

The application relates to the technical field of Internet and discloses a method, a system and equipment for issuing and using an integral. The method of the application comprises the following steps: when receiving the integral operation request, authenticating the user identity corresponding to the integral operation request; after passing the authentication, generating a request data packet according to the integral operation request; transmitting the request data packet to a first message queue; acquiring a request data packet from a first message queue, and further generating corresponding integral data; updating the point balance of the corresponding user in the first database according to the point data; the corresponding system comprises an authentication module, a first generation module, a sending module, an acquisition module, a second generation module and an updating module. By introducing the message queue, the application can actively read the request data packet from the message queue in the integral management process, effectively lighten the pressure of the subsequent integral management, reduce the coupling degree of the system and ensure that the system can normally operate under the condition of high concurrency.

Description

Integral issuing and using method, system and equipment
Technical Field
The present application relates to the field of internet technologies, and in particular, to a method, a system, and an apparatus for issuing and using points.
Background
The issuance and use of points is accomplished in conventional application systems by operating the database in synchronization, in which the user's point balance is maintained as a piece of data. When the condition is met, the system synchronously locks corresponding pieces of data in the database, starts the transaction, increases the point balance of the corresponding pieces of data and submits the transaction, and the point release is completed; when the point is used, a user initiates a request to the system, the system synchronously locks corresponding data, starts a transaction, submits the transaction after the point balance of the corresponding data is reduced, finishes the use of the point at the moment, and then sends feedback information to inform the user of the point use result.
The distribution and use modes of the integration are simple to realize, have low complexity, and are suitable for application systems with small user scale and low system concurrency. In this way, however, if there are a large number of requests for points to be issued or used in a short time, a system crash may be caused; in addition, the credit balance data is easy to be hacked or tampered maliciously by others in the process of credit release and use, so that the security is poor.
Disclosure of Invention
The application provides a method, a system and equipment for issuing and using an integral, which solve the technical problem that the existing scheme for issuing and using the integral is difficult to respond to a large number of requests efficiently.
The first aspect of the present application provides a method for issuing and using an integral, comprising:
when receiving an integral operation request, authenticating a user identity corresponding to the integral operation request; the types of the integral operation requests comprise an integral issuing request and an integral using request;
after passing the authentication, generating a request data packet according to the integral operation request;
transmitting the request data packet to a first message queue;
acquiring a request data packet from the first message queue;
generating corresponding integral data according to the acquired request data packet;
updating the point balance of the corresponding user in the first database according to the point data; the first database stores point balance data of a plurality of registered users.
According to one implementation manner of the first aspect of the present application, the integration operation request carries a user identifier and an integration service type identifier, and the authenticating the user identity corresponding to the integration operation request includes:
verifying whether the user corresponding to the user identifier is a registered user or not;
if the user corresponding to the user identifier is a registered user, acquiring historical point acquisition data according to the user identifier;
calling an integral acquisition condition corresponding to the integral service type identifier;
and judging whether the user corresponding to the user identifier meets the integral acquisition condition according to the historical integral acquisition data, and if so, passing authentication.
According to one implementation manner of the first aspect of the present application, the request packet carries a user identifier, a type identifier of an integral operation request, an integral service type identifier and user behavior data, and the generating corresponding integral data according to the acquired request packet includes:
calling an integral calculation rule of the corresponding integral service according to the integral service type identifier;
calculating the integral updating quantity of the corresponding user according to the integral calculation rule according to the user behavior data; the point calculation rule calculates the point update amount based on the behavior type of the user behavior in the user behavior data;
and generating corresponding point data according to the user identification, the point updating quantity and the type identification of the point operation request.
According to one implementation manner of the first aspect of the present application, the calculating, according to the user behavior data and the integral calculation rule, an integral update amount of a corresponding user includes:
determining the behavior type of the user behavior in the user behavior data;
matching the point update amount of the corresponding user behavior from the point update amount mapping table based on the determined behavior type; the integral updating amount mapping table stores a mapping relation between behavior types and integral updating amounts;
and obtaining the integral updating quantity of the corresponding user according to the integral updating quantity of the user behavior obtained by matching.
According to one manner that the first aspect of the present application can be implemented, the method further includes:
after the point balance of the corresponding user in the first database is updated according to the point data, a corresponding point balance update notification message is generated;
pushing the point balance update notification message to the corresponding user through a second message queue.
According to one manner that the first aspect of the present application can be implemented, the method further includes:
after generating corresponding integral data according to the acquired request data packet, storing the generated integral data in a second database, and adding a tag to indicate that the corresponding integral data is not processed;
after updating the credit balance of the corresponding user in the first database according to the credit data, the label of the corresponding credit data in the second database is modified to indicate that the corresponding credit data has been processed.
According to an implementation manner of the first aspect of the present application, the second database stores integration data in partitions according to user identities, where each partition records a credibility of a corresponding user identity, and the method further includes:
before storing the generated integral data into a second database, judging whether target integral data consistent with user identity exists in the second database according to the generated integral data;
if the integrated data exists, calculating a data storage time difference between the generated integrated data and the target integrated data closest to the current time;
if the calculated data storage time difference is smaller than a preset time difference threshold value, subtracting 1 from the credibility of the identity of the corresponding user;
when the credibility of the user identity is lower than a preset credibility threshold, corresponding early warning information is output.
A second aspect of the present application provides an integral issuance and use system comprising:
the authentication module is used for authenticating the user identity corresponding to the integral operation request when the integral operation request is received; the types of the integral operation requests comprise an integral issuing request and an integral using request;
the first generation module is used for generating a request data packet according to the integral operation request after the authentication is passed;
the sending module is used for sending the request data packet to a first message queue;
the acquisition module is used for acquiring a request data packet from the first message queue;
the second generation module is used for generating corresponding integral data according to the acquired request data packet;
the updating module is used for updating the point balance of the corresponding user in the first database according to the point data; the first database stores point balance data of a plurality of registered users.
According to one implementation manner of the second aspect of the present application, the integration operation request carries a user identifier and an integration service type identifier, and the authentication module includes:
the verification unit is used for verifying whether the user corresponding to the user identifier is a registered user or not;
the acquisition unit is used for acquiring historical integral acquisition data according to the user identification if the user corresponding to the user identification is a registered user;
the first calling unit is used for calling the integral receiving condition corresponding to the integral service type identifier;
and the judging unit is used for judging whether the user corresponding to the user identifier meets the integral acquisition condition according to the historical integral acquisition data, and if so, the authentication is passed.
According to one implementation manner of the second aspect of the present application, the request packet carries a user identifier, a type identifier of an integral operation request, an integral service type identifier, and user behavior data, and the second generating module includes:
the second calling unit is used for calling the integral calculation rule of the corresponding integral service according to the integral service type identifier;
the calculation unit is used for calculating the integral updating quantity of the corresponding user according to the integral calculation rule according to the user behavior data; the point calculation rule calculates the point update amount based on the behavior type of the user behavior in the user behavior data;
and the generating unit is used for generating corresponding point data according to the user identification, the point updating quantity and the type identification of the point operation request.
According to one possible implementation manner of the second aspect of the present application, the computing unit is specifically configured to:
determining the behavior type of the user behavior in the user behavior data;
matching the point update amount of the corresponding user behavior from the point update amount mapping table based on the determined behavior type; the integral updating amount mapping table stores a mapping relation between behavior types and integral updating amounts;
and obtaining the integral updating quantity of the corresponding user according to the integral updating quantity of the user behavior obtained by matching.
According to one manner in which the second aspect of the application can be implemented, the system further comprises:
the third generation module is used for generating a corresponding point balance update notification message after updating the point balance of the corresponding user in the first database according to the point data;
and the pushing module is used for pushing the point balance update notification message to the corresponding user through a second message queue.
According to one manner in which the second aspect of the application can be implemented, the system further comprises:
the storage module is used for storing the generated integral data into the second database after generating corresponding integral data according to the acquired request data packet, and adding a label to indicate that the corresponding integral data is not processed;
and the modification module is used for modifying the label of the corresponding point data in the second database after updating the point balance of the corresponding user in the first database according to the point data so as to indicate that the corresponding point data is processed.
According to one implementation manner of the second aspect of the present application, the second database stores integration data in partitions according to user identities, and each partition records the credibility of the corresponding user identity, and the system further includes:
the judging module is used for judging whether target integral data with consistent user identity exists in the second database aiming at the generated integral data before the generated integral data is stored in the second database;
the calculation module is used for calculating the data storage time difference between the generated integral data and the target integral data closest to the current time if the integral data exist;
the credibility processing module is used for subtracting the credibility of the identity of the corresponding user by 1 if the calculated data storage time difference is smaller than a preset time difference threshold;
and the output module is used for outputting corresponding early warning information when the reliability of the user identity is lower than a preset reliability threshold value.
A third aspect of the present application provides an integral issuing and using apparatus comprising:
a memory for storing instructions; wherein, the instructions are used for realizing the integral issuing and using method in any mode which can be realized;
and the processor is used for executing the instructions in the memory.
A fourth aspect of the present application is a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method of issuing and using an integral as can be implemented by any one of the above.
From the above technical scheme, the application has the following advantages:
the method of the application comprises the following steps: when receiving an integral operation request, authenticating a user identity corresponding to the integral operation request; after passing the authentication, generating a request data packet according to the integral operation request; transmitting the request data packet to a first message queue; acquiring a request data packet from the first message queue; generating corresponding integral data according to the acquired request data packet; updating the point balance of the corresponding user in the first database according to the point data; the first database stores point balance data of a plurality of registered users; the corresponding system comprises an authentication module, a first generation module, a sending module, an acquisition module, a second generation module and an updating module; according to the application, the message queue is introduced, so that the request data packet can be actively read from the message queue in the integral management process, the pressure for carrying out the subsequent integral management is effectively reduced, the downtime condition of the system is reduced, the coupling degree of the system is reduced, and the system can be ensured to normally operate under the condition of high concurrency.
Drawings
In order to more clearly illustrate the embodiments of the application or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, it being obvious that the drawings in the following description are only some embodiments of the application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method of credit release and use provided in an alternative embodiment of the application;
FIG. 2 is a flow chart of a method of credit release and use provided in another alternative embodiment of the application;
FIG. 3 is a flow chart of a method of credit release and use provided in accordance with yet another alternative embodiment of the application;
FIG. 4 is a flow chart of a method of credit release and use provided in accordance with yet another alternative embodiment of the application;
FIG. 5 is a block diagram showing the structural connections of an integral issuance and utilization system according to an alternative embodiment of the present application;
FIG. 6 is a block diagram showing the structural connections of an integration distribution and use system according to another alternative embodiment of the present application;
FIG. 7 is a block diagram showing the structural connections of an integration distribution and use system according to yet another alternative embodiment of the present application;
fig. 8 is a block diagram showing the structural connection of an integration distribution and use system according to still another alternative embodiment of the present application.
Reference numerals:
1-an authentication module; 2-a first generation module; 3-a transmitting module; 4-an acquisition module; 5-a second generation module; 6-updating the module; 7-a third generation module; 8-pushing module; 9-a memory module; 10-modifying the module; 11-a judging module; 12-a calculation module; 13-a credibility processing module; 14-an output module.
Description of the embodiments
The embodiment of the application provides a method, a system and equipment for issuing and using an integral, which are used for solving the technical problem that the existing scheme for issuing and using the integral is difficult to respond to a large number of requests efficiently.
In order to make the objects, features and advantages of the present application more comprehensible, the technical solutions in the embodiments of the present application are described in detail below with reference to the accompanying drawings, and it is apparent that the embodiments described below are only some embodiments of the present application, but not all embodiments of the present application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The application provides a method for issuing and using an integral.
Referring to fig. 1, fig. 1 is a flowchart illustrating a method for issuing and using an integral according to an embodiment of the present application.
The integral issuing and using method provided by the embodiment of the application comprises the steps S1-S6.
Step S1, when an integral operation request is received, authenticating a user identity corresponding to the integral operation request; the types of the point operation request include a point issue request and a point use request.
Wherein, an integration interface module can be arranged to provide an interface for the user terminal, comprising an integration issuing interface and an integration using interface, and the integration operation request is received when the interface is called.
As an implementation manner, the authentication of the user identity corresponding to the integration operation request may be performed according to a preset user name and password. The user name and password may also be the user name and password of an operator in the user in the execution system of the method according to the application.
In the embodiment of the application, the reliability of the integral management is enhanced by authenticating the user identity corresponding to the integral operation request.
As another embodiment, the integration operation request carries a user identifier and an integration service type identifier, and the authentication of the user identity corresponding to the integration operation request includes:
verifying whether the user corresponding to the user identifier is a registered user or not;
if the user corresponding to the user identifier is a registered user, acquiring historical point acquisition data according to the user identifier;
calling an integral receiving condition corresponding to the integral service type identifier;
and judging whether the user corresponding to the user identifier meets the integral acquisition condition according to the historical integral acquisition data, and if so, passing the authentication.
When verifying whether the user corresponding to the user identifier is a registered user, the registered user identifier list stored in the user identifier may be matched, and whether the user corresponding to the user identifier is a registered user may be determined according to the matching result.
Wherein, the point acquisition conditions corresponding to different point service type identifiers can be set according to the actual conditions of the point service environments. For example, the point acquisition condition may be set to include that the accumulated acquired point does not exceed a preset point threshold value within the year, so that the identity authentication of the user is determined to pass when the accumulated acquired point does not exceed the preset point threshold value within the year of the user. For another example, the point acquisition condition may be set to include that the user can acquire the points only a preset number of times each year, and if the user does not acquire the points in the present year, the user is determined to be the user who meets the point acquisition condition, and then the identity authentication of the user can be determined to pass.
In the embodiment of the application, when the user identity corresponding to the integral operation request is authenticated, the identity authentication is realized according to whether the user is a registered user or not and whether the user meets the integral acquisition condition or not in a two-layer screening mode, so that the accuracy of integral issuing and using can be improved, meanwhile, the processing of the integral operation request which does not meet the requirements is avoided, the pressure of integral management can be effectively reduced, the downtime condition of a system for executing the method is reduced, and the fault tolerance of the system for executing the method is improved.
And S2, after the authentication is passed, generating a request data packet according to the integral operation request.
Step S3, the request data packet is sent to a first message queue.
In the embodiment of the application, the data to be transmitted is placed in the message queue, and the data transmission can be realized by using a mechanism of the message queue. Because the message queue is a first-in first-out data unit, the request data packet is written into the message queue, and when the request data packet is read from the message queue later, the first-in request data packet is read first, so that the sequential processing of the request data packet is ensured. When a large number of integration operation requests occur in a short time, the integration messages are temporarily stored in the message queues due to the existence of the message queues, and then the request data packets are processed as required by a system executing the method. Therefore, the system can normally operate under the condition of high concurrency, and cannot be down.
Step S4, obtaining the request data packet from the first message queue.
Wherein the acquisition of the request packet is performed in chronological order.
And S5, generating corresponding integral data according to the acquired request data packet.
In one implementation manner, the request packet carries a user identifier, a type identifier of an integral operation request, an integral service type identifier and user behavior data, and the generating of corresponding integral data according to the acquired request packet includes:
calling a corresponding integral calculation rule of the integral service according to the integral service type identifier;
calculating the integral updating quantity of the corresponding user according to the integral calculation rule according to the user behavior data; the point calculation rule calculates the point update amount based on the behavior type of the user behavior in the user behavior data;
and generating corresponding point data according to the user identification, the point updating quantity and the type identification of the point operation request.
The user behavior data may be data such as user login times, user birthdays, user shopping lines, user exchange article information, and the like.
And setting point calculation rules corresponding to different point service type identifiers according to the actual conditions of the point service environments, wherein each point calculation rule needs to calculate the point update amount based on the behavior type of the user behavior in the user behavior data. For example, when the user behavior data is 5 times of user login, the amount of point update to be given when the number of times of user login is 5 times is calculated according to the point calculation rule, and the behavior type is determined to be login behavior based on the user behavior data. For example, when the user behavior data is a point exchange behavior, the point update amount of the corresponding user is calculated according to the point calculation rule, and the behavior type is determined to be the point exchange behavior according to the user behavior data.
The specific calculation mode of the integral update amount under each login behavior type can be set according to actual conditions, for example, a corresponding calculation formula can be set to calculate the integral update amount, an integral update amount query list is set to query the integral update amount, and the like. The calculation formula and the integral update amount query list can be designed by a person skilled in the art according to the actual service scene, and are not repeated.
In one implementation, calculating an amount of point update for a corresponding user according to a point calculation rule based on user behavior data includes:
determining a behavior type of the user behavior in the user behavior data;
matching the point update amount of the corresponding user behavior from the point update amount mapping table based on the determined behavior type; the integral updating amount mapping table stores a mapping relation between behavior types and integral updating amounts;
and obtaining the integral updating quantity of the corresponding user according to the integral updating quantity of the user behavior obtained by matching.
In the embodiment of the application, the quick query determination of the integral updating quantity is realized by setting the integral updating quantity mapping table, which is beneficial to improving the management efficiency of integral issuing/using.
The type identifier of the integral operation request can determine whether to deduct the integral updating amount or increase the integral updating amount when updating the integral balance of the corresponding user in the first database, so as to facilitate the execution of the subsequent steps, and when corresponding integral data is generated according to the user identifier, the integral updating amount and the type identifier of the integral operation request, a label can be added to the integral updating amount in the integral data to indicate whether the integral updating is integral deduction or integral increase.
S6, updating the point balance of the corresponding user in the first database according to the point data; the first database stores therein point balance data for a plurality of registered users.
In one implementation, on the basis of the method shown in fig. 1, as shown in fig. 2, the method further includes:
step S7, after the point balance of the corresponding user in the first database is updated according to the point data, a corresponding point balance update notification message is generated;
and S8, pushing the point balance update notification message to the corresponding user through a second message queue.
In the embodiment of the application, the notification of the point balance update is realized through the message queue, so that the coupling degree of the system can be improved, and the system can be ensured to normally operate under the condition of high concurrency.
In one implementation, on the basis of the method shown in fig. 2, as shown in fig. 3, the method further includes:
step S9, after generating corresponding integral data according to the acquired request data packet, storing the generated integral data in a second database, and adding a label to indicate that the corresponding integral data is not processed;
step S10, after updating the point balance of the corresponding user in the first database according to the point data, the label of the corresponding point data in the second database is modified to indicate that the corresponding point data has been processed.
In the embodiment of the application, after the integral data is read, the integral data is stored in the second database, which is equivalent to the backup of the integral data, so that even if the condition of downtime occurs during the execution of the subsequent steps, the integral data can be prevented from being lost; in addition, after the integral data is stored in the second database, the state of the integral data is recorded, so that the integral data which are processed and the integral data which are not processed can be clearly known, and the integral management can be more accurately performed.
In one implementation manner, the second database stores the integral data in a partition according to the user identity, and each partition records the credibility of the corresponding user identity, and on the basis of the method shown in fig. 3, as shown in fig. 4, the method further includes:
step S11, before the generated integral data is stored in the second database, judging whether target integral data with consistent user identity exists in the second database according to the generated integral data;
step S12, if the integrated data exist, calculating the data storage time difference between the generated integrated data and the target integrated data closest to the current time;
step S13, if the calculated data storage time difference is smaller than a preset time difference threshold, subtracting 1 from the reliability of the identity of the corresponding user;
step S14, when the credibility of the user identity is lower than a preset credibility threshold, corresponding early warning information is output.
According to the embodiment of the application, the operation behavior of the user is monitored based on the integral data, when the credibility of the user identity is lower than the preset credibility threshold value, corresponding early warning information is output, and an administrator of the integral issuing and using system can find out the unreasonable behavior of the user in time, so that corresponding protection measures can be executed in advance, and the safety of integral management is improved.
The application also provides a system for issuing and using the points, which can be used for executing the method for issuing and using the points according to any one of the embodiments of the application.
Referring to fig. 5, fig. 5 is a block diagram showing structural connection of an integration distribution and use system according to an embodiment of the present application.
The system for issuing and using the integration provided by the embodiment of the application comprises the following components:
the authentication module 1 is used for authenticating the user identity corresponding to the integral operation request when the integral operation request is received; the types of the point operation requests include a point issue request and a point use request;
the first generation module 2 is used for generating a request data packet according to the integral operation request after the authentication is passed;
a sending module 3, configured to send a request packet to a first message queue;
an obtaining module 4, configured to obtain a request packet from the first message queue;
a second generating module 5, configured to generate corresponding integral data according to the acquired request data packet;
the updating module 6 is used for updating the point balance of the corresponding user in the first database according to the point data; the first database stores therein point balance data for a plurality of registered users.
In one possible implementation, the integration operation request carries a user identifier and an integration service type identifier, and the authentication module 1 includes:
the verification unit is used for verifying whether the user corresponding to the user identifier is a registered user or not;
the acquisition unit is used for acquiring historical point acquisition data according to the user identification if the user corresponding to the user identification is a registered user;
the first calling unit is used for calling the integral receiving condition corresponding to the integral service type identifier;
and the judging unit is used for judging whether the user corresponding to the user identifier meets the integral acquisition condition according to the historical integral acquisition data, and if so, the authentication is passed.
In one possible implementation, the request packet carries a user identifier, a type identifier of the integration operation request, an identifier of the integration service type, and user behavior data, and the second generating module 5 includes:
the second calling unit is used for calling the integral calculation rule of the corresponding integral service according to the integral service type identifier;
the calculation unit is used for calculating the integral update quantity of the corresponding user according to the integral calculation rule according to the user behavior data; the point calculation rule calculates the point update amount based on the behavior type of the user behavior in the user behavior data;
and the generating unit is used for generating corresponding point data according to the user identification, the point updating quantity and the type identification of the point operation request.
In one possible implementation, the computing unit is specifically configured to:
determining a behavior type of the user behavior in the user behavior data;
matching the point update amount of the corresponding user behavior from the point update amount mapping table based on the determined behavior type; the integral updating amount mapping table stores a mapping relation between behavior types and integral updating amounts;
and obtaining the integral updating quantity of the corresponding user according to the integral updating quantity of the user behavior obtained by matching.
In one manner of implementation, on the basis of the system shown in fig. 5, as shown in fig. 6, the system further includes:
the third generation module 7 is configured to generate a corresponding point balance update notification message after updating the point balance of the corresponding user in the first database according to the point data;
and the pushing module 8 is used for pushing the credit balance update notification message to the corresponding user through the second message queue.
In one manner of implementation, on the basis of the system shown in fig. 6, as shown in fig. 7, the system further includes:
a storage module 9, configured to store the generated integral data in the second database after generating corresponding integral data according to the acquired request data packet, and add a tag to indicate that the corresponding integral data is not processed;
a modifying module 10, configured to modify the label of the corresponding point data in the second database to indicate that the corresponding point data has been processed after updating the point balance of the corresponding user in the first database according to the point data.
In one implementation manner, the second database stores the integral data in a partition according to the user identity, each partition records the credibility of the corresponding user identity, and on the basis of the system shown in fig. 7, as shown in fig. 8, the system further includes:
the judging module 11 is configured to judge, for the generated integral data, whether target integral data with consistent user identity exists in the second database before the generated integral data is stored in the second database;
a calculation module 12, configured to calculate a data storage time difference between the generated integral data and the target integral data nearest to the current time, if any;
the credibility processing module 13 is configured to reduce the credibility of the corresponding user identity by 1 if the calculated data storage time difference is smaller than a preset time difference threshold;
and the output module 14 is used for outputting corresponding early warning information when the reliability of the user identity is lower than a preset reliability threshold value.
The application also provides an integral issuing and using device, which comprises:
a memory for storing instructions; wherein the instructions are configured to implement the method for issuing and using an integral as described in any one of the embodiments above;
and the processor is used for executing the instructions in the memory.
The present application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor implements the method of credit issuing and use according to any of the embodiments described above.
It will be clearly understood by those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses, modules and units may refer to corresponding procedures in the foregoing method embodiments, and specific beneficial effects of the above-described systems, modules and units may refer to corresponding beneficial effects in the foregoing method embodiments, which are not repeated herein.
In the several embodiments provided by the present application, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. For example, the system embodiments described above are merely illustrative, e.g., the division of the modules is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple modules or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with respect to each other may be through some interface, indirect coupling or communication connection of systems or modules, electrical, mechanical, or other form.
The modules described as separate components may or may not be physically separate, and components shown as modules may or may not be physical modules, i.e., may be located in one place, or may be distributed over a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional module in each embodiment of the present application may be integrated into one processing module, or each module may exist alone physically, or two or more modules may be integrated into one module. The integrated modules may be implemented in hardware or in software functional modules.
The integrated modules, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be embodied essentially or in part or all of the technical solution or in part in the form of a software product stored in a storage medium, including instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The above embodiments are only for illustrating the technical solution of the present application, and not for limiting the same; although the application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims (10)

1. A method of dispensing and using an integral, comprising:
when receiving an integral operation request, authenticating a user identity corresponding to the integral operation request; the types of the integral operation requests comprise an integral issuing request and an integral using request;
after passing the authentication, generating a request data packet according to the integral operation request;
transmitting the request data packet to a first message queue;
acquiring a request data packet from the first message queue;
generating corresponding integral data according to the acquired request data packet;
updating the point balance of the corresponding user in the first database according to the point data; the first database stores point balance data of a plurality of registered users.
2. The point issuing and using method according to claim 1, wherein the point operation request carries a user identifier and a point service type identifier, and the authenticating the user identity corresponding to the point operation request includes:
verifying whether the user corresponding to the user identifier is a registered user or not;
if the user corresponding to the user identifier is a registered user, acquiring historical point acquisition data according to the user identifier;
calling an integral acquisition condition corresponding to the integral service type identifier;
and judging whether the user corresponding to the user identifier meets the integral acquisition condition according to the historical integral acquisition data, and if so, passing authentication.
3. The point issuing and using method according to claim 1, wherein the request packet carries a user identifier, a type identifier of a point operation request, a point service type identifier, and user behavior data, and the generating corresponding point data according to the acquired request packet includes:
calling an integral calculation rule of the corresponding integral service according to the integral service type identifier;
calculating the integral updating quantity of the corresponding user according to the integral calculation rule according to the user behavior data; the point calculation rule calculates the point update amount based on the behavior type of the user behavior in the user behavior data;
and generating corresponding point data according to the user identification, the point updating quantity and the type identification of the point operation request.
4. The point issuing and using method according to claim 3, wherein the calculating the point update amount of the corresponding user according to the point calculation rule based on the user behavior data includes:
determining the behavior type of the user behavior in the user behavior data;
matching the point update amount of the corresponding user behavior from the point update amount mapping table based on the determined behavior type; the integral updating amount mapping table stores a mapping relation between behavior types and integral updating amounts;
and obtaining the integral updating quantity of the corresponding user according to the integral updating quantity of the user behavior obtained by matching.
5. The point of sale and use method of claim 1, further comprising:
after the point balance of the corresponding user in the first database is updated according to the point data, a corresponding point balance update notification message is generated;
pushing the point balance update notification message to the corresponding user through a second message queue.
6. The point of sale and use method of claim 1, further comprising:
after generating corresponding integral data according to the acquired request data packet, storing the generated integral data in a second database, and adding a tag to indicate that the corresponding integral data is not processed;
after updating the credit balance of the corresponding user in the first database according to the credit data, the label of the corresponding credit data in the second database is modified to indicate that the corresponding credit data has been processed.
7. The point issuing and use method according to claim 6, wherein the second database stores point data in sections according to user identities, each section having a record of credibility of a corresponding user identity, the method further comprising:
before storing the generated integral data into a second database, judging whether target integral data consistent with user identity exists in the second database according to the generated integral data;
if the integrated data exists, calculating a data storage time difference between the generated integrated data and the target integrated data closest to the current time;
if the calculated data storage time difference is smaller than a preset time difference threshold value, subtracting 1 from the credibility of the identity of the corresponding user;
when the credibility of the user identity is lower than a preset credibility threshold, corresponding early warning information is output.
8. An integral issuance and use system, comprising:
the authentication module is used for authenticating the user identity corresponding to the integral operation request when the integral operation request is received; the types of the integral operation requests comprise an integral issuing request and an integral using request;
the first generation module is used for generating a request data packet according to the integral operation request after the authentication is passed;
the sending module is used for sending the request data packet to a first message queue;
the acquisition module is used for acquiring a request data packet from the first message queue;
the second generation module is used for generating corresponding integral data according to the acquired request data packet;
the updating module is used for updating the point balance of the corresponding user in the first database according to the point data; the first database stores point balance data of a plurality of registered users.
9. An integral issuing and using apparatus, comprising:
a memory for storing instructions; wherein the instructions are for implementing the point issuance and use method according to any one of claims 1-7;
and the processor is used for executing the instructions in the memory.
10. A computer readable storage medium, wherein a computer program is stored on the computer readable storage medium, and when executed by a processor, the computer program implements the method of credit issuing and use as claimed in any one of claims 1 to 7.
CN202311112218.1A 2023-08-31 2023-08-31 Integral issuing and using method, system and equipment Active CN116846980B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311112218.1A CN116846980B (en) 2023-08-31 2023-08-31 Integral issuing and using method, system and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311112218.1A CN116846980B (en) 2023-08-31 2023-08-31 Integral issuing and using method, system and equipment

Publications (2)

Publication Number Publication Date
CN116846980A true CN116846980A (en) 2023-10-03
CN116846980B CN116846980B (en) 2024-02-13

Family

ID=88165589

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311112218.1A Active CN116846980B (en) 2023-08-31 2023-08-31 Integral issuing and using method, system and equipment

Country Status (1)

Country Link
CN (1) CN116846980B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117408748A (en) * 2023-12-13 2024-01-16 天津金城银行股份有限公司 Integral issuing method, system, computer equipment and readable storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2002011034A1 (en) * 2000-07-31 2002-02-07 Capital One Financial Corporation System and method for issuing and redeeming credit card reward points
CN101751635A (en) * 2008-12-22 2010-06-23 中国移动通信集团辽宁有限公司 Point reward exchanging system, device and method
CN108549965A (en) * 2018-03-02 2018-09-18 深圳市元征科技股份有限公司 Data processing method and data processing platform (DPP), server
CN108830632A (en) * 2018-04-24 2018-11-16 深圳市轱辘车联数据技术有限公司 A kind of integration managing method, block chain node device and client
CN111639965A (en) * 2020-05-15 2020-09-08 浙江口碑网络技术有限公司 Integral updating method and device
CN113409078A (en) * 2021-06-10 2021-09-17 杭州趣链科技有限公司 Point issuing method, device, equipment and storage medium
CN115525449A (en) * 2022-09-26 2022-12-27 昆仑数智科技有限责任公司 Micro-service data transmission system, method and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2002011034A1 (en) * 2000-07-31 2002-02-07 Capital One Financial Corporation System and method for issuing and redeeming credit card reward points
CN101751635A (en) * 2008-12-22 2010-06-23 中国移动通信集团辽宁有限公司 Point reward exchanging system, device and method
CN108549965A (en) * 2018-03-02 2018-09-18 深圳市元征科技股份有限公司 Data processing method and data processing platform (DPP), server
CN108830632A (en) * 2018-04-24 2018-11-16 深圳市轱辘车联数据技术有限公司 A kind of integration managing method, block chain node device and client
CN111639965A (en) * 2020-05-15 2020-09-08 浙江口碑网络技术有限公司 Integral updating method and device
CN113409078A (en) * 2021-06-10 2021-09-17 杭州趣链科技有限公司 Point issuing method, device, equipment and storage medium
CN115525449A (en) * 2022-09-26 2022-12-27 昆仑数智科技有限责任公司 Micro-service data transmission system, method and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117408748A (en) * 2023-12-13 2024-01-16 天津金城银行股份有限公司 Integral issuing method, system, computer equipment and readable storage medium
CN117408748B (en) * 2023-12-13 2024-04-09 天津金城银行股份有限公司 Integral issuing method, system, computer equipment and readable storage medium

Also Published As

Publication number Publication date
CN116846980B (en) 2024-02-13

Similar Documents

Publication Publication Date Title
US11966916B2 (en) Resource transfer method and apparatus, storage medium, and computer device
CN107480990B (en) Block chain accounting method and device
CN108734028B (en) Data management method based on block chain, block chain link point and storage medium
CN108199852B (en) Authentication method, authentication system and computer readable storage medium
CN116846980B (en) Integral issuing and using method, system and equipment
CN108768837A (en) Message treatment method and relevant apparatus
CN112541009B (en) Data query method, device, electronic equipment and storage medium
CN108366176A (en) A kind of charging method of terminal applies, apparatus and system
CN110941840B (en) Data processing method, system and terminal
CN113645278A (en) Cross-chain message transmission method, device and storage medium of block chain
CN112581110A (en) Fuel deduction method and device, electronic equipment and storage medium
CN108848501B (en) Number management method and device and server
US20200143382A1 (en) Method of transaction without physical support of a security identifier and without token, secured by the structural decoupling of the personal and service identifiers
CN110266475A (en) A kind of cloud storage data safety auditing method
CN112131267B (en) Count processing method, device, server and count processing system
CN111489252B (en) Deposit certification opening method and device based on alliance chain
CN109948362B (en) Data access processing method and system
CN115701078A (en) Cross-chain transaction processing method and device, electronic equipment and storage medium
CN111901299A (en) Application authentication method and device, electronic equipment and storage medium
CN115392912B (en) Random number generation method, system, device and storage medium
CN114338255B (en) Group management method and device
CN109871287A (en) Interface call method, device, computer installation and storage medium
CN113691534B (en) Identity authentication charging system and method
CN110009464B (en) Cross-time zone business processing method, server, computing device and storage medium
CN115934242A (en) Container monitoring method, device, equipment, system and storage medium

Legal Events

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