CN115186198B - Stock market pushing method and related device - Google Patents

Stock market pushing method and related device Download PDF

Info

Publication number
CN115186198B
CN115186198B CN202211098726.4A CN202211098726A CN115186198B CN 115186198 B CN115186198 B CN 115186198B CN 202211098726 A CN202211098726 A CN 202211098726A CN 115186198 B CN115186198 B CN 115186198B
Authority
CN
China
Prior art keywords
quotation
stock
market
processing period
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202211098726.4A
Other languages
Chinese (zh)
Other versions
CN115186198A (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.)
China Cicc Wealth Securities Co ltd
Original Assignee
China Cicc Wealth Securities Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Cicc Wealth Securities Co ltd filed Critical China Cicc Wealth Securities Co ltd
Priority to CN202211098726.4A priority Critical patent/CN115186198B/en
Publication of CN115186198A publication Critical patent/CN115186198A/en
Application granted granted Critical
Publication of CN115186198B publication Critical patent/CN115186198B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • General Physics & Mathematics (AREA)
  • Development Economics (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Strategic Management (AREA)
  • Marketing (AREA)
  • Economics (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a stock market quotation pushing method and a related device. The method comprises the following steps: receiving a plurality of subscription stock lists of the plurality of terminal devices in a first action processing period, wherein a single subscription stock list is used for representing stocks subscribed by a user in the first action processing period from user dimensions; updating a pre-configured user subscription list according to the plurality of subscription stock lists; acquiring quotation data of target stocks; and querying the user subscription list to determine a reference user of the target stock needing to perform market data synchronization in the first market processing period, and sending the market data of the target stock to a terminal device of the reference user. The method and the system enable the real-time stock quotation push user to locally store the subscription data, the timing pulling, subscription and cleaning processes and the stock quotation push process are not interfered with each other, and the stability, the usability and the real-time performance of the system are enhanced.

Description

Stock market quotation pushing method and related device
Technical Field
The invention relates to the technical field of computers, in particular to a stock market quotation pushing method and a related device.
Background
There are a number of trading markets for financial instruments worldwide, with exchanges providing a match function and real-time stock market quotations for a defined trading period. The stock company obtains the real-time stock quotation data, forwards and transmits the real-time stock quotation according to the request of the user terminal, and draws and displays the real-time stock quotation on the user terminal.
With the wide application of the intelligent operating system to smart phones, tablet computers and smart televisions, in the scene of high concurrency and massive terminals, when centralized storage is used, great pressure is applied to data transmission and access, and the stability, usability and real-time performance of the centralized storage can affect the stability, usability and real-time performance of a market system.
Disclosure of Invention
In order to solve the above problems, the present application provides a method and a related device for pushing stock quotation, which push the user subscription data local storage through the real-time quotation of stocks, wherein the processes of regularly pulling, subscribing and cleaning do not interfere with the process of pushing stock quotation, and the stability, availability and real-time performance of the system are enhanced.
In a first aspect, an example of the present application provides a method for pushing stock quotes, where the method includes:
receiving a plurality of subscription stock lists of the plurality of terminal devices in a first action processing period, wherein a single subscription stock list is used for representing the stocks subscribed by the user in the first action processing period from the user dimension;
updating a pre-configured user subscription list according to the plurality of subscription stock lists, wherein the user subscription list is used for representing users needing quotation data synchronization of each stock in each quotation processing period from a stock dimension;
acquiring quotation data of target stocks;
and querying the user subscription list to determine a reference user of the target stock needing to perform market data synchronization in the first market processing period, and sending the market data of the target stock to a terminal device of the reference user.
In a second aspect, the present application example provides a device for pushing stock quotations, the device includes:
a receiving module, configured to receive multiple subscription stock lists from the multiple terminal devices in a first action processing period, where a single subscription stock list is used to characterize, from a user dimension, stocks subscribed by a user in the first action processing period;
the updating module is used for updating a pre-configured user subscription list according to the plurality of subscription stock lists, and the user subscription list is used for representing users needing quotation data synchronization in each quotation processing period of each stock from the stock dimension;
the acquisition module is used for acquiring the market data of the target stock;
and the pushing module is used for inquiring the user subscription list to determine a reference user needing market data synchronization of the target stock in the first market processing period, and sending the market data of the target stock to the terminal equipment of the reference user.
In a third aspect, the present invention provides an electronic device comprising a processor, a memory, a communication interface, and one or more programs stored in the memory and configured to be executed by the processor, the programs including instructions for performing the steps in the first aspect of the embodiments of the present application.
In a fourth aspect, embodiments of the present application provide a computer storage medium for storing a computer program for electronic data exchange, wherein the computer program enables a computer to perform some or all of the steps as described in the first aspect of the embodiments of the present application.
In a fifth aspect, embodiments of the present application provide a computer program product, where the computer program product includes a non-transitory computer-readable storage medium storing a computer program, where the computer program is operable to cause a computer to perform some or all of the steps as described in the first aspect of the embodiments of the present application.
The application provides a method and a device for pushing stock quotations, electronic equipment and a readable storage medium. The method comprises the following steps: receiving a plurality of subscription stock lists of the plurality of terminal devices in a first action processing period, wherein a single subscription stock list is used for representing the stocks subscribed by the user in the first action processing period from the user dimension; updating a pre-configured user subscription list according to the plurality of subscription stock lists; acquiring quotation data of target stocks; and querying the user subscription list to determine a reference user of the target stock needing to perform market data synchronization in the first market processing period, and sending the market data of the target stock to a terminal device of the reference user. By adopting the shared data and the optimization scheme, competition among the read locks and the write locks is reduced, and the storage and the acquisition of the user subscription list can be realized through local calculation. When high concurrency and massive terminals are faced, data are processed reasonably and orderly, the speed is accelerated, a user subscription list does not need to be transmitted through a network, and the stability, the usability and the real-time performance of the whole market pushing system are improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative efforts.
FIG. 1 is a diagram illustrating a real-time stock quotation display interface according to an embodiment of the present disclosure;
fig. 2 is a schematic flowchart of a method for pushing stock quotes according to an embodiment of the present application;
fig. 3 is a schematic flowchart of a method for pushing stock quotes according to an embodiment of the present application;
FIG. 4a is a table of cycle times provided by an embodiment of the present application;
FIG. 4b is a schematic diagram of a user's stock subscription list collection;
FIG. 4c is a schematic diagram of another user's stock subscription list collection;
FIG. 4d is a time chart for reading and writing real-time stock market information;
fig. 5a is a block diagram illustrating functional units of a stock market pushing device according to an embodiment of the present disclosure;
FIG. 5b is a block diagram illustrating functional units of another apparatus for pushing stock quotes according to the embodiment of the present application;
fig. 6 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the technical solutions of the present application better understood, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The terms "first," "second," and the like in the description and claims of the present application and in the foregoing drawings are used for distinguishing between different objects and not for describing a particular sequential order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or modules is not limited to the listed steps or modules but may alternatively include other steps or modules not listed or inherent to such process, method, article, or apparatus.
Referring to fig. 2, fig. 2 is a schematic flowchart of a stock market quotation pushing method according to an embodiment of the present application, and as shown in fig. 2, the method is applied to a market quotation server in a stock market quotation pushing system, where the stock market quotation pushing system includes the market quotation server and a plurality of terminal devices, and the market quotation server is in communication connection with the plurality of terminal devices; the method comprises the following steps:
step 210, receiving a plurality of subscription stock lists from the plurality of terminal devices in a first action processing period.
The flow chart of the stock real-time quotation system comprises a user equipment terminal, a stock quotation server and a stock real-time quotation source. The stock quotation server comprises a program for processing timing pull and subscription, a program for processing push, a program for timing cleaning a stock list and a shared data memory;
the user terminal interface is shown in fig. 1, fig. 1 is a stock real-time quotation display interface provided by the application, the user terminal is mainly used for displaying user-selected stocks, quotations, trades, financing and personal information of the user on a home page, and as shown in fig. 1, the name, latest price and fluctuation information of the user-selected stocks can be browsed on the home page interface; and stock searching/self-selecting editing operation can be provided for the user, and data interaction is carried out with the stock market server. The terminal in the embodiments of the present application may be a device that includes both receiving and transmitting hardware and a device that has receiving and transmitting hardware capable of performing bidirectional communication over a bidirectional communication link. Such a terminal may include: a cellular or other communication device having a single line display or a multi-line display or a cellular or other communication device without a multi-line display. The specific terminal may be a desktop terminal or a mobile terminal, and the terminal may also be one of a mobile phone, a tablet computer, a notebook computer, and the like; it should be understood that, the terminal device is connected with the stock quotation server through long communication, the sending and receiving instructions and data transmission can be carried out between the two devices, the user can edit the subscription stock list through searching, adding, reducing and the like, and the terminal device caches the subscription stock list.
Wherein, the market processing cycle shown in fig. 4a is a time slice, and the time slice is a continuous time slice which is divided in advance and has the same time interval, and the interval is the same as the market processing cycle, and can be 5 seconds, so the market processing cycle is used to replace the time slice in the following;
wherein, stock real-time quotation source is mainly used for: and collecting the quotation data of each stock which is being traded in the current processing period in each quotation processing period, and sending the real-time quotation data of the target stock to the stock quotation server according to the request of the stock quotation server.
Wherein, stock market server includes: a processing timing pull and subscription program, a processing push program, a timing cleaning program and a shared data memory, wherein the processing timing pull and subscription program executes steps B2, B3 and D2 shown in figure 3 and all the steps of pulling a stock real-time quotation from a stock quotation server and pushing the stock real-time quotation to a terminal; the push program is processed to execute the steps C1, C2 and C3 shown in FIG. 3; the timing cleaning program executes the step E1 shown in fig. 3; its shared data store performs all the steps from the dataset back to the process timing pull and subscribe program as shown in figure 3.
Referring to fig. 3, fig. 3 is a schematic specific flowchart of a stock market pushing method provided in an embodiment of the present application, and as shown in fig. 3, a terminal device initially performs a step A1 of editing a subscription stock list, specifically: when a user uses the terminal equipment for the first time, the recommendation system randomly subscribes for the user; the user can also actively browse/search the stock code and then join the stock subscription list, and in practical application, the terminal device caches the subscription stock list. The terminal equipment confirms that the current time is in the stock trading time period, B1 timing pulling and subscribing steps are executed, specifically, a command of pulling and subscribing a stock list and a target stock is sent to the stock market server at a timing, and the subscription stock list is transmitted to the stock market server; the stock market server receives a plurality of subscription stock lists of the terminal devices in a first market processing period, B2 is executed to store the user subscription list, the user subscription list needs to be locked when the user subscription list is stored every time, and if the user subscription list is not matched with the current subscription stock lists, the pre-configured user subscription list is updated according to the subscription stock lists; and executing the B3 drawing stock real-time quotation by a processing timing drawing and subscribing program and returning to the step, wherein the drawing stock real-time quotation is to acquire data from a stock real-time quotation source.
Referring to fig. 3, as shown in fig. 3, the step of processing the push program to execute C1 to obtain the user subscription list; c2, filtering the data of the user subscription list, wherein the filtering refers to a data optimization means for temporarily excluding the data which is out of date or invalid from the data for acquiring the user subscription list, and the step of deleting the data is not executed in C2; c3 pulls the stock real-time quotation and returns to the step, it should be understood that here, the stock real-time quotation source is pulled and returns to the processing and pushing program.
Referring to fig. 3, as shown in fig. 3, the terminal device executes a step of canceling subscription D1, the terminal device sends a message of canceling subscription to the stock ticketing server, executes a step of clearing subscription data D2, the stock ticketing server clears data stored in the user subscription list, and returns the updated data information to the processing timing pull and subscription program through the shared data storage, and then returns and pushes the updated data information to the terminal device.
Referring to fig. 4a, as shown in a cycle time comparison table provided in fig. 4a, if the current time is Tc and is in the second market processing cycle, the first market processing cycle is in the next processing cycle of the current time Tc, the third market processing cycle includes N successive market processing cycles after the first market processing cycle, where N is a positive integer; referring to fig. 4b and 4c, that is, the table shown in fig. 4b is converted to the table shown in fig. 4c, where the time slice in fig. 4b refers to a certain time period, which may be a time period of 5S, 10S, 1min, and the like, and this is not limited herein, the index value in fig. 4c is a unique mark of stock market data, and may be composed of a stock name, such as S1, and a corresponding market processing cycle duration, such as T1, and the data in fig. 4c is a user mark, such as U1, corresponding to a certain stock, and in practical applications, the target stock subscription time subscribed by each reference user may be obtained in fig. 4b, and the market processing cycle is determined by looking up a table of the subscription time; FIG. 4c illustrates a user who needs to synchronize market data of each target stock in a certain market processing period; referring to step E1 in fig. 3, step E1 is a step of clearing user subscription list, which is a task triggered at regular time to clear user subscription list
Figure 151318DEST_PATH_IMAGE001
In the formula, the update time of the user subscription list is Tu, T1 is the duration of the market processing cycle, M is the positive integer, and the stock market server regularly cleans up the invalid user subscription list in order to deal with the situations that the terminal bug and the app are killed.
Therefore, in this example, by adopting the shared data and optimizing the scheme to reduce competition between the read lock and the write lock, the local computing can store and acquire the user subscription list, and the stability, the availability and the real-time performance of the whole market pushing system are improved.
And step 220, updating a pre-configured user subscription list according to the plurality of subscription stock lists, wherein the user subscription list is used for representing users needing market data synchronization in each market processing period of each stock from the stock dimension.
In one possible example, the updating a preconfigured user subscription list from the plurality of subscription stock lists comprises: querying data corresponding to a second market processing cycle in the user subscription list, wherein the second market processing cycle is a market processing cycle before the first market processing cycle; detecting that the data corresponding to the second market processing period is not matched with the plurality of subscription stock lists; and updating data corresponding to the first quotation processing period and a third quotation processing period in the user subscription list according to the plurality of subscription stock lists, wherein the third quotation processing period comprises N continuous quotation periods after the first quotation processing period, and N is a positive integer.
In specific applications, when data corresponding to a first emotion processing cycle and a third emotion processing cycle need to be updated, the values of the N corresponding to the use time and the current moment are extracted from the data set, and then the third emotion processing cycle of the data needs to be updated is determined; it should be understood that the server may have another thread for paying attention to the real-time hot spot information, and if a certain preset keyword (for example, new energy, white spirit, etc., which may cause a large fluctuation of stock quotation after a preset part of keywords appear) appears in the real-time hot spot information, the server queries the preset data set, and if the user does not set a new value of N within the latest preset time, the server may perform an adjustment operation on the value of N, and automatically adjust the value of N available in the current time period in the original data set.
Determining a reference value x according to the number of preset associated words (words representing attention heat) appearing in a preset time period, adjusting N acquired from a data set through the reference value, and obtaining adjusted N
Figure 700111DEST_PATH_IMAGE002
At the same timeThe more the occurrence times of the preset associated words in the time period are, the larger the reference value x is, so that the larger N' is, the longer the push occupation time of the stocks corresponding to the high-heat associated words is.
After the value of N 'is adjusted, the frequency of steps C1 to C3 shown in fig. 3 should be correspondingly adjusted, for example, if the heat of a preset associated word is higher, the reference value x is higher, N' is larger, and the number of times of executing steps C1 to C3 is correspondingly increased.
It should be understood that the user subscription list herein may change according to the user application scenario, for example, after the user switches the software to the background, the system may cancel the subscription by default, and the user subscription list at this time may change accordingly.
Therefore, in this embodiment, the user subscription list is not accumulated continuously, but is updated and adjusted in a preset time period along with the change of the application condition of the terminal device side, and a more frequent pushing step can be performed on the stocks with highly-popular associated words to obtain more real-time quotations and push the more real-time quotations to the user, so that the flexibility and pertinence of the system are improved, and the user experience is improved.
In one possible example, the querying the user subscription list to determine a reference user for which the target stock needs market data synchronization in the first market processing period comprises: and under the condition that the starting time is in a fourth line-condition processing period, querying data corresponding to the first line-condition processing period in the user subscription list to determine the reference user, wherein the fourth line-condition processing period is a next line-condition processing period of the first line-condition processing period.
In order to reduce the competition of the read-write lock on the shared data in the steps B2, C1 and E1, the following method is adopted during implementation: determining a time slice Tn where the user subscription list is located according to the current time Tc; b2, writing the storage data of the time slices of (Tn +1, tn + 2., tn + N), namely updating a pre-configured user subscription list according to the plurality of subscription stock lists; c1, reading the stored data of the time slice (Tn), namely under the condition that the starting time is in a fourth emotion processing period, inquiring data corresponding to the first emotion processing period in the user subscription list to determine the reference user; the step E1 writes (Tn-M) the storage data of the time slice, that is, clear (Tn-M) the data whose writing time is before the M market processing cycle from the user subscription list at intervals of a first preset time, where M is a positive integer, please refer to fig. 4d, where N =3, M =1, specifically, the step B2 starts to write data 4, data 5, and data 6 for 3 consecutive time periods from the time T3, and then the step C1 starts to read from the time T2 and reads from the current time (T3), since the step B2 in the step B2 has no data information, the time T3 in the step C1 in fig. 4d also has no data information, and the data 4 corresponding to the time T3 in the step B2 does not exist until the time T4, the step C1 reads the data 5 and the data 6, and so on, and the description is omitted, and the step E1 writes (clears) the data of the time T2 from the time T4.
It can be seen that, in this example, accessing the user subscription list does not involve network interaction, involves thread lock/process lock, involves three resource locks in the stock market server, where the read-write lock involved is local computation, and the speed of accessing shared data is faster and less time consuming than accessing centralized storage, so as to improve real-time performance and optimize user experience.
And step 230, acquiring the quotation data of the target stock.
Step 240, querying the user subscription list to determine a reference user of the target stock, which needs to perform market data synchronization in the first market processing period, and sending the market data of the target stock to a terminal device of the reference user.
In one possible example, the obtaining the market data of the target stock comprises: and acquiring real-time quotation data of the target stock from a stock real-time quotation source, wherein the stock real-time quotation source is used for collecting the quotation data of each stock in the current processing period in trading in a certain quotation processing period.
Wherein the market data includes, but is not limited to: latest price, fluctuation range, 5-grade data of buying and selling (Level-2 market is 10 grades), and the like.
Therefore, in the example, the quotation data in the stock quotation source is pulled in real time, and the quotation data is updated in time, so that the timeliness of stock quotation change is met, the availability of the system is improved, and the user experience is optimized.
In one possible example, the method further comprises: inquiring the user subscription list at preset intervals to acquire data corresponding to a fifth market quotation processing period in the user subscription list, wherein the fifth market quotation processing period is a market quotation processing period before the market quotation processing period at the current moment; according to the data corresponding to the fifth quotation processing period, determining candidate stocks needing quotation data push in the quotation processing period at the current moment and candidate users corresponding to the candidate stocks, and acquiring the real-time quotation data of the candidate stocks from the stock real-time quotation source; and pushing the real-time market data of the candidate stock to the candidate user.
Therefore, in the embodiment, by acquiring the data in the market processing period and correspondingly subscribing the user information, the real-time market pushing user subscription data of the stocks are locally stored, pulled and subscribed at regular time, and the stability, the availability and the real-time performance of the system are improved.
In one possible example, the method further comprises: at the starting time of the fourth market quotation processing period, clearing data written in the user subscription list before M market quotation processing periods of the starting time, wherein M is a positive integer; and if detecting that the corresponding user subscription list data does not exist before the M market processing periods at the starting moment, skipping the step of cleaning the data written in the user subscription list before the M market processing periods at the starting moment.
In step C2 of FIG. 3, the screening process is performed
Figure 834158DEST_PATH_IMAGE003
The current time is Tc, the update time of the user subscription list is Tu, T1 is the market condition processing cycle duration, and N is the positive integer. The stock quotation server obtains the target stock by inquiring the user subscription list, sends the target stock to the stock real-time quotation source and informs the real-time quotation source of the returned target stockAnd sending the quotation data of the target stock to the terminal equipment of the reference user.
As can be seen, in this example, by presetting the screening period, invalid data is reduced, and the robustness and stability of the system are improved.
Referring to step E1 in fig. 3, in addition to the step of clearing the user subscription list data described in step E1, set storage (a storage type) of a local remote dictionary service may be used through a shared data memory, and after data is written, an expire command (time to live command) is used to set timing expiration of the data.
As can be seen, in this example, the data with invalid redundancy can be cleaned up in a plurality of ways, and the robustness and stability of the system are improved.
In one possible example, after the sending the quotation data of the target stock to the terminal device of the reference user, the method further includes: receiving subscription cancellation information sent by the terminal equipment; and deleting the user subscription list data according to the unsubscribe information, and stopping sending the quotation data of the target stock to the terminal equipment of the reference user.
The information for canceling subscription can be from user to cancel subscription, or the device judges that the user cancels subscription by default after the user switches the current stock real-time quotation interface for more than a preset time.
As can be seen, in this example, referring to fig. 3, when the user actively quits from the APP/switches to another service function or the user actively performs a subscription cancellation operation, the step of canceling the subscription is executed by D1, the terminal device sends a subscription cancellation message to the processing timing pull and subscription program in the stock market server, and the timing pull and subscription program executes the step of clearing subscription data by D2, so as to clear data stored in the user subscription list, reduce processing time, and improve operation efficiency.
The embodiment of the application provides a stock quotation pushing method, which is characterized in that a user subscribes data and stores locally through real-time quotation pushing of stocks, the processes of regularly pulling, subscribing and cleaning do not interfere with the flow of pushing the stock quotation, and the stability, the usability and the real-time performance of a system are enhanced.
Referring to fig. 5a, in a case that each function module is divided according to each function, fig. 5a is a block diagram of functional units of a stock market pushing apparatus according to an embodiment of the present application, and as shown in fig. 5a, the stock market pushing apparatus 500 includes: a receiving unit 501, configured to receive multiple subscription stock lists of the multiple terminal devices in a first action processing period, where a single subscription stock list is used to characterize, from a user dimension, stocks subscribed by a user in the first action processing period; an updating unit 502, configured to update a preconfigured user subscription list according to the plurality of subscription stock lists, where the user subscription list is used to characterize, from a stock dimension, users of each stock that need to perform market data synchronization in each market processing cycle; an obtaining unit 503, configured to obtain market data of a target stock; a pushing unit 504, configured to query the user subscription list to determine a reference user of the target stock that needs to perform market data synchronization in the first market processing period, and push the market data of the target stock to a terminal device of the reference user.
In a possible example, the updating unit 502 is specifically configured to update the preconfigured user subscription list according to the plurality of subscription stock lists: querying data corresponding to a second market processing cycle in the user subscription list, wherein the second market processing cycle is a market processing cycle before the first market processing cycle; detecting that the data corresponding to the second market processing period is not matched with the plurality of subscription stock lists; and updating data corresponding to the first quotation processing period and a third quotation processing period in the user subscription list according to the plurality of subscription stock lists, wherein the third quotation processing period comprises N continuous quotation processing periods after the first quotation processing period, and N is a positive integer.
In a possible example, the querying the user subscription list to determine the reference user of the target stock that needs to perform market data synchronization in the first market processing period, the updating unit 502 is specifically configured to: at the starting time of the fourth quotation processing period, cleaning data written in the user subscription list before M quotation processing periods of the starting time, wherein M is a positive integer; and if detecting that the corresponding user subscription list data does not exist before the M market processing periods at the starting moment, skipping the step of cleaning the data written in the user subscription list and before the M market processing periods at the starting moment.
In a possible example, the obtaining the market data of the target stock, and the pushing unit 504 is specifically configured to: and acquiring real-time quotation data of the target stock from a stock real-time quotation source, wherein the stock real-time quotation source is used for collecting the quotation data of each stock in the current processing period in trading in a certain quotation processing period.
In a possible example, the pushing unit 504 is further specifically configured to: inquiring the user subscription list at preset intervals to acquire data corresponding to a fifth market quotation processing period in the user subscription list, wherein the fifth market quotation processing period is a market quotation processing period before the market quotation processing period at the current moment; according to the data corresponding to the fifth quotation processing period, determining candidate stocks needing quotation data pushing in the quotation processing period at the current moment and candidate users corresponding to the candidate stocks, and acquiring the real-time quotation data of the candidate stocks from the stock real-time quotation source; and pushing the real-time quotation data of the candidate stocks to the candidate users.
In a possible example, the pushing unit 504 is further specifically configured to: at the starting time of the fourth quotation processing period, cleaning data written in the user subscription list before M quotation processing periods of the starting time, wherein M is a positive integer; and if detecting that the corresponding user subscription list data does not exist before the M market processing periods at the starting moment, skipping the step of cleaning the data written in the user subscription list before the M market processing periods at the starting moment.
In one possible example, after sending the quotation data of the target stock to the terminal device of the reference user, the receiving unit 501 and the updating unit 502 are used together to: receiving subscription cancellation information sent by the terminal equipment; and deleting the user subscription list data according to the unsubscribe information, and stopping sending the quotation data of the target stock to the terminal equipment of the reference user.
It can be understood that, since the method embodiment and the apparatus embodiment are different presentation forms of the same technical concept, the content of the method embodiment portion in the present application should be synchronously adapted to the apparatus embodiment portion, and is not described herein again.
In the case of using an integrated module, as shown in fig. 5b, fig. 5b is a block diagram of functional units of another stock market information pushing device provided in this embodiment. In fig. 5b, the stock market pushing device 510 includes: a communication module 511 and a processing module 512. The communication module 511 is used for supporting the interaction between the stock ticketing market pushing device and other equipment. The processing module 512 is used for controlling and managing actions of the stock quote pushing device, such as steps of the receiving unit 501, the updating unit 502, the obtaining unit 503 and the pushing unit 504, and/or other processes for executing the techniques described herein. As shown in fig. 5b, the stock quote push device may further include a storage module 513, and the storage module 513 is used for storing program codes and data of the stock quote push device.
The Processing module 512 may be a Processor or a controller, and may be, for example, a Central Processing Unit (CPU), a general-purpose Processor, a Digital Signal Processor (DSP), an ASIC, an FPGA or other programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. The processor may also be a combination of computing functions, e.g., comprising one or more microprocessors, DSPs, and microprocessors, among others. The communication module 511 may be a transceiver, an RF circuit or a communication interface, etc. The storage module 513 may be a memory.
All relevant contents of each scene related to the method embodiment may be referred to the functional description of the corresponding functional module, and are not described herein again. The stock quote push device 510 can execute the stock quote push method shown in fig. 2.
Referring to fig. 6, fig. 6 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure. The electronic device 600 may include one or more of the following components: a processor 601, a memory 602 coupled to the processor 601, wherein the memory 602 may store one or more computer programs that may be configured to be executed by the one or more processors 601 to implement the methods described in the various embodiments above.
The Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. The general purpose processor may be a microprocessor or the processor may be any conventional processor or the like, the processor is a control center of the stock quote push device, and various interfaces and lines are used to connect various parts of the whole stock quote push device.
The memory may be used to store the computer programs and/or modules, and the processor may implement various functions of the stock market pushing apparatus by executing or executing the computer programs and/or modules stored in the memory and calling data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program (such as an image playing function) required by at least one function, and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. In addition, the memory may include high speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), at least one magnetic disk storage device, a Flash memory device, or other volatile solid state storage device.
The above embodiments may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented in software, the above-described embodiments may be implemented in whole or in part in the form of a computer program product. The computer program product comprises one or more computer instructions or computer programs. The procedures or functions described in accordance with the embodiments of the present application are produced in whole or in part when the computer instructions or the computer program are loaded or executed on a computer. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by wire or wirelessly. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. that contains one or more collections of available media. The usable medium may be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium. The semiconductor medium may be a solid state disk.
Embodiments of the present application also provide a computer storage medium, wherein the computer storage medium stores a computer program for electronic data exchange, and the computer program enables a computer to execute part or all of the steps of any one of the methods as described in the above method embodiments.
Embodiments of the present application also provide a computer program product comprising a non-transitory computer readable storage medium storing a computer program operable to cause a computer to perform some or all of the steps of any one of the methods as set out in the above method embodiments.
It should be understood that, in the various embodiments of the present application, the sequence numbers of the above-mentioned processes do not imply any order of execution, and the order of execution of the processes should be determined by their functions and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
In the several embodiments provided in the present application, it should be understood that the disclosed method, apparatus and system may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative; for example, the division of the modules is only one logic function division, and there may be another division manner in actual implementation; for example, multiple modules or components may be combined or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical modules, may be located in one position, or may be distributed on a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present invention may be integrated into one processing module, or each module may be physically included alone, or two or more modules may be integrated into one module. The integrated module can be realized in a hardware form, and can also be realized in a form of hardware and a software functional module.
The integrated module implemented in the form of a software functional module may be stored in a computer-readable storage medium. The software functional module is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute some steps of the methods according to the embodiments of the present invention. And the aforementioned storage medium includes: u disk, removable hard disk, magnetic disk, optical disk, volatile memory or non-volatile memory. The non-volatile memory may be a read-only memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an electrically Erasable EPROM (EEPROM), or a flash memory. Volatile memory can be Random Access Memory (RAM), which acts as external cache memory. By way of example, and not limitation, many forms of Random Access Memory (RAM) are available, such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), and direct bus RAM (DR RAM) among various media capable of storing program code.
Although the present invention is disclosed above, the present invention is not limited thereto. Various changes and modifications can be easily made by those skilled in the art without departing from the spirit and scope of the present invention, and it is within the scope of the present invention to include different functions, combination of implementation steps, software and hardware implementations.

