CN109040300B - Method, device and storage medium for pushing messages - Google Patents

Method, device and storage medium for pushing messages Download PDF

Info

Publication number
CN109040300B
CN109040300B CN201811027552.6A CN201811027552A CN109040300B CN 109040300 B CN109040300 B CN 109040300B CN 201811027552 A CN201811027552 A CN 201811027552A CN 109040300 B CN109040300 B CN 109040300B
Authority
CN
China
Prior art keywords
message
corresponding relation
cache
relation table
identification information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201811027552.6A
Other languages
Chinese (zh)
Other versions
CN109040300A (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.)
Aisino Corp
Original Assignee
Aisino Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Aisino Corp filed Critical Aisino Corp
Priority to CN201811027552.6A priority Critical patent/CN109040300B/en
Publication of CN109040300A publication Critical patent/CN109040300A/en
Application granted granted Critical
Publication of CN109040300B publication Critical patent/CN109040300B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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/50Network services
    • H04L67/55Push-based network services
    • 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/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching

Abstract

The present disclosure relates to a method, an apparatus, and a storage medium for pushing a message, which are used to solve the technical problem in the related art that the message pushing based on personalized requirements is difficult to fully use the existing cache resources, resulting in low cache utilization. The message pushing method comprises the following steps: acquiring attribute information of an account of a login platform server; inquiring the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information; and pushing a message corresponding to the identification information in the database to a client of the platform server logged in by the account according to the inquired identification information.

Description

