Disclosure of Invention
In view of this, embodiments of the present invention provide a reminding method and apparatus, which can perform processing of reminding related data in memories of multiple servers, thereby reducing concurrent processing of data and improving data processing efficiency.
To achieve the above object, according to one aspect of the present invention, a reminding method is provided.
The reminding method of the embodiment of the invention comprises the following steps: acquiring reminding related data of a plurality of articles, and sending the reminding related data to memories of a plurality of servers; wherein the reminder related data for any item includes: the article's reminder feature data and reminder route data; in any server, determining a reminding condition corresponding to any reminding related data stored in the server; and when the reminding characteristic data in the reminding related data meets the reminding condition, sending reminding information according to the reminding path data in the reminding related data.
Optionally, the reminder feature data includes: the final use date of the article; and the sending the reminding related data to the memories of the plurality of servers comprises: and sending the reminding related data to the memories of the plurality of servers based on the final use date of the articles in the reminding related data.
Optionally, the reminder-related data for any item further comprises: the name of the item and the type of the item; the reminding condition corresponding to any reminding related data is determined by the type of the article in the reminding related data; the reminding information comprises the names of the articles in the reminding related data corresponding to the reminding information.
Optionally, in any server, the reminder related data is stored in a multiple mapped multimap data structure; wherein, the final use date of the article in the reminding related data is used as a key, and the name of the article, the type of the article and the reminding path data of the article in the reminding related data are used as values; the reminder related data is arranged in ascending order of keys.
Optionally, when the reminding feature data in the reminding related data meets the reminding condition, sending the reminding information according to the reminding route data in the reminding related data includes: traversing the reminding related data stored by the server in ascending order of the keys, and aiming at any reminding related data: comparing the current date with the final use date of the articles in the reminding related data: deleting the reminding related data when the current date is not prior to the final use date of the article; when the current date is prior to the final use date of the article, judging whether the final use date of the article and the current date meet the reminding condition corresponding to the reminding related data: if yes, sending reminding information according to reminding path data in the reminding related data; otherwise, the reminder-related data is skipped.
Optionally, the method further comprises: in any server, after skipping any reminder-related data, the reminder-related data that are subsequent and include items of the same type as the items included in the reminder-related data are ignored.
Optionally, the sending the reminder related data to the memories of the plurality of servers includes: receiving, in any server, reminder-related data using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; after the receipt is complete, the thread lock is released.
Optionally, the sending the reminder information according to the reminder route data in the reminder related data includes: sending the reminder related data to a push system by using a plurality of threads; in the push system, sending reminding information according to reminding path data in the reminding related data; and, the method further comprises: in a push system, receiving reminder related data by using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; and releasing the thread lock after sending the reminding information according to the reminding path data in the reminding related data.
Optionally, the item is a sold shelf-life item.
To achieve the above object, according to still another aspect of the present invention, a reminder device is provided.
The reminding device of the embodiment of the invention can comprise: the system comprises a dispatching unit, a storage unit and a processing unit, wherein the dispatching unit can be used for acquiring reminding related data of a plurality of articles and sending the reminding related data to memories of a plurality of servers; wherein the reminder related data for any item includes: the article's reminder feature data and reminder route data; the reminding unit can be used for determining a reminding condition corresponding to any reminding related data stored in any server; and when the reminding characteristic data in the reminding related data meets the reminding condition, sending reminding information according to the reminding path data in the reminding related data.
Optionally, the reminder feature data includes: the final use date of the article; and, the dispatch unit may be further operable to: and sending the reminding related data to the memories of the plurality of servers based on the final use date of the articles in the reminding related data.
Optionally, the reminder-related data for any item may further include: the name of the item and the type of the item; the reminding condition corresponding to any reminding related data is determined by the type of the article in the reminding related data; the reminding information comprises the names of the articles in the reminding related data corresponding to the reminding information.
Optionally, in any server, the reminder related data is stored in a multiple mapped multimap data structure; wherein, the final use date of the article in the reminding related data is used as a key, and the name of the article, the type of the article and the reminding path data of the article in the reminding related data are used as values; the reminder related data is arranged in ascending order of keys.
Optionally, the reminding unit may be further configured to: traversing the reminding related data stored by the server in ascending order of the keys, and aiming at any reminding related data: comparing the current date with the final use date of the articles in the reminding related data: deleting the reminding related data when the current date is not prior to the final use date of the article; when the current date is prior to the final use date of the article, judging whether the final use date of the article and the current date meet the reminding condition corresponding to the reminding related data: if yes, sending reminding information according to reminding path data in the reminding related data; otherwise, the reminder-related data is skipped.
Optionally, the reminding unit may be further configured to: in any server, after skipping any reminder-related data, the reminder-related data that are subsequent and include items of the same type as the items included in the reminder-related data are ignored.
Optionally, the dispatch unit may be further configured to: receiving, in any server, reminder-related data using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; after the receipt is complete, the thread lock is released.
Optionally, the reminding unit may be further configured to: in any server, a plurality of threads are utilized to send reminding related data of which the final use date and the current date of the included articles meet corresponding reminding conditions to a push system; in a push system, receiving reminder related data by using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; sending reminding information according to reminding path data in the reminding related data; after the completion of the issue, the thread lock is released.
Optionally, the item is a sold shelf-life item.
To achieve the above object, according to still another aspect of the present invention, there is provided an electronic apparatus.
An electronic device of the present invention includes: one or more processors; the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors realize the reminding method provided by the invention.
To achieve the above object, according to still another aspect of the present invention, there is provided a computer-readable storage medium.
A computer-readable storage medium of the present invention has stored thereon a computer program which, when executed by a processor, implements the alert method provided by the present invention.
According to the technical scheme of the invention, one embodiment of the invention has the following advantages or beneficial effects: the reminding related data are distributed to the memories of the servers, and various concurrent operations of the data are performed in the memories of the servers, so that the data processing efficiency is improved on the premise of not compiling a large number of codes, the user experience is improved, and the problems of excessive concurrent operations and low data processing efficiency in the prior art are solved; storing reminding related data by using an automatically-sequenced multimap data structure in any server, thereby realizing the ordered management of the reminding related data; moreover, for the reminding related data of the same type of articles in any server, only a part of the previous data can be calculated, so that the calculation amount is saved; and data is written, calculated and deleted by utilizing a multithreading and thread locking technology, so that the data safety is ensured, and the data processing efficiency is further improved.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
According to the technical scheme of the embodiment of the invention, the reminding related data are distributed to the memories of the plurality of servers, and various concurrent operations of the data are carried out in the memories of the plurality of servers, so that the data processing efficiency is improved on the premise of not compiling a large number of codes, the user experience is improved, and the problems of excessive concurrent operations and low data processing efficiency in the prior art are solved; storing reminding related data by using an automatically-sequenced multimap data structure in any server, thereby realizing the ordered management of the reminding related data; moreover, for the reminding related data of the same type of articles in any server, only a part of the previous data can be calculated, so that the calculation amount is saved; and data is written, calculated and deleted by utilizing a multithreading and thread locking technology, so that the data safety is ensured, and the data processing efficiency is further improved.
It should be noted that the embodiments of the present invention and the technical features of the embodiments may be combined with each other without conflict.
Fig. 1 is a schematic diagram of main steps of a reminding method according to an embodiment of the present invention.
As shown in fig. 1, the reminding method according to the embodiment of the present invention can be performed according to the following steps:
step S101: and acquiring reminding related data of a plurality of articles, and sending the reminding related data to memories of a plurality of servers.
In practical applications, the items in this step may be various items for which the user is reminded. For example: for the service side, it is necessary to remind the user of the expiration date of the purchased goods, and the shelf-life goods sold by the user can be used as the goods in this step.
In this step, the reminder-related data refers to at least one specific data of the article to be used in the process of making the reminder. It is understood that the reminder-related data may be specifically selected according to the application environment.
In the embodiment of the present invention, the reminder related data may include reminder feature data and reminder route data. Wherein, the reminding characteristic data refers to: when a certain type of reminding is carried out, the article has specific data which can directly embody the connotation of the reminding type. In a specific application, the reminding characteristic data can be used for being matched with the reminding condition so as to determine the reminding time. Namely: and judging whether the reminding characteristic data accords with the reminding condition, and sending out the reminding when the reminding characteristic data is determined to accord with the reminding condition. The reminder route data refers to: path information to the user required when sending the reminder information.
For example: when the reminding is carried out aiming at the origin information of the sold article, the reminding characteristic data is the origin information of the article, and the reminding path data can be the mobile phone number of a user who purchases the article or the user name of the user in a related application program. Besides the above mentioned origin information, mobile phone number, user name, the reminding related data may also include: the name of the item, the purchase quantity of the item, etc. When reminding, the following steps can be specifically executed:
1. a reminder condition for the item is determined. For example, the reminding conditions are: the origin is a reminder sent out abroad.
2. Judging whether the reminding characteristic data meet the reminding conditions or not: if so, sending a prompt to the user according to the prompt path data. For example: the producing area of the article is Mauriques, the article meets the reminding condition, and reminding information is compiled according to the name and the purchase quantity of the article, if: "XX (purchase quantity) pieces xxxxxx (name of article) that you buy, whose origin is murris, please know", this reminder is sent to the user by the user's mobile phone number or user name.
Preferably, in the embodiment of the invention, the user can remind the sold shelf-life articles. The solution of the invention will be mainly described in this context. Specifically, when reminding is performed based on the shelf life article, the reminding characteristic data may be the final use date of the article, and the reminding path data may be the mobile phone number of the user or the user name of the user in the relevant application program.
As a preferred scheme, in addition to the above-mentioned reminder feature data and reminder route data, the reminder-related data may further include the name of the item and the type of the item. Where the name of the item may appear in the reminder message to prompt the user, the type of item may be used to determine the reminder condition.
In specific application, different reminding conditions can be preset for different types of quality guarantee period articles. For example: for the fresh articles, the user needs to be reminded more frequently, and then the reminding condition can be set as: the first reminder is issued three days before expiration, and then reminders are issued once a day until the final use date (the final use date is not reminded). For the articles for daily use which are not easy to deteriorate, only a small amount of reminding can be made, and then the submission condition can be set as: the first reminding is sent out six months before the expiration, and the last reminding is sent out one month before the expiration.
In step S101, the reminder-related data of the plurality of items may originate from a plurality of business systems, such as a plurality of order systems. For a shelf-life commodity, in practical application, information such as the name of the commodity, the type of the commodity, reminding route data of the commodity, the production date and the shelf life of the commodity and the like can be extracted from order data of an order system, and the production date and the shelf life of the commodity are added to obtain the final use date of the commodity, so that reminding related data can be obtained. It will be appreciated that the final date of use of the article may be data expressed in the form of a year, month, day, or further data accurate to hours, minutes, or seconds. In actual scenes, the final use date of the article is generally only reserved for the part of the year, the month and the day.
In this step, after the reminding related data of the plurality of articles is obtained, the reminding related data can be uniformly sent to the memories of the plurality of servers for data processing, so that the concurrent operation of a single machine is reduced, and the efficient reading and writing of the data is realized. The SERVER in this step refers to an electronic device or an application program for processing reminder-related data, and may be an electronic device having computing capability such as a personal computer pc (personal computer), a dedicated SERVER, or an intelligent terminal, or may be various application programs.
In the embodiment of the invention, the reminding related data can be sent to the memories of the servers based on the final use date of the article, so that efficient data management is realized. For example: reminder related data may be distributed to the 12 servers according to the final use date of the item in different months of the current year; reminder related data may also be distributed to the 52 servers depending on the final use date of the item being in a different week of the current year.
In a specific application scenario, when any server receives the reminding related data, multiple threads can be used for receiving so as to improve the receiving efficiency. Specifically, when one thread is utilized to receive related data of a certain reminder, a thread lock is added; and after the receiving is completed, releasing the thread lock to ensure the data security. It will be appreciated that joining a thread lock refers to acquiring a built-in lock of a data object to be processed.
In particular, in embodiments of the present invention, in each server, reminder-related data is stored in a multiple-mapped multimap data structure. In the field of computer technology, multimap is a data structure that allows the values of keys of data to be repeated and that can automatically order data based on key value pairs (key value pairs). Specifically, in the memory of each server, the final use date of the item included in the reminder related data is used as a key, and the name of the item, the type of the item, and the reminder route data of the item included in the reminder related data are used as values to store the reminder related data.
Meanwhile, the attribute of the multimap may be set so that the reminder related data is arranged in the ascending order of the keys. It is understood that ascending key order refers to the order of key values from small to large (first to last for the end use date). In addition, for data with the same key value, the data can be arranged according to a preset arrangement rule. Thus, in each server, the reminder-related data is arranged in the order of the last-used date of the item from first to last. For example: sequentially storing data of final use dates from first monday to first monday in a first server; in addition, it can be understood that the prompt reminding related data written into the server from the business system can also be automatically sequenced.
Illustratively, the multimap data structure may be set by the following pseudo code:
multimap<long_date,goodsinfo,less<long>>
where long denotes long integer data, date denotes the final date of use of the item as a key, goodsinfo denotes the name, type, reminder route data, etc. of the item as a value, and less denotes sorting in ascending order of keys.
Therefore, in the step, the reminding related data are distributed to the memories of the servers, and various concurrent operations of the data are performed in the memories of the servers, so that the data are prevented from being stored and processed in the read-only memory with lower read-write efficiency, the data processing efficiency is improved on the premise of not writing a large number of codes, the user experience is improved, and meanwhile, the horizontal capacity expansion of the servers is facilitated. In addition, each server stores reminding related data by using an automatically-sequenced multimap data structure, so that the effective management of the data can be realized.
Step S102: in any server, determining a reminding condition corresponding to any reminding related data stored in the server; and when the reminding characteristic data in the reminding related data meets the reminding condition, sending reminding information according to the reminding path data in the reminding related data.
In an optional implementation manner, this step may process the reminder related data stored in any server memory according to the following steps:
1. and determining a reminding condition corresponding to any reminding related data in the server.
The reminding condition corresponding to the reminding related data refers to a reminding condition corresponding to an article in the reminding related data. Generally, the reminder condition can be determined based on the type of item included in the reminder-related data.
2. Traversing the reminder related data stored by the server in ascending order of keys; in the traversal process, the following calculation is carried out for any reminding related data:
(1) comparing the current date with the final use date of the articles in the reminding related data: the reminder-related data is deleted when the current date is not prior to (i.e., later than or equal to) the item's final use date. In practical application, when relevant reminding data is deleted, a thread lock needs to be added; and after the deletion is completed, releasing the thread lock to avoid data damage.
(2) When the current date is prior to the final use date of the article, judging whether the final use date of the article and the current date meet the reminding condition corresponding to the reminding related data: if yes, sending pre-programmed reminding information according to reminding path data in the reminding related data; otherwise, skipping the reminding related data and calculating the next reminding related data. The current date may be data expressed in the form of year, month, and day, or may be data further accurate to hour, minute, and second.
For example: the final use date of the articles in the reminding related data is 1 month and 10 days of a certain year, and the reminding conditions corresponding to the reminding related data are as follows: the first reminder is issued three days before expiration, after which the reminder is issued once a day until the final use date (the final use date day means expiration, this day is not reminded). If the current date is 7 days in 1 month, 8 days in 1 month or 9 days in 1 month of the year, the final use date of the article and the current date accord with the reminding condition and need to send out a reminder; and if the current date is 1 month and 1 day, which indicates that the final use date of the article and the current date do not accord with the reminding condition, skipping the reminding related data.
In particular, in practical applications, after skipping an item of reminder-related data during the calculation process of a server, reminder-related data in the server, which includes items of the same type as the items included in the reminder-related data, may be ignored. Here, the ignoring means not calculating the following data. This is because: for the reminding related data of different articles of the same type in the same server, the corresponding reminding conditions are the same, and the final use date of the previous data is necessarily prior to or equal to the final use date of the subsequent data; if the previous data is skipped, the description time is often earlier, and no reminding is needed, and for the following data, no reminding is needed, so that the calculation is not needed. Through the setting, the calculation amount can be saved, and the calculation efficiency is further improved.
Through the steps, the method can calculate the data stored in the memory of each server so as to realize efficient user reminding. In practical application, a daily timing task can be set in each server, and data operation is performed periodically.
Preferably, in the embodiment of the present invention, a push system may be configured to send the reminder information. Wherein, the push system can be a hardware device or a computer program with message push function. Accordingly, after determining a plurality of pieces of reminder-related data for which the reminder information needs to be sent in each server, the following steps may be performed:
1. in the server, a plurality of threads are utilized to send a plurality of pieces of reminding related data to a push system. And after the sending is completed, deleting the sent reminding related data in the server. And when deleting the related data of a certain reminder, adding the thread lock, and after finishing deleting, releasing the thread lock.
2. In a push system, reminder related data is received using a plurality of threads. After receiving a certain reminding related data, sending the pre-programmed reminding information according to the reminding route data in the reminding related data. When a certain thread is used for receiving related data of a certain reminder, a thread lock is added; and after the reminding information is sent according to the reminding path data in the reminding related data, releasing the thread lock and deleting the reminding related data from the pushing system. It is understood that the deletion of the reminder-related data can also be implemented by using a thread lock technique.
Preferably, in the push system, only one piece of reminder related data may be received at a time. And after the reminding information is sent aiming at the reminding related data, receiving the next piece of reminding related data.
Through the process, the invention can write, calculate and delete data by utilizing multithreading and thread lock technology, thereby ensuring data safety and further improving data processing efficiency. Meanwhile, by arranging a plurality of servers and a push system, two asynchronous operations of acquiring related reminding data and sending reminding information can be independently realized, so that the coupling between the systems is reduced.
According to the method provided by the embodiment of the invention, the reminding related data are distributed to the memories of the servers, and various concurrent operations of the data are performed in the memories of the servers, so that the data processing efficiency is improved on the premise of not compiling a large number of codes, the user experience is improved, and the problems of excessive concurrent operations and low data processing efficiency in the prior art are solved; storing reminding related data by using an automatically-sequenced multimap data structure in any server, thereby realizing the ordered management of the reminding related data; moreover, for the reminding related data of the same type of articles in any server, only a part of the previous data can be calculated, so that the calculation amount is saved; and data is written, calculated and deleted by utilizing a multithreading and thread locking technology, so that the data safety is ensured, and the data processing efficiency is further improved.
Fig. 2 is a schematic diagram of a main part of a reminder device according to an embodiment of the invention.
As shown in fig. 2, the reminding device 200 according to the embodiment of the present invention may include: a dispatching unit 201 and a reminding unit 202. Wherein:
the dispatching unit 201 may be configured to obtain reminder related data of a plurality of items, and send the reminder related data to memories of a plurality of servers; wherein the reminder related data for any item includes: the article's reminder feature data and reminder route data;
the reminding unit 202 may be configured to determine, in any server, a reminding condition corresponding to any reminding related data stored in the server; and when the reminding characteristic data in the reminding related data meets the reminding condition, sending reminding information according to the reminding path data in the reminding related data.
Preferably, in an embodiment of the present invention, the reminding feature data includes: the final use date of the article; the reminder-related data for any item may further include: the name of the item and the type of the item; the reminding condition corresponding to any reminding related data is determined by the type of the article in the reminding related data; the reminding information comprises the name of an article in the reminding related data corresponding to the reminding information; the item may be a sold shelf-life item.
In an alternative implementation, the dispatch unit 201 may be further configured to: and sending the reminding related data to the memories of the plurality of servers based on the final use date of the articles in the reminding related data.
In practical application, in any server, the reminding related data is stored in a multimap data structure; wherein, the final use date of the article in the reminding related data is used as a key, and the name of the article, the type of the article and the reminding path data of the article in the reminding related data are used as values; the reminder related data is arranged in ascending order of keys.
As a preferred solution, the reminding unit 202 can further be configured to: traversing the reminding related data stored by the server in ascending order of the keys, and aiming at any reminding related data: comparing the current date with the final use date of the articles in the reminding related data: deleting the reminding related data when the current date is not prior to the final use date of the article; when the current date is prior to the final use date of the article, judging whether the final use date of the article and the current date meet the reminding condition corresponding to the reminding related data: if yes, sending reminding information according to reminding path data in the reminding related data; otherwise, the reminder-related data is skipped.
In the embodiment of the present invention, the reminding unit 202 can be further configured to: in any server, after skipping any reminder-related data, the reminder-related data that are subsequent and include items of the same type as the items included in the reminder-related data are ignored.
In a specific application, the dispatching unit 201 can be further configured to: receiving, in any server, reminder-related data using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; after the receipt is complete, the thread lock is released.
Furthermore, in the embodiment of the present invention, the reminding unit 202 may be further configured to: in any server, a plurality of threads are utilized to send reminding related data of which the final use date and the current date of the included articles meet corresponding reminding conditions to a push system; in a push system, receiving reminder related data by using a plurality of threads; when any thread in the multiple threads is used for receiving any reminding related data, adding a thread lock; sending reminding information according to reminding path data in the reminding related data; after the completion of the issue, the thread lock is released.
According to the technical scheme of the embodiment of the invention, the reminding related data are distributed to the memories of the plurality of servers, and the plurality of concurrent operations of the data are carried out in the memories of the plurality of servers, so that the data processing efficiency is improved on the premise of not compiling a large number of codes, the user experience is improved, and the problems of excessive concurrent operations and low data processing efficiency in the prior art are solved; storing reminding related data by using an automatically-sequenced multimap data structure in any server, thereby realizing the ordered management of the reminding related data; moreover, for the reminding related data of the same type of articles in any server, only a part of the previous data can be calculated, so that the calculation amount is saved; and data is written, calculated and deleted by utilizing a multithreading and thread locking technology, so that the data safety is ensured, and the data processing efficiency is further improved.
Fig. 3 shows an exemplary system architecture 300 to which the alert method or alert device of an embodiment of the present invention may be applied.
As shown in fig. 3, the system architecture 300 may include terminal devices 301, 302, 303, a network 304 and a server 305 (this architecture is merely an example, and the components included in a particular architecture may be adapted according to the application specific circumstances). The network 304 serves as a medium for providing communication links between the terminal devices 301, 302, 303 and the server 305. Network 304 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal device 301, 302, 303 to interact with the server 305 via the network 304 to receive or send messages or the like. The terminal devices 301, 302, 303 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 301, 302, 303 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 305 may be a server providing various services, such as a background management server (for example only) providing support for shopping-like websites browsed by users using the terminal devices 301, 302, 303. The backend management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (for example, target push information, product information — just an example) to the terminal device.
It should be noted that the reminding method provided by the embodiment of the present invention is generally executed by the server 305, and accordingly, the reminding apparatus is generally disposed in the server 305.
It should be understood that the number of terminal devices, networks, and servers in fig. 3 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
The invention also provides the electronic equipment.
The electronic device of the embodiment of the invention comprises: one or more processors; the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors realize the reminding method provided by the invention.
Referring now to FIG. 4, a block diagram of a computer system 400 suitable for use with the electronic device implementing an embodiment of the invention is shown. The electronic device shown in fig. 4 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 4, the computer system 400 includes a Central Processing Unit (CPU)401 that can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)402 or a program loaded from a storage section 408 into a Random Access Memory (RAM) 403. In the RAM403, various programs and data necessary for the operation of the computer system 400 are also stored. The CPU401, ROM 402, and RAM403 are connected to each other via a bus 404. An input/output (I/O) interface 405 is also connected to bus 404.
The following components are connected to the I/O interface 405: an input section 406 including a keyboard, a mouse, and the like; an output section 407 including a display device such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 408 including a hard disk and the like; and a communication section 409 including a network interface card such as a LAN card, a modem, or the like. The communication section 409 performs communication processing via a network such as the internet. A driver 410 is also connected to the I/O interface 405 as needed. A removable medium 411 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 410 as necessary, so that a computer program read out therefrom is mounted into the storage section 408 as necessary.
In particular, the processes described in the main step diagrams above may be implemented as computer software programs, according to embodiments of the present disclosure. For example, embodiments of the invention include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the main step diagram. In the above-described embodiment, the computer program can be downloaded and installed from a network through the communication section 409, and/or installed from the removable medium 411. The computer program performs the above-described functions defined in the system of the present invention when executed by the central processing unit 401.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present invention may be implemented by software or hardware. The described units may also be provided in a processor, and may be described as: a processor includes a dispatch unit and a reminder unit. Where the names of these units do not in some cases constitute a limitation of the unit itself, for example, the serving unit may also be described as a "unit sending reminder-related data to the reminder unit".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by the apparatus, cause the apparatus to perform steps comprising: acquiring reminding related data of a plurality of articles, and sending the reminding related data to memories of a plurality of servers; wherein the reminder related data for any item includes: the article's reminder feature data and reminder route data; in any server, determining a reminding condition corresponding to any reminding related data stored in the server; and when the reminding characteristic data in the reminding related data meets the reminding condition, sending reminding information according to the reminding path data in the reminding related data.
According to the technical scheme of the embodiment of the invention, the reminding related data are distributed to the memories of the plurality of servers, and the plurality of concurrent operations of the data are carried out in the memories of the plurality of servers, so that the data processing efficiency is improved on the premise of not compiling a large number of codes, the user experience is improved, and the problems of excessive concurrent operations and low data processing efficiency in the prior art are solved; storing reminding related data by using an automatically-sequenced multimap data structure in any server, thereby realizing the ordered management of the reminding related data; moreover, for the reminding related data of the same type of articles in any server, only a part of the previous data can be calculated, so that the calculation amount is saved; and data is written, calculated and deleted by utilizing a multithreading and thread locking technology, so that the data safety is ensured, and the data processing efficiency is further improved.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.