CN104468782A - Network data obtaining method and device - Google Patents

Network data obtaining method and device Download PDF

Info

Publication number
CN104468782A
CN104468782A CN201410740506.6A CN201410740506A CN104468782A CN 104468782 A CN104468782 A CN 104468782A CN 201410740506 A CN201410740506 A CN 201410740506A CN 104468782 A CN104468782 A CN 104468782A
Authority
CN
China
Prior art keywords
service end
request
time
client
time interval
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201410740506.6A
Other languages
Chinese (zh)
Other versions
CN104468782B (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.)
Beijing Gridsum Technology Co Ltd
Original Assignee
Beijing Gridsum Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Gridsum Technology Co Ltd filed Critical Beijing Gridsum Technology Co Ltd
Priority to CN201410740506.6A priority Critical patent/CN104468782B/en
Publication of CN104468782A publication Critical patent/CN104468782A/en
Application granted granted Critical
Publication of CN104468782B publication Critical patent/CN104468782B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols

Abstract

The invention discloses a network data obtaining method and device. The network data obtaining method includes the steps that a server side obtained first request time; the server side obtains second request time; the server side calculates the digital acquisition number according to the first request time, the second request time and the preset acquisition time interval; the server side obtains the digits collected from the first request time to the second request time; the server side calculates the target digit according to the collected digits and the digit acquisition number; the server side sends the target digit to a client side. According to the network data obtaining method and device, the problem that the accuracy of obtaining data from the server side of the client side excessively depends on the time interval of sending a request of the client side, and consequently the accuracy of obtaining the data is improved at the cost of lowering the performance of the client side is solved, the target digit is calculated by the client side according to the collected digits and the digit acquisition number, and the effect of improving the accuracy of the network data received by the client side without shortening the time interval of sending the request by the client side is achieved.

Description