Method, device and storage medium for pushing messages
Technical Field
The present disclosure relates to the field of internet technologies, and in particular, to a method, an apparatus, and a storage medium for pushing a message.
Background
In chinese patent application document No. 201611184661.X, a message pushing method is disclosed, the method comprising: when the cache queue meets a preset condition, acquiring a push message from a cache server; the cache server stores a push message generated and sent by the service server; caching the obtained push message to the cache queue; and pushing the push message in the cache queue to the client.
However, the technical solution disclosed in the above patent is applicable in a limited scenario, and for a message database with millions of data volumes, when there is a personalized demand for pushing messages according to a specific enterprise or a specific user, a relatively complex database SQL statement needs to be used, which easily causes a slow query of the database; for the individual requirements issued according to specific enterprises, the cache cannot be created according to regions and can only be created according to users, and the possibility of repeated login of the same user in a short time is very low, so that the cache utilization rate is low.
Disclosure of Invention
The present disclosure provides a method, an apparatus, and a storage medium for pushing a message, so as to solve the technical problem in the related art that the message pushing based on personalized requirements is difficult to fully use the existing cache resources, which results in low cache utilization.
In order to achieve the above object, in a first aspect of the embodiments of the present disclosure, a method for pushing a message is provided, where the method is applied to a platform server, and the method includes:
acquiring attribute information of an account logged in the platform server;
inquiring the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information;
and pushing a message corresponding to the identification information in the database to a client of the platform server logged in by the account according to the inquired identification information.
Optionally, the method further comprises:
and before acquiring the attribute information of the account logged in the platform server, creating a corresponding relation table and storing the corresponding relation table in a cache.
Optionally, the creating a correspondence table and storing the correspondence table in a cache includes:
inquiring whether a corresponding relation table exists in the cache or not;
when the corresponding relation table does not exist in the cache, locking the cache operation; when locking, forbidding other accounts to enter the platform server or inquiring the corresponding relation table;
analyzing the message data in the database to acquire the corresponding relation between the attribute information and the identification information of the message;
according to the analysis result, creating a corresponding relation table and storing the corresponding relation table in a cache;
and unlocking the cache operation.
Optionally, the method further comprises:
and after locking the cache operation, confirming that the corresponding relation table does not exist in the cache.
Optionally, before creating the correspondence table, the method further includes:
when the message data in the database are changed, setting an update mark;
periodically inquiring whether the updating mark exists; and when the update mark exists, creating a corresponding relation table.
Optionally, the attribute information includes a region number and an enterprise tax number corresponding to the account, and the identification information includes a number of the message.
In a second aspect of the disclosed embodiments, there is provided an apparatus for pushing a message, the apparatus including:
the acquisition module is used for acquiring the attribute information of the account logged in the platform server;
the query module is used for querying the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information;
and the pushing module is used for pushing the message corresponding to the identification information in the database to the account according to the inquired identification information.
Optionally, the method further comprises:
and the creating module is used for creating a corresponding relation table and storing the corresponding relation table in a cache before acquiring the attribute information of the account logged in the platform server.
Optionally, the creating module includes:
the query submodule is used for querying whether a corresponding relation table exists in the cache or not;
the locking submodule is used for locking the cache operation when the corresponding relation table does not exist in the cache; when locking, forbidding other accounts to enter the platform server or inquiring the corresponding relation table;
the analysis submodule is used for analyzing the message data in the database to acquire the corresponding relation between the attribute information and the identification information of the message;
the creating submodule is used for creating a corresponding relation table according to the analysis result and storing the corresponding relation table into a cache;
and the unlocking submodule is used for unlocking the cache operation.
Optionally, the creating module further comprises:
and the confirming submodule is used for confirming that the corresponding relation table does not exist in the cache after the cache operation is locked.
Optionally, the method further comprises:
the setting module is used for setting an update mark when the message data in the database is changed;
the regular query module is used for regularly querying whether the update mark exists; and when the update mark exists, the creating module executes the operation of creating the corresponding relation table.
In a third aspect of the embodiments of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored, which when executed by a processor implements the steps of the method of any one of the above first aspects.
In a fourth aspect of the embodiments of the present disclosure, an apparatus for pushing a message is provided, including:
a memory having a computer program stored thereon; and
a processor for executing the computer program in the memory to implement the steps of the method of any of the first aspects above.
By adopting the technical scheme, the following technical effects can be at least achieved:
according to the method and the device, the corresponding relation table of the attribute information and the identification information is set in the cache, when a user logs in a platform server, the identification information of the corresponding message can be inquired according to the attribute information of a user account, and then the message corresponding to the identification information in the database can be pushed to the user according to the identification information, so that the personalized requirement can be met, and the technical problem that the utilization rate of the cache is low due to the fact that the existing cache resource is difficult to be fully used for message pushing of the personalized requirement in the related technology is solved.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure without limiting the disclosure. In the drawings:
fig. 1 is a flowchart illustrating a method for pushing a message according to an exemplary embodiment of the disclosure.
FIG. 2 is a schematic diagram of one implementation environment illustrated by the present disclosure, in accordance with an exemplary embodiment.
Fig. 3 is a flowchart illustrating another method for pushing a message according to an exemplary embodiment of the disclosure.
Fig. 4 is a flowchart illustrating a method of pushing a message including steps of creating a correspondence table according to an exemplary embodiment.
Fig. 5 is a block diagram of an apparatus for pushing a message according to an exemplary embodiment of the disclosure.
Fig. 6 is a block diagram of another apparatus for pushing messages according to an exemplary embodiment of the disclosure.
Fig. 7 is a block diagram illustrating a creation module of an apparatus for pushing a message according to an exemplary embodiment of the disclosure.
Fig. 8 is a block diagram illustrating an apparatus for pushing messages in accordance with an example embodiment.
Detailed Description
The following detailed description of specific embodiments of the present disclosure is provided in connection with the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the present disclosure, are given by way of illustration and explanation only, not limitation.
FIG. 2 is a schematic diagram illustrating one implementation environment in accordance with an example embodiment. As shown in fig. 2, the implementation environment may include a platform server 10, clients running on a first terminal 20 and a second terminal 30. The platform server 10 may be one server or a server cluster including a plurality of servers. In this embodiment, the platform server 10 is provided with a database to store message data, and a cache space cache correspondence table. In other embodiments, a database may be set in one platform server, and another platform server sets the cache space cache correspondence table.
The terminal may be a user equipment, such as a desktop computer, a smart phone, a tablet computer, a notebook computer, etc., which accesses the platform server 10 through a mobile communication network. Fig. 2 illustrates the terminal as a desktop computer. Specifically, the terminal may be installed with various clients, and when accessing the network service, the client initiates a network connection request, and based on the network connection request, the terminal may connect to the mobile communication network to access the platform server 10.
The platform server can be used for pushing different messages to corresponding enterprise users. In other embodiments, the user who logs in the platform server through the client may also be an employee of an enterprise, the client is an internal communication system of some enterprise, the employee logs in the internal communication system through an account of the employee, and the platform server may push different messages to the corresponding employee.
Fig. 1 is a flowchart of a method for pushing a message according to an exemplary embodiment, so as to solve a technical problem in the related art that a cache utilization rate is low due to difficulty in fully using an existing cache resource for message pushing with personalized requirements. The method for pushing a message shown in this embodiment may be applied to the platform server 10 shown in fig. 2, as shown in fig. 1, and the method includes:
and S11, acquiring the attribute information of the account logged in the platform server.
And S12, inquiring the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information.
And S13, according to the inquired identification information, pushing the information corresponding to the identification information in the database to the client of the platform server logged by the account.
In step S11, the user inputs account information, such as an account name and a password, into the client, and the client or the platform server verifies the input account name and password, and after verification is successful, the client is allowed to log in the platform server.
And the accounts logged in the platform server all have corresponding attribute information. For example, when the user of the platform server is an enterprise user and the client is an enterprise communication system of each enterprise in a region, the attribute information of the account may include a region number and/or an enterprise tax number of the region where the enterprise is located; when the user of the platform server is an employee of an enterprise, the client is an internal communication system of the enterprise, and the attribute information of the account may include information such as the job number and/or the affiliated department of the employee. In other embodiments, the attribute information of the account may be other preset identification information, and the disclosure is not limited in particular.
It should be noted that, the attribute information and the account name of the account may be pre-stored in the terminal or the platform server in an associated manner.
After the attribute information of the account is obtained, step S12 is executed to query the identification information of the message corresponding to the attribute information according to the correspondence table between the cached attribute information and the identification information. The identification information of the message may be the number of the message in the message database, and each message in the message database has a unique message number. It should be noted that the correspondence table between the attribute information and the identification information is stored in the cache of the platform server.
When the identification information of the message corresponding to the attribute information is found in the correspondence table in the cache, step S13 is executed, and the message corresponding to the identification information in the database is pushed to the client that logs in the platform server from the account.
For example, as shown in fig. 2, the platform server 10 may be a unified platform supporting personalized configurations across the country, and the messages in the platform server 10 support target region-by-target region distribution and target enterprise distribution. The first terminal 20 is a terminal used by a first enterprise located in the beijing area, the second terminal 30 is a terminal used by a second enterprise located in the shanghai area, and both the first terminal 20 and the second terminal 30 are installed with clients capable of logging in the platform server 10. The first enterprise user inputs the account name and the password of the first enterprise user into the login interface of the client in the first terminal 20, the second enterprise user inputs the account name and the password of the second enterprise user into the login interface of the client in the second terminal 30, the platform server 10 verifies the account information of the first enterprise user and the second enterprise user, and the client in the first terminal 20 and the client in the second terminal 30 are allowed to log in the platform server 10 after the verification is successful.
Next, the platform server 10 may query attribute information of a corresponding account in a pre-storage space according to the account name, for example, the pre-storage space stores the account name of the first enterprise user and the corresponding attribute information, where the attribute information includes: the enterprise tax number is 110101000000000, and the Beijing area number is 110100; the pre-storage space also stores an account name of a second enterprise user and corresponding attribute information, and the attribute information comprises: the Shanghai area is numbered 310000.
Then, the platform server 10 queries a corresponding relationship table in the cache, and if the beijing area includes the message 1 and the message 2, the first enterprise includes the message 3, and the shanghai area includes the message 4, the corresponding relationship table includes three pieces of data, which are: { "110100", "1, 2" }, { "110101000000000", "3" }, { "310000", "4" }. According to the query result, the message identifier corresponding to the attribute information of the account of the first enterprise user is 1, 2 or 3, and the message identifier corresponding to the attribute information of the account of the second enterprise user is 4.
Next, pushing the messages with the message identifiers of "1, 2 and 3" in the database to the client of the first terminal 20, namely pushing the messages 1, 2 and 3 to the first enterprise user; and pushing the message with the message mark of '4' in the database to the client of the second terminal 30, namely pushing the message 4 to the second enterprise user.
Certainly, in other embodiments, the user logging in the platform server 10 through the client may also be an employee of an enterprise, the client is an internal communication system of the enterprise, the employee logs in the internal communication system through an account of the user, the platform server 10 may push different messages to the corresponding employee, the first terminal 20 and the second terminal 30 are terminals used by employees in two different departments in the enterprise, and the attribute information of the employee account may include information such as an employee job number and a department number. The platform server 10 may push the message to a certain employee according to the cached correspondence table, or may push the message to all employees in a certain department.
According to the method and the device, the corresponding relation table of the attribute information and the identification information is set in the cache, when a user logs in a platform server, the identification information of the corresponding message can be inquired according to the attribute information of a user account, and then the message corresponding to the identification information in the database can be pushed to the user according to the identification information, so that the personalized requirement can be met, and the technical problem that the utilization rate of the cache is low due to the fact that the existing cache resource is difficult to be fully used for message pushing of the personalized requirement in the related technology is solved.
It should be noted that the method embodiment shown in fig. 1 is described as a series of acts or combinations for simplicity of description, but it should be understood by those skilled in the art that the present disclosure is not limited by the order of acts or steps described. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no particular act is required in order to implement the disclosure.
Fig. 3 is a flowchart of another method for pushing a message according to an exemplary embodiment of the present disclosure, so as to solve a technical problem in the related art that the utilization rate of a cache is low due to the difficulty in fully using existing cache resources for message pushing based on personalized requirements. The method for pushing a message shown in this embodiment may be applied to the platform server 10 shown in fig. 2, as shown in fig. 3, and the method includes: .
And S21, creating a corresponding relation table and storing the table in a cache.
And S22, acquiring the attribute information of the account logged in the platform server.
And S23, inquiring the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information.
And S24, according to the inquired identification information, pushing the information corresponding to the identification information in the database to the client of the platform server logged by the account.
And when the cache of the platform server does not have the corresponding relation table, the corresponding relation table needs to be created and stored in the cache. Fig. 4 is a flowchart illustrating a method for pushing a message according to an exemplary embodiment, where the method includes a step of creating a correspondence table, and as shown in fig. 4, the creating a correspondence table and storing the correspondence table in a cache may include the following steps:
s211, inquiring whether a corresponding relation table exists in the cache.
S212, when the corresponding relation table does not exist in the cache, locking the cache operation; and when the platform is locked, other accounts are prohibited from entering the platform server or the corresponding relation table is inquired.
S213, analyzing the message data in the database to obtain the corresponding relation between the attribute information and the identification information of the message.
And S214, creating a corresponding relation table according to the analysis result and storing the corresponding relation table in a cache.
S215, unlocking the cache operation.
The reason why the operation of creating the correspondence table needs to be locked is that when a plurality of users log in at the same time and it is determined that the correspondence table does not exist, the same operation of creating the correspondence table may be repeatedly executed for a plurality of times, which may cause performance waste and, in a serious case, may even cause a system crash. In order to solve the problem, the operation of creating the corresponding relation table can be locked, after the locking, only the user who logs in or inquires that the corresponding relation table does not exist firstly can log in the platform server through the client, other users are in a suspended state, and after the unlocking, other users can log in the platform server through the client to perform inquiry operation.
Whether the corresponding relation table exists in the cache is inquired before locking, so that the cache data possibly existing can be inquired by a plurality of threads at the same time, and the concurrent processing capacity is improved. Optionally, after locking the cache operation, it is determined that the corresponding relationship table does not exist in the cache. That is, the query operation is also performed after the locking, and the query operation after the locking is necessary for solving the problem of repeatedly creating the correspondence table.
In step S213, parsing the message data in the database may include: inquiring whether preset keywords exist in the message or not; and when the preset keywords exist in the message, associating the identification information of the message with the attribute information corresponding to the preset keywords. For example, the preset keyword may be an enterprise name, a region name, an employee name, or the like, and assuming that two words of beijing exist in the message with the number of 1, the beijing region number is associated with the message 1 in the correspondence table, and the expression form may be: {"110100","1"}.
Optionally, before the corresponding relationship table is created, a query cycle is set, and the query cycle may be a week, or may be five days or three days. And setting an update mark every time the message data in the database is changed in a query period. The message data change may be message publishing, message deleting or message content change, and the update flag may be stored in the cache or other storage spaces of the platform server. For example, every other week, it is queried whether an update flag exists in the cache, and if so, step S21 is executed to create a correspondence table and store the correspondence table in the cache. In this embodiment, step S21 is executed, and the step of querying whether the corresponding relationship table exists in the cache may be omitted.
Because the message data in the database are changed when the messages are issued, deleted and changed, if the cache data are updated synchronously, the performance of the cache system is greatly reduced, but if the cache data are updated asynchronously, the messages obtained by user login are still the messages when the cache is created before, and the phenomenon of message data asynchronization is generated. In order to fully utilize cache resources and improve the cache utilization rate, the cache time cannot be too short, and in order to ensure data synchronization, the cache time cannot be too long. In order to solve the contradiction, the cache is updated according to the requirement, namely, a mark is set when the message data is changed, then whether the update mark exists or not is judged at regular time, and the corresponding relation table is updated only if the update mark exists. Due to the fact that the cache updating is triggered at regular time, concurrency can not happen, and locking is not needed.
Because the corresponding relation table is updated according to needs, the contradiction between the cache utilization rate and the data asynchronism is solved, and the cache resources are optimally used according to actual conditions.
Fig. 5 is a block diagram of an apparatus for pushing a message according to an exemplary embodiment of the disclosure, and as shown in fig. 5, the apparatus 300 for pushing a message includes:
an obtaining module 310, configured to obtain attribute information of an account logged in the platform server;
the query module 320 is configured to query, according to the correspondence table between the cached attribute information and the identification information, the identification information of the message corresponding to the attribute information;
and the pushing module 330 is configured to push, according to the queried identification information, a message corresponding to the identification information in the database to the account.
Optionally, as shown in fig. 6, the apparatus 300 for pushing a message further includes:
the creating module 340 is configured to create a corresponding relationship table and store the corresponding relationship table in a cache before acquiring the attribute information of the account logged in the platform server.
Optionally, as shown in fig. 7, the creating module 340 includes:
the query submodule 341 is configured to query whether a corresponding relationship table exists in the cache;
the locking submodule 342 is configured to lock the cache operation when the corresponding relationship table does not exist in the cache; when locking, forbidding other accounts to enter the platform server or inquiring the corresponding relation table;
the parsing sub-module 344 is configured to parse the message data in the database to obtain a corresponding relationship between the attribute information and the identification information of the message;
the creating submodule 345 is configured to create a corresponding relationship table according to the analysis result and store the corresponding relationship table in the cache;
an unlock submodule 346 for unlocking the cache operation.
Optionally, the creating module further comprises:
the confirming submodule 343 is configured to confirm that the corresponding relationship table does not exist in the cache after the cache operation is locked.
Optionally, as shown in fig. 6, the apparatus 300 for pushing a message further includes:
a setting module 350, configured to set an update flag when the message data in the database is changed.
A periodic query module 360, configured to periodically query whether the update flag exists; when the update flag exists, the creating module 340 performs an operation of creating a correspondence table.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
The present disclosure also provides a computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements the method steps of pushing a message as described in any of the above-mentioned alternative embodiments.
The present disclosure also provides a device for pushing a message, including:
a memory having a computer program stored thereon; and
a processor for executing the computer program in the memory to perform the method steps of the push message.
Fig. 8 is a block diagram illustrating an apparatus 400 for pushing messages in accordance with an example embodiment. As shown in fig. 8, the apparatus 400 may include: a processor 401, a memory 402, a multimedia component 403, an input/output (I/O) interface 404, and a communication component 405.
The processor 401 is configured to control the overall operation of the apparatus 400, so as to complete all or part of the steps in the above method for pushing a message. The memory 402 is used to store various types of data to support operation of the apparatus 400, and such data may include, for example, instructions for any application or method operating on the apparatus 400, as well as application-related data. The Memory 402 may be implemented by any type of volatile or non-volatile Memory device or combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic disk or optical disk. The multimedia components 403 may include a screen and an audio component. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 402 or transmitted through the communication component 405. The audio assembly also includes at least one speaker for outputting audio signals. The I/O interface 404 provides an interface between the processor 401 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 405 is used for wired or wireless communication between the apparatus 400 and other devices. Wireless Communication, such as Wi-Fi, bluetooth, Near Field Communication (NFC), 2G, 3G, or 4G, or a combination of one or more of them, so that the corresponding Communication component 405 may include: Wi-Fi module, bluetooth module, NFC module.
In an exemplary embodiment, the apparatus 400 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components for performing the above-described method of pushing messages.
In another exemplary embodiment, a computer readable storage medium comprising program instructions, such as the memory 402 comprising program instructions, which are executable by the processor 401 of the apparatus 400 to perform the above-described method of pushing messages is also provided.
The preferred embodiments of the present disclosure are described in detail with reference to the accompanying drawings, however, the present disclosure is not limited to the specific details of the above embodiments, and various simple modifications may be made to the technical solution of the present disclosure within the technical idea of the present disclosure, and these simple modifications all belong to the protection scope of the present disclosure.
It should be noted that the various features described in the above embodiments may be combined in any suitable manner without departing from the scope of the invention. In order to avoid unnecessary repetition, various possible combinations will not be separately described in this disclosure.
In addition, any combination of various embodiments of the present disclosure may be made, and the same should be considered as the disclosure of the present disclosure, as long as it does not depart from the spirit of the present disclosure.

