CN108153777B - Method and device for acquiring data access information - Google Patents
Method and device for acquiring data access information Download PDFInfo
- Publication number
- CN108153777B CN108153777B CN201611105450.2A CN201611105450A CN108153777B CN 108153777 B CN108153777 B CN 108153777B CN 201611105450 A CN201611105450 A CN 201611105450A CN 108153777 B CN108153777 B CN 108153777B
- Authority
- CN
- China
- Prior art keywords
- time
- access table
- target data
- query
- access
- 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
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/24569—Query processing with adaptation to specific hardware, e.g. adapted for using GPUs or SSDs
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computational Linguistics (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Transfer Between Computers (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The application discloses a method and a device for acquiring data access information, wherein the method comprises the following steps: acquiring operation information of target data in real time, wherein the target data has starting time; extracting a target user identifier of a user operating the target data in the operation information; and searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, wherein the first access table comprises the user identification, and if the target user identification does not exist, storing the target user identification into the first access table. According to the method and the device, the user identification is extracted from the operation information for accessing the target data in real time, so that the first access table is filled, the operations such as query or data statistics and the like are not needed to be directly performed on the database, the calculation rate of the access information for the target data is increased, and the purpose of the method and the device is achieved.
Description
Technical Field
The present invention relates to the field of stream processing technologies, and in particular, to a method and an apparatus for acquiring data access information.
Background
In the era of data explosion, stream processing calculation becomes a popular research field at present, and the characteristics of high efficiency and rapidness become important for main research. How to calculate the access situation of specific data in the stream processing, such as the television program data watched by which users, is also a valuable solution.
In the prior art, a query result of an accessed condition of specific data is obtained by writing data into a database in real time and then by sql query and deduplication operations of the database.
However, although the scheme in the prior art is simple, in the case of a large amount of data, the calculation speed by the scheme is too slow, and the requirement of stream processing cannot be met.
Disclosure of Invention
In view of the above, the present application is proposed to provide a technical problem of overcoming or at least partially solving the slow computing rate of the prior art in the case where data is accessed.
The application provides a method for acquiring data access information, which comprises the following steps:
acquiring operation information of target data in real time, wherein the target data has starting time;
extracting a target user identifier of a user operating the target data in the operation information;
and searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, wherein the first access table comprises the user identification, and if the target user identification does not exist, storing the target user identification into the first access table.
The above method, preferably, further comprises:
receiving a query request, wherein the query request is used for requesting to return the accessed state of the target data, and the query request at least comprises query time;
and judging whether the query time is consistent with a time parameter value of the first access table, and if so, returning the first access table.
Preferably, in the above method, if the target user identifier does not exist in the first access table, the method further includes:
and storing the target user identification and the starting time into a second access table preset for the target data.
The above method, preferably, further comprises:
receiving a query request, wherein the query request is used for requesting to return the accessed state of the target data, and the query request at least comprises query time;
and judging whether the query time is consistent with a time parameter value of the first access table, if so, returning the first access table, and if not, querying in the second access table based on the query request.
Preferably, the querying in the second access table based on the query request includes:
comparing the query time with each starting time in the second access table;
and returning the user identification corresponding to the starting time consistent with the query time in the second access table.
The present application further provides an apparatus for acquiring data access information, including:
the operation acquisition unit is used for acquiring operation information of target data in real time, and the target data has starting time;
an identification extraction unit configured to extract a target user identification of a user who operates the target data in the operation information;
the identification searching unit is used for searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, the first access table comprises the user identification, and if the target user identification does not exist, the first storage unit is triggered;
and the first storage unit is used for storing the target user identification into the first access table.
The above apparatus, preferably, further comprises:
the first query unit is used for receiving a query request, the query request is used for requesting to return the accessed state of the target data, the query request at least comprises query time, whether the query time is consistent with a time parameter value of the first access table or not is judged, and if yes, the first access table is returned.
The above apparatus, preferably, further comprises:
and the second storage unit is used for storing the target user identifier and the starting time into a second access table which is preset for the target data when the identifier searching unit does not search the target user identifier in the first access table.
The above apparatus, preferably, further comprises:
a second query unit, configured to receive a query request, where the query request is used to request a return of an accessed state of the target data, and the query request at least includes query time, and determine whether the query time is consistent with a time parameter value of the first access table, if so, return the first access table, and if not, trigger the table query unit;
a table query unit, configured to query the second access table based on the query request.
Preferably, the above apparatus, wherein the table lookup unit includes:
the time comparison subunit is used for comparing the query time with each starting time in the second access table;
and the identifier returning subunit is used for returning the user identifier corresponding to the starting time consistent with the query time in the second access table.
By means of the technical scheme, the method and the device for acquiring the data access information provided by the application have the advantages that the first access table is preset based on the starting time of the target data, the user identification of the user for carrying out the access operation on the target data is stored in a duplication-removing manner, namely, only the user identification which does not exist in the first access table is stored, and the user identification which already exists in the first access table does not need to be responded, so that the user identification stored in the first access table represents the user for carrying out the access operation on the target data after the target data is started, the access information of the data is obtained, the user identification is extracted from the operation information for accessing the target data in real time in the process, the filling of the first access table is realized, the operations such as direct query or data statistics and the like on a database are not needed, the calculation rate of the access information of the target data is accelerated, the purpose of the application is achieved.
The foregoing description is only an overview of the technical solutions of the present invention, and the embodiments of the present invention are described below in order to make the technical means of the present invention more clearly understood and to make the above and other objects, features, and advantages of the present invention more clearly understandable.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a flowchart of a method for acquiring data access information according to an embodiment of the present application
FIG. 2 is a diagram illustrating an example of an application of an embodiment of the present application;
fig. 3 is a flowchart of a method for acquiring data access information according to a second embodiment of the present application;
fig. 4 is a flowchart of a method for acquiring data access information according to a third embodiment of the present application;
FIG. 5 is a diagram illustrating another exemplary application of an embodiment of the present application;
FIG. 6 is a partial flow chart of a third embodiment of the present application;
fig. 7 is a schematic structural diagram of an apparatus for acquiring data access information according to a fourth embodiment of the present application;
fig. 8 is a schematic structural diagram of an apparatus for acquiring data access information according to a fifth embodiment of the present application;
fig. 9 is a schematic structural diagram of an apparatus for acquiring data access information according to a sixth embodiment of the present application;
FIG. 10 is another schematic structural diagram of a sixth embodiment of the present application;
fig. 11 is a partial structural schematic diagram of a sixth embodiment of the present application.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Referring to fig. 1, an implementation flowchart of a method for acquiring data access information according to an embodiment of the present application is suitable for a situation where specific data is statistically accessed in stream processing, such as a situation where a certain video program is watched by certain users, and specifically, the method may include the following steps:
step 101: and acquiring the operation information of the target data in real time.
Wherein the target data has a start time, such as a time when the video program was opened, a web document uploaded to the server, a time when the online game was started, and the like.
The operation information refers to operation information for the user to browse a target web document, view a video program, or operate a game interface. The user may access the target data through various terminals or interfaces.
Step 102: and extracting the target user identification of the user operating the target data in the operation information.
The target user identifier may be a user name of a user operating the target data or a number representing an identity of the user.
Step 103: and searching whether the target user identification exists in a first access table which is set for the target data in advance and the time parameter value of the first access table is consistent with the starting time, and if not, executing step 104.
The time parameter value of the first access table is consistent with the starting time, that is, when the target data is started, the first access table of the target data can be generated at the same time, and the first access table is initialized; or a plurality of first access tables are generated in advance, and after the target data is started, one first access table is selected as the first access table of the target data and initialized. Initialization is understood here to mean initializing a data item in the first access table, for example setting a plurality of data item fields in the first access table and leaving each field empty for subsequent storage of a user identification.
When it is required to be described, the setting or generating time of the first access table and the time parameter value thereof do not belong to the same value, the setting or generating time of the first access table refers to the execution time of the setting action of the first access table from the end, the time parameter value of the first access table is an attribute value of the first access table, and the time parameter value is the same as the time of being started or operated of the target data to which the first access table belongs.
Step 104: and storing the target user identification in the first access table.
That is, the first access table has time parameter values corresponding to the start times of the target data, and at the same time, only the user identifier of the user who starts the access operation on the target data from the start time of the target data is stored in the first access table, as shown in fig. 2. Before the user identifier is stored, only the user identifier which is not stored in the first access table is stored by inquiring the identifier which is already stored in the first access table, so that the duplicate removal operation is realized, and in the inquiry of subsequent users, the duplicate removal processing is not required to be carried out again.
By the above technical solution, in the method for acquiring data access information provided in the first embodiment of the present application, the first access table is preset based on the start time of the target data, and the user identifier of the user performing the access operation on the target data is deduplicated, that is, only the user identifier that does not exist in the first access table is stored, and no response is required to the user identifier that already exists in the first access table, so that the user identifier stored in the first access table represents the user performing the access operation on the target data after the target data is started, thereby obtaining the access information of the data, and in this process, the user identifier is extracted from the operation information accessing the target data in real time to further implement the filling of the first access table, and operations such as direct query or data statistics on a database are not required, thereby speeding up the calculation rate of the access information of the target data, the purpose of the application is achieved.
In one implementation, a worker such as an analyst may query which users access the target data by querying the first access table, specifically, referring to fig. 3, which is an implementation flowchart of a method for acquiring data access information provided in the second embodiment of the present application, where the method may further include the following steps:
step 301: a query request is received.
In this embodiment, each user identifier in the first access table represents an operated or accessed state of the target data to which the first access table belongs. The query request at least comprises query time, and the query request containing the query time refers to a request for accessing and operating target data required to be queried by a worker by which users after the query time is started.
Step 302: it is determined whether the query time is consistent with the time parameter value of the first access table, and if so, step 303 is performed.
Step 303: and returning the first access table.
For example, in the streaming processing, after the target data is started, statistics is started on which users access the target data, if a staff member starts to inquire which users access the target data at this time, if which users watch the program, it is first checked whether the inquiry time in the inquiry request is consistent with the time parameter value of the first access table currently performing the streaming processing, if so, the first access table is directly returned, and at this time, the user identifier stored in the first access table is the identifier of the user who watches the program from the started time, for example, from point 17 of 2016.09.20.
In an implementation, in order to ensure reliability of data, the embodiment may store both the extracted target user identifier and the start time of the corresponding target data, specifically, refer to fig. 4, which is an implementation flowchart of a method for acquiring data access information provided in the third embodiment of the present application, where after the first access table is queried in step 103 that the target user identifier does not exist, the method may further include the following steps:
step 105: and storing the target user identification and the starting time into a second access table preset for the target data.
That is, the second access table records the user id of the user whose target data is accessed at any activated time and the corresponding activation time, and the user id in the second access table is not repeated at any activated time of the target data, as shown in fig. 5, the video program is viewed by users A, B and C at 14 o 'clock of the activation time 2016.09.20 and by users A, C and D at 17 o' clock of 2016.09.20.
When the user identifier is provided to a staff member such as an analyst for user identifier query, it is necessary to determine whether the query time queried by the user is consistent with the start time of the target data of the current stream processing, so as to ensure the reliability of the query, specifically, as shown in fig. 6, the method may further include the following steps:
step 601: a query request is received.
The query request is used for requesting to return the accessed state of the target data, the query request at least comprises query time, and the query request containing the query time refers to a request of which users access the target data required to be queried by a worker after the query time is started.
Step 602: it is determined whether the query time is consistent with the time parameter value of the first access table, if so, step 603 is performed, and if not, step 604 is performed.
Step 603: and returning the first access table.
Step 604: a query is made in the second access table based on the query request.
That is to say, in this embodiment, it is first checked whether the query time in the query request is consistent with the start time of the target data in the query task for which users access the target data in the current stream processing, that is, whether the query time in the query request is consistent with the time parameter value of the first access table, if so, it indicates that the user needs to query the user identifier in the first access table generated in the current stream processing, at this time, the step 603 is executed to return the first access table, and if not, it indicates that the user needs to check which users access other start times of the target data, and at this time, the step 604 is executed to query the second access table including the access user identifier for which the target data is started at any time.
In a specific implementation, when the target data started at the query time is accessed by which users based on the query request in the second access table, the embodiment may be implemented specifically by the following manner:
firstly, the query time is compared with each starting time in the second access table, and then the user identification corresponding to the starting time which is consistent with the query time in the second access table is returned.
For example, 14 points of time 2016.09.20 in the query request are compared with each starting time in the second access table shown in fig. 5, and the 14 points of consistent starting time 2016.09.20 are found, and then the user identifiers A, B and C corresponding to the starting time are returned.
Referring to fig. 7, a schematic structural diagram of an apparatus for acquiring data access information according to a fourth embodiment of the present application is suitable for a situation where specific data is statistically accessed in stream processing, such as a situation where a certain video program is watched by certain users, and specifically, the apparatus may include the following structures:
an operation acquiring unit 701 configured to acquire operation information of the target data in real time.
Wherein the target data has a start time, such as a time when the video program was opened, a web document uploaded to the server, a time when the online game was started, and the like.
The operation information refers to operation information for the user to browse a target web document, view a video program, or operate a game interface. The user may access the target data through various terminals or interfaces.
An identification extracting unit 702, configured to extract a user identification of a target user who operates the target data in the operation information.
The target user identifier may be a user name of a user operating the target data or a number representing an identity of the user.
The identifier searching unit 703 is configured to search whether the target user identifier exists in a first access table that is set in advance for the target data and has a time parameter value that is consistent with the start time, where the set time of the first access table is consistent with the start time, and if the target user identifier does not exist, trigger the first storage unit 704.
The time parameter value of the first access table is consistent with the starting time, that is, when the target data is started, the first access table of the target data can be generated at the same time, and the first access table is initialized; or a plurality of first access tables are generated in advance, and after the target data is started, one first access table is selected as the first access table of the target data and initialized. Initialization is understood here to mean initializing a data item in the first access table, for example setting a plurality of data item fields in the first access table and leaving each field empty for subsequent storage of a user identification.
When it is required to be described, the setting or generating time of the first access table and the time parameter value thereof do not belong to the same value, the setting or generating time of the first access table refers to the execution time of the setting action of the first access table from the end, the time parameter value of the first access table is an attribute value of the first access table, and the time parameter value is the same as the time of being started or operated of the target data to which the first access table belongs.
A first storage unit 704, configured to store the target user identifier in the first access table.
That is, the first access table has time parameter values corresponding to the start times of the target data, and at the same time, only the user identifier of the user who starts the access operation on the target data from the start time of the target data is stored in the first access table, as shown in fig. 2. Before the user identifier is stored, only the user identifier which is not stored in the first access table is stored by inquiring the identifier which is already stored in the first access table, so that the duplicate removal operation is realized, and in the inquiry of subsequent users, the duplicate removal processing is not required to be carried out again.
In a specific implementation, the apparatus may include a processor and a memory, and is disposed on a server or other terminals, where the operation obtaining unit 701, the identifier extracting unit 702, the identifier searching unit 703, the first storage unit 704, and the like are all stored in the memory as program units, and the processor executes the program units stored in the memory to implement corresponding functions.
The processor comprises a kernel, and the kernel calls the corresponding program unit from the memory. The kernel can be set to one or more, and statistics of which users have accessed the target data after the startup is carried out by adjusting the kernel parameters.
The memory may include volatile memory in a computer readable medium, Random Access Memory (RAM) and/or nonvolatile memory such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
By the above technical solution, the apparatus for acquiring data access information provided in the fourth embodiment of the present application, sets the first access table in advance based on the start time of the target data, and performs deduplication storage on the user identifier of the user performing the access operation on the target data, that is, only stores the user identifier that does not exist in the first access table, and does not need to respond to the user identifier that already exists in the first access table, so that the user identifier stored in the first access table represents the user performing the access operation on the target data after the target data is started, thereby obtaining the access information of the data, and in this process, the user identifier is extracted from the operation information accessing the target data in real time to further implement filling of the first access table, and operations such as direct query or data statistics on a database are not needed, thereby speeding up the calculation rate of the access information of the target data, the purpose of the application is achieved.
In one implementation, a worker such as an analyst may query which users access target data by querying the first access table, specifically, referring to fig. 8, which is a schematic structural diagram of an apparatus for acquiring data access information provided in the fifth embodiment of the present application, the apparatus may further include the following structure:
the first querying unit 705 is configured to receive a query request, where the query request is used to request that the accessed state of the target data is returned, and in this embodiment, each user identifier in the first access table is used to represent an operated or accessed state of the target data to which the first access table belongs. And the query request at least comprises query time, whether the query time is consistent with the time parameter value of the first access table is judged, and if so, the first access table is returned.
The query request at least comprises query time, and the query request containing the query time refers to a request for accessing operation by which users of target data required to be queried by a worker after the query time is started.
For example, in the streaming processing, after the target data is started, statistics is started on which users access the target data, if a staff member starts to inquire which users access the target data at this time, if which users watch the program, it is first checked whether the inquiry time in the inquiry request is consistent with the time parameter value of the first access table currently performing the streaming processing, if so, the first access table is directly returned, and at this time, the user identifier stored in the first access table is the identifier of the user who watches the program from the started time, for example, from point 17 of 2016.09.20.
In an implementation, in order to ensure reliability of data, the present embodiment may store both the extracted target user identifier and the start time of the corresponding target data, specifically, refer to fig. 9, which is a schematic structural diagram of an apparatus for acquiring data access information provided in a sixth embodiment of the present application, where the apparatus may further include the following structure:
a second storage unit 706, configured to, when the identifier searching unit 703 does not find the target user identifier in the first access table, store the target user identifier and the start time in a second access table preset for the target data.
That is, the second access table records the user id of the user whose target data is accessed at any activated time and the corresponding activation time, and the user id in the second access table is not repeated at any activated time of the target data, as shown in fig. 5, the video program is viewed by users A, B and C at 14 o 'clock of the activation time 2016.09.20 and by users A, C and D at 17 o' clock of 2016.09.20.
When the user identifier is provided to a staff member such as an analyst for querying the user identifier, it is necessary to determine whether the query time queried by the user is consistent with the start time of the target data of the current stream processing, so as to ensure the reliability of the query, specifically, as shown in fig. 10, the apparatus may further include the following structure:
a second query unit 707, configured to receive a query request, where the query request is used to request to return an accessed state of the target data, and the query request at least includes query time, determine whether the query time is consistent with a time parameter value of the first access table, if so, return the first access table, and if not, trigger the table query unit 708;
the query request at least comprises query time, and the query request containing the query time refers to a request for accessing operation by which users of target data required to be queried by a worker after the query time is started.
A table lookup unit 708 configured to perform a lookup in the second access table based on the lookup request.
That is to say, in this embodiment, it is first checked whether the query time in the query request is consistent with the start time of the target data in the query task for which users access the target data in the current stream processing, that is, whether the query time in the query request is consistent with the time parameter value of the first access table, if so, it indicates that the user needs to query the user identifier in the first access table generated in the current stream processing, at this time, the first access table is returned, and if not, it indicates that the user needs to check which users access other start times of the target data, and at this time, the user queries in the second access table including the access user identifier in which the target data is started at any time.
In a specific implementation, when the table query unit 708 accesses the target data started by the query time based on the query request in the second access table, the table query unit may specifically be implemented by a structure, as shown in fig. 11:
the time comparison subunit 781 is configured to compare the query time with each start time in the second access table;
an identifier returning sub-unit 782, configured to return, in the second access table, the user identifier corresponding to the start time that is consistent with the query time.
That is to say, in this embodiment, the query time is first compared with each start time in the second access table, and then the user identifier corresponding to the start time that is consistent with the query time in the second access table is returned.
For example, 14 points of time 2016.09.20 in the query request are compared with each starting time in the second access table shown in fig. 5, and the 14 points of consistent starting time 2016.09.20 are found, and then the user identifiers A, B and C corresponding to the starting time are returned.
The embodiment of the present application further provides a computer program product, which can be run on a data processing device such as a server, and when the computer program product in the embodiment is executed on the data processing device, the computer program product is adapted to execute a program code initialized with the following method steps:
acquiring operation information of target data in real time, wherein the target data has starting time; extracting a target user identifier of a user operating the target data in the operation information; and searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, wherein the first access table comprises the user identification, and if the target user identification does not exist, storing the target user identification into the first access table.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
The above are merely examples of the present application and are not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims (8)
1. A method for acquiring data access information is characterized by comprising the following steps:
acquiring operation information of target data in real time, wherein the target data has starting time;
extracting a target user identifier of a user operating the target data in the operation information;
searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, wherein the first access table comprises user identifications, if the target user identification does not exist, the target user identification is stored in the first access table, the target user identification and the starting time are stored in a second access table which is set for the target data in advance, the second access table records the user identifications of users who begin to be accessed at any starting time of the target data and corresponding starting time, the user identifications in the second access table are not repeated at any starting time of the target data, and the first access table only stores the user identifications of users who begin to access the target data at the starting time of the target data.
2. The method of claim 1, further comprising:
receiving a query request, wherein the query request is used for requesting to return the accessed state of the target data, and the query request at least comprises query time;
and judging whether the query time is consistent with a time parameter value of the first access table, and if so, returning the first access table.
3. The method of claim 2, further comprising:
receiving a query request, wherein the query request is used for requesting to return the accessed state of the target data, and the query request at least comprises query time;
and judging whether the query time is consistent with a time parameter value of the first access table, if so, returning the first access table, and if not, querying in the second access table based on the query request.
4. The method of claim 3, wherein querying in the second access table based on the query request comprises:
comparing the query time with each starting time in the second access table;
and returning the user identification corresponding to the starting time consistent with the query time in the second access table.
5. An apparatus for acquiring data access information, comprising:
the operation acquisition unit is used for acquiring operation information of target data in real time, and the target data has starting time;
an identification extraction unit configured to extract a target user identification of a user who operates the target data in the operation information;
the identification searching unit is used for searching whether the target user identification exists in a first access table which is set for the target data in advance and has a time parameter value consistent with the starting time, the first access table comprises the user identification, if the target user identification does not exist, the first storage unit and the second storage unit are triggered, and the first access table only stores the user identification of a user starting to access the target data from the starting time of the target data;
a first storage unit, configured to store the target user identifier in the first access table;
the second storage unit is used for storing the target user identification and the starting time into a second access table which is set for the target data in advance, the second access table records the user identification of the user who starts to be accessed at any starting time of the target data and the corresponding starting time, and the user identification in the second access table is not repeated at any starting time of the target data.
6. The apparatus of claim 5, further comprising:
the first query unit is used for receiving a query request, the query request is used for requesting to return the accessed state of the target data, the query request at least comprises query time, whether the query time is consistent with a time parameter value of the first access table or not is judged, and if yes, the first access table is returned.
7. The apparatus of claim 5, further comprising:
a second query unit, configured to receive a query request, where the query request is used to request a return of an accessed state of the target data, and the query request at least includes query time, and determine whether the query time is consistent with a time parameter value of the first access table, if so, return the first access table, and if not, trigger the table query unit;
a table query unit, configured to query the second access table based on the query request.
8. The apparatus of claim 7, wherein the table lookup unit comprises:
the time comparison subunit is used for comparing the query time with each starting time in the second access table;
and the identifier returning subunit is used for returning the user identifier corresponding to the starting time consistent with the query time in the second access table.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611105450.2A CN108153777B (en) | 2016-12-05 | 2016-12-05 | Method and device for acquiring data access information |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611105450.2A CN108153777B (en) | 2016-12-05 | 2016-12-05 | Method and device for acquiring data access information |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108153777A CN108153777A (en) | 2018-06-12 |
CN108153777B true CN108153777B (en) | 2022-02-22 |
Family
ID=62470057
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201611105450.2A Active CN108153777B (en) | 2016-12-05 | 2016-12-05 | Method and device for acquiring data access information |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108153777B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110955847B (en) * | 2018-09-26 | 2023-08-25 | 北京国双科技有限公司 | Information processing method, device, storage medium and processor |
CN112261134B (en) * | 2020-10-21 | 2023-06-30 | 阳光保险集团股份有限公司 | Network data access auditing method, device, equipment and storage medium |
CN112732807A (en) * | 2020-12-30 | 2021-04-30 | 福建卓融信息技术有限公司 | Interface calling method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103020058A (en) * | 2011-09-21 | 2013-04-03 | 阿里巴巴集团控股有限公司 | Multi-version data acquisition method and device |
CN103200281A (en) * | 2013-01-24 | 2013-07-10 | 中国联合网络通信集团有限公司 | Method, device and system for accessing intranet server |
CN103207882A (en) * | 2012-01-13 | 2013-07-17 | 阿里巴巴集团控股有限公司 | Shop visiting data processing method and system |
CN103577441A (en) * | 2012-07-30 | 2014-02-12 | 腾讯科技(深圳)有限公司 | Storage method and storage device for user operation data |
CN104298675A (en) * | 2013-07-18 | 2015-01-21 | 国际商业机器公司 | Method and device for cache management |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101473286B1 (en) * | 2011-02-10 | 2014-12-16 | 가부시키가이샤 엔.티.티.도코모 | Terminal number estimation device and terminal number estimation method |
-
2016
- 2016-12-05 CN CN201611105450.2A patent/CN108153777B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103020058A (en) * | 2011-09-21 | 2013-04-03 | 阿里巴巴集团控股有限公司 | Multi-version data acquisition method and device |
CN103207882A (en) * | 2012-01-13 | 2013-07-17 | 阿里巴巴集团控股有限公司 | Shop visiting data processing method and system |
CN103577441A (en) * | 2012-07-30 | 2014-02-12 | 腾讯科技(深圳)有限公司 | Storage method and storage device for user operation data |
CN103200281A (en) * | 2013-01-24 | 2013-07-10 | 中国联合网络通信集团有限公司 | Method, device and system for accessing intranet server |
CN104298675A (en) * | 2013-07-18 | 2015-01-21 | 国际商业机器公司 | Method and device for cache management |
Also Published As
Publication number | Publication date |
---|---|
CN108153777A (en) | 2018-06-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106326309B (en) | Data query method and device | |
CN106202235B (en) | Data processing method and device | |
CN107015985B (en) | Data storage and acquisition method and device | |
CN108153777B (en) | Method and device for acquiring data access information | |
CN107832440B (en) | Data mining method, device, server and computer readable storage medium | |
CN106970958B (en) | A kind of inquiry of stream file and storage method and device | |
CN109033360B (en) | Data query method, device, server and storage medium | |
CN110704418A (en) | Block chain information query method, device and equipment | |
CN111784468B (en) | Account association method and device and electronic equipment | |
CN105528218A (en) | Data diagram cascaded method and data diagram cascaded system | |
CN104778252B (en) | The storage method and device of index | |
KR20200121744A (en) | Method and device for processing user personal, server and storage medium | |
CN106648839B (en) | Data processing method and device | |
CN107451204B (en) | Data query method, device and equipment | |
CN103279489A (en) | Method and device for storing metadata | |
CN107644033B (en) | Method and equipment for querying data in non-relational database | |
CN107622090B (en) | Object acquisition method, device and system | |
CN111176574B (en) | Small file storage method, device, equipment and medium | |
CN107562703B (en) | Dictionary tree reconstruction method and system | |
CN111125087B (en) | Data storage method and device | |
CN109561126B (en) | Data synchronization method and device, storage medium and processor | |
CN108121733B (en) | Data query method and device | |
CN107562533B (en) | Data loading processing method and device | |
EP3616092A1 (en) | Media sharing based on identified physical objects | |
CN108073596B (en) | Data deletion method and device for OLAP database |
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 | ||
CB02 | Change of applicant information | ||
CB02 | Change of applicant information |
Address after: 100080 No. 401, 4th Floor, Haitai Building, 229 North Fourth Ring Road, Haidian District, Beijing Applicant after: Beijing Guoshuang Technology Co.,Ltd. Address before: 100086 Cuigong Hotel, 76 Zhichun Road, Shuangyushu District, Haidian District, Beijing Applicant before: Beijing Guoshuang Technology Co.,Ltd. |
|
GR01 | Patent grant | ||
GR01 | Patent grant |