Network Data Capture method and device
Technical field
The present invention relates to internet arena, in particular to a kind of Network Data Capture method and device.
Background technology
In daily life or production operation, a lot of data need Real-time Collection, and study the Changing Pattern of the data collected, thus instruct daily life or production operation.Such as, the data situation such as Real-time Collection temperature, air humidity, PM2.5; Or, in internet arena, the volume of the flow of passengers of Real-time Collection website.Under normal circumstances, we utilize service end Real-time Collection such as above-mentioned data, then the data that service end obtains are sent to client, study at the Changing Pattern of client to data.
Generally, adopt real-time system based on poll through the mode of Fixed Time Interval to service end poll inquiry data, request service end provides real time data to client.Due to the restriction on client performance, often the poll inquiry time interval is longer than the time interval of service end image data.Therefore, the real time data that client obtains at every turn is interrupted (namely can not obtain each real time data that service end gathers), and due to reasons such as the delay on network or request loss, may cause and show the data of client to be inaccurate in some moment.Such as, due to network delay, make when the data of client first time request not yet return client, the data of second time request arrive client.The Changing Pattern of this Changing Pattern of data and the data of service end actual acquisition of just causing client acquisition produces deviation.So the data adopting traditional approach to obtain can not embody the Changing Pattern of True Data.Fig. 1 is the schematic diagram of the network data that existing method obtains.The data of service end collection upgraded according to the time interval of 1 second, and client sent a request message at interval of 5 seconds to service end.Fig. 1 gives the situation of change of the situation of change of the data that service end gathers and the data of client acquisition.As can be seen from Figure 1, because client just obtains the data in certain several moment in the data of service end collection, the data in major part moment do not obtain, and therefore, the real change situation of the data that the situation of change of these data and service end gather differs larger.
Usually, as far as possible the method for head it off shortens polling time interval, namely shortens the time interval that client sends a request message to service end.This method makes client can get more data, thus the Changing Pattern of these data is also more close to the change of True Data.But also there is following problem in the method simultaneously: the shortening of polling time interval can increase the weight of service end and client bandwidth consumption, affect client performance; Because network request is unordered, too short polling time interval can cause when upper once ask not return, second time request prior to the last time request pass client back.Therefore, although existing mode can improve the accuracy of data that client obtains to a certain extent, be but sacrifice client performance and bandwidth is cost; Further, when polling time interval is too short, the accuracy of the data that client obtains can be reduced on the contrary.
For in correlation technique due to client from service end obtain the accuracy of data be overly dependent upon time interval that client sends request and cause improve the problem of the accuracy obtaining data with loss client performance for cost, at present effective solution is not yet proposed.
Summary of the invention
The problem of the network data poor accuracy obtained from service end for existing client and propose the present invention, for this reason, main purpose of the present invention is to provide a kind of Network Data Capture method and device, to solve the problem.
To achieve these goals, according to an aspect of the present invention, a kind of Network Data Capture method is provided.The method comprises: service end obtains the first request time, wherein, first request time is the time that the last request message sent to service end of client arrives service end, and service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval; Service end obtains the second request time, wherein, the second request time be this request message sent to service end of client arrive service end time; Service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number; Service end obtains the numeral gathered in the first request time to the second request time; Service end calculates target number according to the numeral gathered and digital collection number; Target number is sent to client by service end.
Further, service end comprises according to the first request time, the second request time and default acquisition time interval calculation digital collection number: determine default acquisition time interval; Calculate digital collection number in such a way: P=[(T 2-T 1)/t], wherein, P is digital collection number, T 2be the second request time, T 1be the first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.
Further, the second request time is client first time arrive the time of service end to the request that service end sends, and service end obtains the first request time and comprises: service end determines that the second request time is the first request time.
Further, service end comprises according to the numeral gathered and digital collection number calculating target number: service end calculates the digital sum gathered; Calculate target number in such a way: Q=A/P, wherein, Q is target number, and A is the digital sum gathered.
Further, before service end obtains the first request time, the method also comprises: client determination polling time interval, and wherein, polling time interval is the time interval that client sends between the first request message and the second request message; According to polling time interval, client sends the first request message, wherein, first request message is that last client-requested obtains the message of data from service end, before service end obtains the second request time, the method also comprises: according to polling time interval, and client sends the second request message, wherein, the second request message is that this client-requested obtains the message of data from service end.
To achieve these goals, according to a further aspect in the invention, provide a kind of Network Data Capture device, this device comprises: the first acquiring unit, obtain the first request time for service end, wherein, the first request time is the time that the last request sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval; Second acquisition unit, obtains the second request time for service end, wherein, the second request time be this request sent to service end of client arrive service end time; First computing unit, for service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number; 3rd acquiring unit, obtains the numeral gathered in the first request time to the second request time for service end; Second computing unit, calculates target number for service end according to the numeral gathered and digital collection number; Transmitting element, sends to client for service end by target number.
Further, the first computing unit comprises: determination module, for determining default acquisition time interval; First computing module, for calculating digital collection number in such a way: P=[(T 2-T 1)/t], wherein, P is digital collection number, and T2 is the second request time, and T1 is the first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.
Further, the second request time is client first time arrive the time of service end to the request that service end sends, for service end, the first acquiring unit also determines that the second request time is the first request time.
Further, the second computing unit comprises: the second computing module, calculates the digital sum gathered for service end; 3rd computing module, for calculating target number in such a way: Q=A/P, wherein, Q is target number, and A is the digital sum gathered.
Further, this device also comprises: determining unit, and for client determination polling time interval, wherein, polling time interval is the time interval that client sends between the first request message and the second request message; First request unit, for according to polling time interval, client sends the first request message, and wherein, the first request message is that last client-requested obtains the message of data from service end; Second request unit, for according to polling time interval, client sends the second request message, and wherein, the second request message is that this client-requested obtains the message of data from service end.
Pass through the present invention, adopt the method comprised the following steps: service end obtains the first request time, wherein, first request time is the time that the last request sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval; Service end obtains the second request time, wherein, the second request time be this request sent to service end of client arrive service end time; Service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number; Service end obtains the numeral gathered in the first request time to the second request time; Service end calculates target number according to the numeral gathered and digital collection number; Target number is sent to client by service end, solve client from service end obtain the accuracy of data be overly dependent upon time interval that client sends request and cause with loss client performance for cost improves the problem of the accuracy obtaining data, and then calculate target number by service end according to the numeral gathered and digital collection number, and target number is sent to client, reach and do not need to shorten the effect that time interval of sending request of client can improve the accuracy of the network data that client receives.
Accompanying drawing explanation
The accompanying drawing forming a application's part is used to provide a further understanding of the present invention, and schematic description and description of the present invention, for explaining the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the schematic diagram of the network data that existing method obtains;
Fig. 2 is the flow chart of the first embodiment according to Network Data Capture method of the present invention;
Fig. 3 is the schematic diagram of the network data according to the present invention's acquisition;
Fig. 4 is the flow chart of the second embodiment according to Network Data Capture method of the present invention; And
Fig. 5 is the schematic diagram of the first embodiment according to Network Data Capture device of the present invention.
Embodiment
The present invention program is understood better in order to make those skilled in the art person, below in conjunction with the accompanying drawing in the embodiment of the present invention, technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the embodiment of a part of the present invention, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, should belong to the scope of protection of the invention.
It should be noted that, term " first ", " second " etc. in specification of the present invention and claims and above-mentioned accompanying drawing are for distinguishing similar object, and need not be used for describing specific order or precedence.In addition, term " comprises " and " having " and their any distortion, intention is to cover not exclusive comprising, such as, contain those steps or unit that the process of series of steps or unit, method, system, product or equipment is not necessarily limited to clearly list, but can comprise clearly do not list or for intrinsic other step of these processes, method, product or equipment or unit.
When not conflicting, the embodiment in the application and the feature in embodiment can combine mutually.Below with reference to the accompanying drawings and describe the present invention in detail in conjunction with the embodiments.
Fig. 2 is the flow chart of the first embodiment according to Network Data Capture method of the present invention.As shown in Figure 2, the method comprising the steps of S102 is to step S112.
Step S102, service end obtains the first request time, and wherein, the first request time is the time that the last request message sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval.
Step S104, service end obtains the second request time, wherein, the second request time be this request message sent to service end of client arrive service end time.
When client needs to obtain service end data, request message can be sent to client.Due to reasons such as network delays, can there is the delay of a period of time in the time that sends of time and this request message that this request message reaches service end.The time of service end record client request message arrival each time service end in the present invention.Double request message arrived between the time difference of service end and the client double time interval sending request message does not have restricting relation, due to the randomness of network request, the time difference of double request message arrival service end may be greater than, be less than or equal to the client double time interval sending request message.
The client double time interval sending request can be fixed time interval, also it is possible that change.The time interval of service end collection numeral can be fixed time interval, also it is possible that change.Service end often receives the request message that client is sent, just time of reaching of this request message of instant recording, and is recorded as this time this time, and the front time of once recording is defaulted as the last time.It should be noted that, if the second request time is client first time arrive the time of service end to the request that service end sends, service end will determine that the second request time is the first request time.
Step S106, service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number.
Step S108, service end obtains the numeral gathered in the first request time to the second request time.
Service end the first request time and within the second request time time interval in continuous image data, client sent in the time interval between request message can comprise some data, but client does not have request service end sends these data.In the present invention, service end utilizes the first request time, the second request time and default acquisition time interval, the first request time can be calculated and the number of numeral that within the second request time time interval, service end gathers, and determine the first request time and the numeral that within the second request time time interval, client is not asked.Take into full account the first request time and within the second request time time interval service end gather the number of numeral and the numeral within this period, the situation of change of numeral in this period can be embodied better, avoid the comparatively big error on the numeral change global regularity of the numeral only obtaining fixed time (the first request time or the second request time) and the final acquisition brought.
Service end can be carried out according to following steps according to the first request time, the second request time and default acquisition time interval calculation digital collection number: determine default acquisition time interval; Calculate digital collection number in such a way: P=[(T 2-T 1)/t], wherein, P is digital collection number, T 2be the second request time, T 1be the first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.Such as, the real time data of service end acquisition is as shown in table 1.First request time is t=1s, and the second request time is t=5s, and default acquisition time is spaced apart 1s, and therefore, can calculate digital collection number according to above-mentioned formula is 4.The numeral of service end collection in this period of time interval is 36,27,19 and 38.Numeral according to digital collection number and collection in this period of time interval can obtain target number, and namely service end will send to the numeral of client.
Table 1
Acquisition time (t) 1s 2s 3s 4s 5s 6s
Numeral 25 36 27 19 38 26
Step S110, service end calculates target number according to the numeral gathered and digital collection number.
According to the numeral gathered and digital collection number, service end can calculate target number in such a way: service end calculates the digital sum gathered; Calculate target number in such a way: Q=A/P, wherein, Q is target number, and A is the digital sum gathered.
The first request time and the arithmetic mean in the second request time time interval is calculated according to the numeral gathered and digital collection number, make the target number obtained more can reflect the first request time and the digital Changing Pattern in the second request time time interval, avoid because the numeral of corresponding first request time or the second request time is comparatively large because the reasons such as network depart from, and the first request time causing client to obtain and the digital Changing Pattern in the second request time time interval produce larger error.
Step S112, target number is sent to client by service end.
The target number calculated is sent to client by service end, and client sends time interocclusal record this target number of target number according to service end.According to different user's requests, the multiple target number reaching client within a period of time can be obtained, the plurality of target number is analyzed, the Changing Pattern of the plurality of target number can be obtained.The Changing Pattern of numeral that the Changing Pattern of the target number obtained according to the present invention will gather close to service end more.
Fig. 3 is the schematic diagram of the network data according to the present invention's acquisition.The default acquisition time of service end is spaced apart 1s as can be seen from Figure 3, and the time that client request message arrives service end is t=1s, 5s and 14s.T=1s is arrived the time of service end as last request message, t=5s arrives the time of service end as this request message, the data amount check gathered in t=1s to the t=5s time is 4, the numeral gathered is respectively 69,27,33 and 54, can calculate target number for (69+27+33+54)/4 according to the numeral gathered and digital collection number.T=5s is arrived the time of service end as last request message, t=14s arrives the time of service end as this request message, the data amount check gathered in t=5s to the t=14s time is 9, the numeral gathered is respectively 98,101,77,92,45,27,33,87 and 65, can calculate target number for (98+101+77+92+45+27+33+87+65)/9 according to the numeral gathered and digital collection number.
This embodiment is owing to taking following steps: service end obtains the first request time, wherein, first request time is the time that the last request message sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval; Service end obtains the second request time, wherein, the second request time be this request message sent to service end of client arrive service end time; Service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number; Service end obtains the numeral gathered in the first request time to the second request time; Service end calculates target number according to the numeral gathered and digital collection number; Target number is sent to client by service end, solve client from service end obtain the accuracy of data be overly dependent upon polling time interval and cause with loss client performance for cost improves the problem of the accuracy obtaining data, and then calculate target number by service end according to the numeral gathered and digital collection number, and target number is sent to client, reach and do not need to shorten the effect that time interval of sending request of client can improve the accuracy of the network data that client receives.
Fig. 4 is the flow chart of the second embodiment according to Network Data Capture method of the present invention.This embodiment can as a kind of preferred implementation embodiment illustrated in fig. 2.As shown in Figure 3, the method comprising the steps of S201 is to step S209.
Step S201, client determination polling time interval, wherein, polling time interval is the time interval that client sends between the first request message and the second request message.
Preferably, based on the real-time system of poll, client can preset polling time interval before sending a request message to service end, and often through a polling time interval, client can send a request message to service end.Client can send multiple request message according to demand automatically, is conducive to obtaining a large amount of target number, very favourable for the execution efficiency improving whole flow process.
Such as, client setting polling time interval is 5s, and namely client sends the time interval of the first request message and the second request message is 5s.Like this, client can at t=1s, 5s, 10s ... respectively send a request message to service end.
Step S202, according to polling time interval, client sends the first request message, and wherein, the first request message is that last client-requested obtains the message of data from service end.
Step S203, service end obtains the first request time, and wherein, the first request time is the time that the last request message sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval.
This step, with step S102, repeats no more here.
Step S204, according to polling time interval, client sends the second request message, and wherein, the second request message is that this client-requested obtains the message of data from service end.
Step S205, service end obtains the second request time, wherein, the second request time be this request message sent to service end of client arrive service end time.
This step, with step S104, repeats no more here.
Step S206, service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number.
This step, with step S106, repeats no more here.
Step S207, service end obtains the numeral gathered in the first request time to the second request time.
This step, with step S108, repeats no more here.
Step S208, service end calculates target number according to the numeral gathered and digital collection number;
This step, with step S110, repeats no more here.
Step S209, target number is sent to client by service end.
This step, with step S112, repeats no more here.
This embodiment is owing to taking following steps: client determination polling time interval, and wherein, polling time interval is the time interval that client sends between the first request message and the second request message; According to polling time interval, client sends the first request message, and wherein, the first request message is that last client-requested obtains the message of data from service end; Service end obtains the first request time, wherein, first request time is the time that the last request message sent to service end of client arrives service end, and service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval; According to polling time interval, client sends the second request message, and wherein, the second request message is that this client-requested obtains the message of data from service end; Service end obtains the second request time, wherein, the second request time be this request message sent to service end of client arrive service end time; Service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number; Service end obtains the numeral gathered in the first request time to the second request time; Service end calculates target number according to the numeral gathered and digital collection number; Target number is sent to client by service end, makes client can send the message of request msg from trend service end according to polling time interval, is conducive to obtaining a large amount of target number, can improve the execution efficiency of whole Network Data Capture flow process.
It should be noted that, the Network Data Capture device of the embodiment of the present invention may be used for performing the Network Data Capture method that the embodiment of the present invention provides, and the Network Data Capture device that the Network Data Capture method of the embodiment of the present invention also can be provided by the embodiment of the present invention performs.
Fig. 5 is the schematic diagram of the first embodiment according to Network Data Capture device of the present invention.As shown in Figure 5, this apparatus structure comprises: the first acquiring unit 20, second acquisition unit 30, first computing unit 40, the 3rd acquiring unit 50, second computing unit 60 and transmitting element 70.
First acquiring unit 20, obtain the first request time for service end, wherein, the first request time is the time that the last request sent to service end of client arrives service end, service end is for gathering numeral, and service end gathers the time interval of numeral for presetting acquisition time interval.
Second request time is client first time arrive the time of service end to the request that service end sends, for service end, the first acquiring unit 20 also determines that the second request time is the first request time.
Second acquisition unit 30, obtains the second request time for service end, wherein, the second request time be this request sent to service end of client arrive service end time.
First computing unit 40, for service end according to the first request time, the second request time and default acquisition time interval calculation digital collection number, wherein, digital collection number be the first request time to the second request time the time interval in service end gather digital number.
First computing unit 40 can also comprise: determination module, for determining default acquisition time interval; First computing module, for calculating digital collection number in such a way: P=[(T 2-T 1)/t], wherein, P is digital collection number, T 2be the second request time, T 1be the first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.
3rd acquiring unit 50, obtains the numeral gathered in the first request time to the second request time for service end.
Second computing unit 60, calculates target number for service end according to the numeral gathered and digital collection number.
Second computing unit 60 comprises: the second computing module, calculates the digital sum gathered for service end; 3rd computing module, for calculating target number in such a way: Q=A/P, wherein, Q is target number, and A is the digital sum gathered.
Transmitting element 70, sends to client for service end by target number.
Alternatively, this device can also comprise: determining unit, and for client determination polling time interval, wherein, polling time interval is the time interval that client sends between the first request message and the second request message; First request unit, for according to polling time interval, client sends the first request message, and wherein, the first request message is that last client-requested obtains the message of data from service end; Second request unit, for according to polling time interval, client sends the second request message, and wherein, the second request message is that this client-requested obtains the message of data from service end.
The Network Data Capture device that the present embodiment provides comprises: the first acquiring unit 20, second acquisition unit 30, first computing unit 40, the 3rd acquiring unit 50, second computing unit 60 and transmitting element 70.By this device, solve client from service end obtain the accuracy of data be overly dependent upon polling time interval and cause with loss client performance for cost improves the problem of the accuracy obtaining data, and then calculate target number by service end according to the numeral gathered and digital collection number, and target number is sent to client, reach and do not need to shorten the effect that time interval of sending request of client can improve the accuracy of the network data that client receives.
Obviously, those skilled in the art should be understood that, above-mentioned of the present invention each module or each step can realize with general calculation element, they can concentrate on single calculation element, or be distributed on network that multiple calculation element forms, alternatively, they can realize with the executable program code of calculation element, thus, they can be stored and be performed by calculation element in the storage device, or they are made into each integrated circuit modules respectively, or the multiple module in them or step are made into single integrated circuit module to realize.Like this, the present invention is not restricted to any specific hardware and software combination.
These are only the preferred embodiments of the present invention, be not limited to the present invention, for a person skilled in the art, the present invention can have various modifications and variations.Within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. a Network Data Capture method, is characterized in that, described method comprises:
Service end obtains the first request time, wherein, described first request time is the time that the last request message sent to described service end of client arrives described service end, described service end is for gathering numeral, and described service end gathers the time interval of numeral for presetting acquisition time interval;
Described service end obtains the second request time, wherein, described second request time be described client this to the request message that described service end sends arrive described service end time;
Described service end is according to described first request time, described second request time and described default acquisition time interval calculation digital collection number, wherein, described digital collection number is the digital number that in described first request time to the time interval of described second request time, described service end gathers;
Described service end obtains the numeral gathered in described first request time to described second request time;
Described service end calculates target number according to the numeral of described collection and described digital collection number; And
Described target number is sent to described client by described service end.
2. method according to claim 1, is characterized in that, described service end comprises according to described first request time, described second request time and described default acquisition time interval calculation digital collection number:
Determine described default acquisition time interval; And
Calculate described digital collection number in such a way:
P=[(T 2-T 1)/t], wherein, P is described digital collection number, T 2for described second request time, T 1for described first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.
3. method according to claim 2, it is characterized in that, described second request time is the time described client first time arriving described service end to the request that described service end sends, and service end obtains the first request time and comprises: described service end determines that described second request time is described first request time.
4. method according to claim 3, is characterized in that, described service end calculates target number according to the numeral of described collection and described digital collection number and comprises:
Described service end calculates the digital sum of described collection; And
Calculate described target number in such a way:
Q=A/P, wherein, Q is described target number, and A is the digital sum of described collection.
5. method according to claim 1, is characterized in that,
Before service end obtains the first request time, described method also comprises:
Described client determination polling time interval, wherein, described polling time interval is the time interval that described client sends between described first request message and described second request message; And
According to described polling time interval, described client sends described first request message, and wherein, described first request message is that last described client-requested obtains the message of data from described service end,
Before described service end obtains the second request time, described method also comprises: according to described polling time interval, described client sends described second request message, and wherein, described second request message is for client-requested described in this is from the message of described service end acquisition data.
6. a Network Data Capture device, is characterized in that, described device comprises:
First acquiring unit, the first request time is obtained for service end, wherein, described first request time is the time that the last request sent to described service end of client arrives described service end, described service end is for gathering numeral, and described service end gathers the time interval of numeral for presetting acquisition time interval;
Second acquisition unit, obtains the second request time for described service end, wherein, described second request time be described client this to the request that described service end sends arrive described service end time;
First computing unit, for described service end according to described first request time, described second request time and described default acquisition time interval calculation digital collection number, wherein, described digital collection number is the digital number that in described first request time to the time interval of described second request time, described service end gathers;
3rd acquiring unit, obtains the numeral gathered in described first request time to described second request time for described service end;
Second computing unit, calculates target number for described service end according to the numeral of described collection and described digital collection number; And
Transmitting element, sends to described client for described service end by described target number.
7. device according to claim 6, is characterized in that, described first computing unit comprises:
Determination module, for determining described default acquisition time interval; And
First computing module, for calculating described digital collection number in such a way:
P=[(T 2-T 1)/t], wherein, P is described digital collection number, T 2for described second request time, T 1for described first request time, [(T 2-T 1)/t] for being less than or equal to (T 2-T 1the maximum integer of)/t.
8. device according to claim 7, it is characterized in that, described second request time is the time described client first time arriving described service end to the request that described service end sends, for described service end, described first acquiring unit also determines that described second request time is described first request time.
9. device according to claim 8, is characterized in that, described second computing unit comprises:
Second computing module, calculates the digital sum of described collection for described service end; And
3rd computing module, for calculating described target number in such a way:
Q=A/P, wherein, Q is described target number, and A is the digital sum of described collection.
10. device according to claim 6, is characterized in that, described device also comprises:
Determining unit, for described client determination polling time interval, wherein, described polling time interval is the time interval that described client sends between described first request message and described second request message;
First request unit, for according to described polling time interval, described client sends described first request message, and wherein, described first request message is that last described client-requested obtains the message of data from described service end; And
Second request unit, for according to described polling time interval, described client sends described second request message, and wherein, described second request message to obtain the message of data for client-requested described in this from described service end.
CN201410740506.6A 2014-12-05 2014-12-05 Network Data Capture method and device Active CN104468782B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410740506.6A CN104468782B (en) 2014-12-05 2014-12-05 Network Data Capture method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410740506.6A CN104468782B (en) 2014-12-05 2014-12-05 Network Data Capture method and device