Claims (10)

1. A method for pushing messages is applied to a platform server, and the method comprises the following steps:
creating a corresponding relation table and storing the corresponding relation table in a cache;
acquiring attribute information of an account logged in the platform server;
inquiring the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information;
pushing a message corresponding to the identification information in a database to a client of the platform server logged in by the account according to the inquired identification information;
the creating a corresponding relation table and storing the corresponding relation table into a cache comprises the following steps:
inquiring whether a corresponding relation table exists in the cache or not;
when the corresponding relation table does not exist in the cache, locking the cache operation to prohibit other accounts from entering the platform server or inquiring the corresponding relation table;
analyzing message data in the database to acquire the corresponding relation between the attribute information and the identification information of the message;
according to the analysis result, creating a corresponding relation table and storing the corresponding relation table in a cache;
unlocking the cache operation;
the analyzing the message data in the database to obtain the corresponding relationship between the attribute information and the identification information of the message includes:
inquiring whether preset keywords exist in the message or not; and the number of the first and second electrodes,
and when the preset keyword exists in the message, associating the identification information of the message with the attribute information corresponding to the preset keyword.
2. The method of claim 1, further comprising:
and after locking the cache operation, confirming that the corresponding relation table does not exist in the cache.
3. The method of claim 1, wherein before creating the correspondence table, the method further comprises:
when the message data in the database are changed, setting an update mark;
periodically inquiring whether the updating mark exists; and when the update mark exists, creating a corresponding relation table.
4. The method of claim 1, wherein the attribute information comprises a region number and/or an enterprise tax number corresponding to the account, and the identification information comprises a number of the message.
5. An apparatus for pushing a message, the apparatus comprising:
the creating module is used for creating a corresponding relation table and storing the corresponding relation table in a cache;
the acquisition module is used for acquiring the attribute information of the account of the login platform server;
the query module is used for querying the identification information of the message corresponding to the attribute information according to the corresponding relation table of the cached attribute information and the identification information;
the pushing module is used for pushing a message corresponding to the identification information in the database to the account according to the inquired identification information;
wherein the creation module comprises:
the query submodule is used for querying whether a corresponding relation table exists in the cache or not;
the locking sub-module is used for locking the cache operation when the corresponding relation table does not exist in the cache so as to prohibit other accounts from entering the platform server or inquiring the corresponding relation table;
the analysis submodule is used for analyzing the message data in the database to acquire the corresponding relation between the attribute information and the identification information of the message;
the creating submodule is used for creating a corresponding relation table according to the analysis result and storing the corresponding relation table into a cache;
the unlocking submodule is used for unlocking the cache operation;
wherein the parsing submodule is specifically configured to:
inquiring whether preset keywords exist in the message or not; and the number of the first and second electrodes,
and when the preset keyword exists in the message, associating the identification information of the message with the attribute information corresponding to the preset keyword.
6. The apparatus of claim 5, wherein the creation module further comprises:
and the confirming submodule is used for confirming that the corresponding relation table does not exist in the cache after the cache operation is locked.
7. The apparatus of claim 5, further comprising:
the setting module is used for setting an update mark when the message data in the database is changed;
the regular query module is used for regularly querying whether the update mark exists; and when the update mark exists, the creating module executes the operation of creating the corresponding relation table.
8. The apparatus of claim 5, wherein the attribute information comprises a region number and/or an enterprise tax number corresponding to the account, and the identification information comprises a number of the message.
9. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 4.
10. An apparatus for pushing a message, comprising:
a memory having a computer program stored thereon; and
a processor for executing the computer program in the memory to carry out the steps of the method of any one of claims 1 to 4.
CN201811027552.6A 2018-09-04 2018-09-04 Method, device and storage medium for pushing messages Active CN109040300B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811027552.6A CN109040300B (en) 2018-09-04 2018-09-04 Method, device and storage medium for pushing messages

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811027552.6A CN109040300B (en) 2018-09-04 2018-09-04 Method, device and storage medium for pushing messages