Claims (9)

1. A stock quotation push method is characterized in that the method is applied to a quotation server in a stock quotation push system, the stock quotation push system comprises the quotation server and a plurality of terminal devices, and the quotation server is in communication connection with the terminal devices; the method comprises the following steps:
receiving a plurality of subscription stock lists of the plurality of terminal devices in a first action processing period, wherein a single subscription stock list is used for representing stocks subscribed by a user in the first action processing period from user dimensions;
querying data corresponding to a second market processing period in a user subscription list, wherein the user subscription list is used for representing users needing market data synchronization of each stock in each market processing period from the stock dimension, and the second market processing period is a market processing period before the first market processing period;
detecting that the data corresponding to the second market processing period is not matched with the plurality of subscription stock lists;
updating data corresponding to the first quotation processing period and a third quotation processing period in the user subscription list according to the plurality of subscription stock lists, wherein the third quotation processing period comprises N continuous quotation processing periods after the first quotation processing period, and N is a positive integer;
acquiring quotation data of target stocks;
and querying the user subscription list to determine a reference user of the target stock needing to perform market data synchronization in the first market processing period, and sending the market data of the target stock to a terminal device of the reference user.
2. The method of claim 1, wherein querying the user subscription list to determine a reference user for which the target stock requires market data synchronization for the first market processing period comprises:
and under the condition that the starting time is in a fourth behavior processing period, querying data corresponding to the first behavior processing period in the user subscription list to determine the reference user, wherein the fourth behavior processing period is a subsequent behavior processing period of the first behavior processing period.
3. The method of claim 1, wherein obtaining market data for the target stock comprises:
and acquiring real-time quotation data of the target stock from a stock real-time quotation source, wherein the stock real-time quotation source is used for collecting the quotation data of each stock in the current processing period in trading in a certain quotation processing period.
4. The method of claim 3, further comprising:
inquiring the user subscription list at preset intervals to acquire data corresponding to a fifth market quotation processing period in the user subscription list, wherein the fifth market quotation processing period is a market quotation processing period before the market quotation processing period at the current moment;
according to the data corresponding to the fifth quotation processing period, determining candidate stocks needing quotation data pushing in the quotation processing period at the current moment and candidate users corresponding to the candidate stocks, and acquiring the real-time quotation data of the candidate stocks from the stock real-time quotation source;
and pushing the real-time quotation data of the candidate stocks to the candidate users.
5. The method of claim 2, further comprising:
at the starting time of the fourth market quotation processing period, clearing data written in the user subscription list, wherein the time of the data is M market quotation processing periods before the starting time, and M is a positive integer;
and if detecting that the corresponding user subscription list data does not exist before the M market processing periods at the starting moment, skipping the step of cleaning the data written in the user subscription list and before the M market processing periods at the starting moment.
6. The method according to any one of claims 1-5, wherein after the sending of the market data of the target stock to the terminal device of the reference user, further comprising:
receiving subscription cancellation information sent by the terminal equipment;
and deleting the user subscription list data according to the unsubscribe information, and stopping sending the quotation data of the target stock to the terminal equipment of the reference user.
7. A stock quotation push device is characterized in that the stock quotation push device is applied to a quotation server in a stock quotation push system, the stock quotation push system comprises the quotation server and a plurality of terminal devices, and the quotation server is in communication connection with the terminal devices; the device comprises:
a receiving unit, configured to receive multiple subscription stock lists from the multiple terminal devices in a first action processing period, where a single subscription stock list is used to characterize, from a user dimension, stocks subscribed by a user in the first action processing period;
the updating unit is used for inquiring data corresponding to a second market processing period in a user subscription list, the user subscription list is used for representing users needing market data synchronization of each stock in each market processing period from the stock dimension, and the second market processing period is a market processing period before the first market processing period; and detecting that the data corresponding to the second market processing period is not matched with the plurality of subscription stock lists; updating data corresponding to the first quotation processing period and a third quotation processing period in the user subscription list according to the plurality of subscription stock lists, wherein the third quotation processing period comprises N continuous quotation processing periods after the first quotation processing period, and N is a positive integer;
the acquisition unit is used for acquiring the quotation data of the target stock;
and the pushing unit is used for inquiring the user subscription list to determine a reference user of the target stock needing market data synchronization in the first market processing period, and sending the market data of the target stock to the terminal equipment of the reference user.
8. An electronic device comprising a processor, a memory, a communication interface, and one or more programs stored in the memory and configured to be executed by the processor, the programs comprising instructions for performing the steps in the method of any of claims 1-6.
9. A computer-readable storage medium for a computer-readable storage medium, characterized in that the computer-readable storage medium stores a computer program for electronic data exchange, wherein the computer program causes a computer to perform the method according to any of claims 1-6.
CN202211098726.4A 2022-09-09 2022-09-09 Stock market pushing method and related device Active CN115186198B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211098726.4A CN115186198B (en) 2022-09-09 2022-09-09 Stock market pushing method and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211098726.4A CN115186198B (en) 2022-09-09 2022-09-09 Stock market pushing method and related device