Publications (2)

Publication Number Publication Date
CN104468782A true CN104468782A (en) 2015-03-25
CN104468782B CN104468782B (en) 2017-11-14

Family

ID=52914134

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410740506.6A Active CN104468782B (en) 2014-12-05 2014-12-05 Network Data Capture method and device

Country Status (1)

Country Link
CN (1) CN104468782B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106452898A (en) * 2016-11-01 2017-02-22 武汉斗鱼网络科技有限公司 Data request control method and apparatus

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030145236A1 (en) * 2002-01-30 2003-07-31 Kabushiki Kaisha Toshiba Server computer protection apparatus and method for controlling data transfer by the same
US20030233453A1 (en) * 2002-06-18 2003-12-18 Institute For Information Industry Topology probing method for mobile IP system
CN101094107A (en) * 2006-06-21 2007-12-26 北京网视天元信息技术有限公司 System and method for accurate measuring transmission effect of P2P stream media netwrok for video / audio programs
CN102497284A (en) * 2011-12-06 2012-06-13 摩卡软件(天津)有限公司 Method and system for integrating alarms of monitoring software
CN102571687A (en) * 2010-12-10 2012-07-11 联芯科技有限公司 Method for building synchronous status information among real-time media streams, device adopting same and SCC AS
CN103023701A (en) * 2012-12-07 2013-04-03 瑞斯康达科技发展股份有限公司 Method and device for analyzing performance parameters of network management system
CN103807988A (en) * 2014-03-12 2014-05-21 侯春海 Air conditioner control method for reserving comfortable environmental temperature

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030145236A1 (en) * 2002-01-30 2003-07-31 Kabushiki Kaisha Toshiba Server computer protection apparatus and method for controlling data transfer by the same
US20030233453A1 (en) * 2002-06-18 2003-12-18 Institute For Information Industry Topology probing method for mobile IP system
CN101094107A (en) * 2006-06-21 2007-12-26 北京网视天元信息技术有限公司 System and method for accurate measuring transmission effect of P2P stream media netwrok for video / audio programs
CN102571687A (en) * 2010-12-10 2012-07-11 联芯科技有限公司 Method for building synchronous status information among real-time media streams, device adopting same and SCC AS
CN102497284A (en) * 2011-12-06 2012-06-13 摩卡软件(天津)有限公司 Method and system for integrating alarms of monitoring software
CN103023701A (en) * 2012-12-07 2013-04-03 瑞斯康达科技发展股份有限公司 Method and device for analyzing performance parameters of network management system
CN103807988A (en) * 2014-03-12 2014-05-21 侯春海 Air conditioner control method for reserving comfortable environmental temperature

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106452898A (en) * 2016-11-01 2017-02-22 武汉斗鱼网络科技有限公司 Data request control method and apparatus