Publications (2)

Publication Number Publication Date
CN109040300A CN109040300A (en) 2018-12-18
CN109040300B true CN109040300B (en) 2021-05-14

Family

ID=64623820

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811027552.6A Active CN109040300B (en) 2018-09-04 2018-09-04 Method, device and storage medium for pushing messages

Country Status (1)

Country Link
CN (1) CN109040300B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110247963A (en) * 2019-05-31 2019-09-17 北京智慧云行科技有限责任公司 A kind of data push method and system
CN110062055B (en) * 2019-05-31 2021-07-20 四川长虹电器股份有限公司 Websocket-based single-user multi-place login distributed push method
CN110661697B (en) * 2019-09-10 2022-10-18 北京百分点科技集团股份有限公司 Message synchronization method, device, readable storage medium, electronic device and system
CN113918776B (en) * 2021-12-14 2022-04-08 杭州筑龙信息技术股份有限公司 Data caching method and device, electronic equipment and data query method

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105491539A (en) * 2014-09-18 2016-04-13 博雅网络游戏开发(深圳)有限公司 Message push management method and device
CN106612301A (en) * 2015-10-22 2017-05-03 招商局国际信息技术有限公司 Updated data pushing method and updated data pushing device
CN106998274A (en) * 2016-12-12 2017-08-01 深圳大宇无限科技有限公司 Application message method for pushing and device
CN107277181A (en) * 2017-08-14 2017-10-20 深圳市金立通信设备有限公司 A kind of information push method, server and message push system
CN107977865A (en) * 2017-12-07 2018-05-01 畅捷通信息技术股份有限公司 Advertisement sending method, device, computer equipment and readable storage medium storing program for executing
CN108322521A (en) * 2018-01-17 2018-07-24 腾讯科技(深圳)有限公司 Message content method for pushing, device, system, computer equipment and storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090124241A1 (en) * 2007-11-14 2009-05-14 Qualcomm Incorporated Method and system for user profile match indication in a mobile environment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105491539A (en) * 2014-09-18 2016-04-13 博雅网络游戏开发(深圳)有限公司 Message push management method and device
CN106612301A (en) * 2015-10-22 2017-05-03 招商局国际信息技术有限公司 Updated data pushing method and updated data pushing device
CN106998274A (en) * 2016-12-12 2017-08-01 深圳大宇无限科技有限公司 Application message method for pushing and device
CN107277181A (en) * 2017-08-14 2017-10-20 深圳市金立通信设备有限公司 A kind of information push method, server and message push system
CN107977865A (en) * 2017-12-07 2018-05-01 畅捷通信息技术股份有限公司 Advertisement sending method, device, computer equipment and readable storage medium storing program for executing
CN108322521A (en) * 2018-01-17 2018-07-24 腾讯科技(深圳)有限公司 Message content method for pushing, device, system, computer equipment and storage medium