Publications (2)

Publication Number Publication Date
CN115186198A CN115186198A (en) 2022-10-14
CN115186198B true CN115186198B (en) 2022-12-20

Family

ID=83522623

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211098726.4A Active CN115186198B (en) 2022-09-09 2022-09-09 Stock market pushing method and related device

Country Status (1)

Country Link
CN (1) CN115186198B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105592327A (en) * 2014-10-22 2016-05-18 中兴通讯股份有限公司 IPTV-system-based processing method and apparatus for stock information
CN105869051A (en) * 2016-03-25 2016-08-17 北京资配易投资顾问有限公司 Information processing method, device and system
CN111062192A (en) * 2019-12-17 2020-04-24 支付宝(杭州)信息技术有限公司 Information notification method, device and equipment
CN111325472A (en) * 2020-02-28 2020-06-23 北京思特奇信息技术股份有限公司 Abnormal data detection method and system
CN111694678A (en) * 2020-05-29 2020-09-22 科大智能电气技术有限公司 Continuous periodic data sampling method and system based on linux platform
CN114782201A (en) * 2022-04-19 2022-07-22 中国工商银行股份有限公司 Stock recommendation method and device, computer equipment and storage medium

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7334103B2 (en) * 2002-12-11 2008-02-19 Koninklijke Philips Electronics N.V. Methods and apparatus for improving the breathing of disk scheduling algorithms
CN100449995C (en) * 2006-03-27 2009-01-07 张威 Method for noticing data resource information changing through gate network station
KR100840609B1 (en) * 2006-10-17 2008-06-23 삼성전자주식회사 Apparatus and method of providing contents service
US20080118686A1 (en) * 2006-11-20 2008-05-22 Katherine Glasgow Injection blow molding process and article
CN101145223A (en) * 2007-09-27 2008-03-19 腾讯科技(深圳)有限公司 Calendar supervision system and its supervision method
CN102461223A (en) * 2009-04-20 2012-05-16 捷讯研究有限公司 Updating the user equipment (ue) allowed closed subscriber group list (acl)
CN101930448B (en) * 2009-06-23 2012-08-29 北京搜狗科技发展有限公司 Method and device for subscribing webpage information
CN102769640B (en) * 2011-05-05 2015-10-07 ***通信集团广东有限公司 The update method of user profile, server and system
CN102802047B (en) * 2012-07-09 2016-05-18 北京迈伦斯科技有限公司 The information subscribing that a kind of inter-network is collaborative and information delivery method and system
CN103544627A (en) * 2012-07-11 2014-01-29 北京长生天地电子商务有限公司 Information analyzing system and information analyzing method in network transaction
CN102917061B (en) * 2012-10-19 2015-09-02 北京奇虎科技有限公司 Resource synchronization method and system
CN107067325A (en) * 2017-04-18 2017-08-18 湖南福米信息科技有限责任公司 Filter method, filter and the supplying system of stock market data
CN109918424A (en) * 2019-03-18 2019-06-21 武汉优品楚鼎科技有限公司 A kind of method, system, device and storage medium loading stock certificate data
CN111145024B (en) * 2019-12-27 2023-05-12 深圳市思迪信息技术股份有限公司 Market data pushing method and device
CN111611487A (en) * 2020-05-20 2020-09-01 上海腾韵信息科技有限公司 Stock information application analysis system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105592327A (en) * 2014-10-22 2016-05-18 中兴通讯股份有限公司 IPTV-system-based processing method and apparatus for stock information
CN105869051A (en) * 2016-03-25 2016-08-17 北京资配易投资顾问有限公司 Information processing method, device and system
CN111062192A (en) * 2019-12-17 2020-04-24 支付宝(杭州)信息技术有限公司 Information notification method, device and equipment
CN111325472A (en) * 2020-02-28 2020-06-23 北京思特奇信息技术股份有限公司 Abnormal data detection method and system
CN111694678A (en) * 2020-05-29 2020-09-22 科大智能电气技术有限公司 Continuous periodic data sampling method and system based on linux platform
CN114782201A (en) * 2022-04-19 2022-07-22 中国工商银行股份有限公司 Stock recommendation method and device, computer equipment and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
基于互联网+新闻传媒和大物流业务推广应用探析;赵焕清;《神华科技》;20191226(第12期);第82-85页 *
基于条件约束发布/订阅模式的航天测控数据交换***;汪毅等;《兵工自动化》;20170415(第04期);第 55-57页 *