Also Published As

Publication number Publication date
CN104468782B (en) 2017-11-14

Similar Documents

Publication Publication Date Title
US10536543B2 (en) Methods and apparatus to share online media impressions data
CN109426884B (en) Distribution scheme determination method, device and computer readable storage medium
US20210021887A1 (en) Methods and apparatus to associate audience members with over-the-top device media impressions
WO2020028602A3 (en) Method and system for a network presence platform with intelligent routing
CN103177380A (en) Method and device for optimizing advertisement delivery effect by combining user groups and pre-delivery
CN103840950A (en) Information pushing method and system
CN104122865A (en) Agricultural machine fault analyzing and maintaining method and system
CN108628721B (en) User data value abnormality detection method, device, storage medium, and electronic device
CN104202220A (en) Pressure test method and pressure test device
CN103595576A (en) Interconnection port ICP flow statistical system and method based on content provider identifications
RU2015105984A (en) METHOD, DEVICE AND SYSTEM OF DATA PROCESSING IN REAL TIME
CN103039116A (en) Information analysis device and information analysis method
CN105791144A (en) Method and apparatus for sharing link traffic
CN105163277A (en) Position information-based big data task management system and method
US10116535B1 (en) Monitoring internet usage on home networks of panelist users using a measurement device
CN108512869A (en) A kind of method and system handling concurrent data using asynchronization mode
US20180084556A1 (en) Data routing method and device
CN106534239A (en) Method and device for acquiring perception data
CN105530304A (en) Internet of things sensing cloud system for widely accessing devices
CN104468782A (en) Network data obtaining method and device
CN102880686B (en) A kind of interest point search method and device
CN104125115A (en) Log information transferring method and device
US8811958B2 (en) Communication system, information analysis device, and information analysis method
CN103200585B (en) Signaling traffic subsystem, extension counter treatment system and method
CN103024091B (en) Obtain method and the device of networking client actual physical address

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
PE01 Entry into force of the registration of the contract for pledge of patent right
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: Network data obtaining method and device

Effective date of registration: 20190531

Granted publication date: 20171114

Pledgee: Shenzhen Black Horse World Investment Consulting Co., Ltd.

Pledgor: Beijing Guoshuang Technology Co.,Ltd.

Registration number: 2019990000503

CP02 Change in the address of a patent holder
CP02 Change in the address of a patent holder

Address after: 100083 No. 401, 4th Floor, Haitai Building, 229 North Fourth Ring Road, Haidian District, Beijing

Patentee after: Beijing Guoshuang Technology Co.,Ltd.

Address before: 100086 Beijing city Haidian District Shuangyushu Area No. 76 Zhichun Road cuigongfandian 8 layer A

Patentee before: Beijing Guoshuang Technology Co.,Ltd.