Also Published As

Publication number Publication date
CN109040300A (en) 2018-12-18

Similar Documents

Publication Publication Date Title
CN109040300B (en) Method, device and storage medium for pushing messages
CN107426169B (en) Service processing method and device based on permission
CN105765944B (en) Method and system for third party to batch process request for authorizing repeated access to resource
CN107733972B (en) Short link analysis method, device and equipment
US9910895B2 (en) Push subscriptions
CN111741016B (en) Method, computing device, and computer storage medium for managing application interfaces
EP3491808B1 (en) Interchangeable retrieval of content
CN112434059B (en) Data processing method, data processing device, computer equipment and storage medium
WO2011115839A2 (en) Computer relational database method and system having role based access control
CN112261172B (en) Service addressing access method, device, system, equipment and medium
US11734229B2 (en) Reducing database fragmentation
CN110895603B (en) Multi-system account information integration method and device
CN112925589A (en) Calling method and device of expansion interface
CN107203594B (en) Data processing device, method and computer readable storage medium
US11522863B2 (en) Method and system for managing resource access permissions within a computing environment
CN113824675B (en) Method and device for managing login state
CN113138943B (en) Method and device for processing request
US11226983B2 (en) Sub-scope synchronization
CN103701844A (en) User information management method and system
US11157454B2 (en) Event-based synchronization in a file sharing environment
CN113127906A (en) Unified authority management platform, method and storage medium based on C/S architecture
KR102334093B1 (en) Apparatus and method for managing data
CN111026936B (en) Data cognition method, device, terminal and computer storage medium of interaction theme
CN116701328A (en) Data processing method, apparatus, device, storage medium, and program product
CN116932558A (en) Form data processing method and device

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