Also Published As

Publication number Publication date
CN115186198A (en) 2022-10-14

Similar Documents

Publication Publication Date Title
CN109885786B (en) Data caching processing method and device, electronic equipment and readable storage medium
US20210240784A1 (en) Method, apparatus and storage medium for searching blockchain data
CN110765165B (en) Method, device and system for synchronously processing cross-system data
CN109101607B (en) Method, apparatus and storage medium for searching blockchain data
CN110909022A (en) Data query method and device
CN111026761B (en) Financial data storage system, processing method and device
CN109271564A (en) Declaration form querying method and equipment
CN108600780A (en) Method for pushed information
CN114006946B (en) Method, device, equipment and storage medium for processing homogeneous resource request
CN109086414B (en) Method, apparatus and storage medium for searching blockchain data
CN111414207A (en) Page construction method, device and equipment
CN115186198B (en) Stock market pushing method and related device
CN110955719B (en) Data access processing equipment, system and method
CN111104401A (en) System and method for storing data in array and linked list based integrated structure
WO2024103898A1 (en) Database cluster management method and apparatus
CN110515979B (en) Data query method, device, equipment and storage medium
CN111753141B (en) Data management method and related equipment
JP7221652B6 (en) External change detection
CN113626113A (en) Page rendering method and device
EP2153353A1 (en) Distributed search in a casual network of servers
CN101493817A (en) File opening method
US20190146924A1 (en) Method and system for matching multi-dimensional data units in electronic information system
CN108268594B (en) Data query method and device
CN112819490A (en) Device and method for pre-notifying second-killing advertisement
CN112784195A (en) Page data publishing method and system

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