CN106027415A - Data report method and device - Google Patents

Data report method and device Download PDF

Info

Publication number
CN106027415A
CN106027415A CN201610355246.XA CN201610355246A CN106027415A CN 106027415 A CN106027415 A CN 106027415A CN 201610355246 A CN201610355246 A CN 201610355246A CN 106027415 A CN106027415 A CN 106027415A
Authority
CN
China
Prior art keywords
data
nonurgent
type data
preset duration
application
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.)
Pending
Application number
CN201610355246.XA
Other languages
Chinese (zh)
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.)
Nubia Technology Co Ltd
Original Assignee
Nubia 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 Nubia Technology Co Ltd filed Critical Nubia Technology Co Ltd
Priority to CN201610355246.XA priority Critical patent/CN106027415A/en
Publication of CN106027415A publication Critical patent/CN106027415A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a data report device. The device comprises a storage module which is used for storing data when the data sent by a software development tool is received each time, wherein the data is the data collected by the software development tool when an application corresponding to the software development tool is being operated, and the data comprises emergency data and general data; a first sending module which is used for reporting the emergency data stored in first preset duration to a server every other the first preset duration; a second sending module which is used for reporting the general data stored in second preset duration to the server every other the second preset duration, wherein the first preset duration is shorter than the second preset duration. The invention also discloses a data report method. According to the method and the device, low power consumption is realized, and moreover, the emergency data is reported timely.

Description

Data reporting device and method
Technical field
The present invention relates to communication technical field, particularly relate to a kind of data reporting device and method.
Background technology
In the mobile Internet epoch, along with popularizing of the terminals such as smart mobile phone, PAD (panel computer), the various application of form color color are arisen at the historic moment.When each application is in operation, corresponding data can be recorded and reported to server, by server, the data reported being analyzed, thus realizing formulating the application effect such as the development plan of next version, application migration efficiency according to analysis result.The existing mode that data report to server mainly includes following two: (1), integrated data statistics SDK SDK (Software Development Kit in each application, SDK), each SDK SDK the Dynamic data exchange that correspondence application runs is reported to server;(2), application timing is reported to report to server by data each application service data unification.In (1st) kind mode, owing to SDK is whenever collecting data, just reported to server, although needing, for some, the nonurgent type data that reports in time, can reach to report in time the effect of server, but due to constantly reported data, result in the highest power consumption;In (2nd) kind mode, the unified timing of application is reported to report by data, although to reduce power consumption, but there is the problem that nonurgent type data can not report in time.In a word, the mode of existing reported data cannot be taken into account low-power consumption and report nonurgent type data in time.
Summary of the invention
Present invention is primarily targeted at a kind of data reporting device of proposition and method, it is intended to solve prior art can not be taken into account low-power consumption and report the technical problem of nonurgent type data in time.
For achieving the above object, a kind of data reporting device that the present invention provides, described data reporting device includes:
Memory module, for when receiving the data that SDK sends every time, preserve described data, wherein, described data are that the application that described SDK is corresponding is when being in operation, the data that described SDK gathers, described data include nonurgent type data and general type data;
First sending module, for reporting to server at interval of the first preset duration by the nonurgent type data preserved in described first preset duration;
Second sending module, for reporting to described server at interval of the second preset duration by the general type data preserved in described second preset duration;Wherein, described first preset duration is less than described second preset duration.
Alternatively, described data reporting device also includes:
Acquisition module, for at interval of the first preset duration, obtain the interior data being packaged with urgent identification information preserved of described first preset duration, wherein, described SDK, when according to the data form encapsulation of data preset, encapsulates urgent identification information in nonurgent type data;
Determining module, the data being used for be packaged with described urgent identification information are as nonurgent type data.
Alternatively, described data reporting device also includes:
Whether the first judge module, be nonurgent type data for judging the described data being currently received;
Second judge module, for when the described data being currently received are nonurgent type data, it is determined whether have started to timing;
Timing module, for when not starting timing, starts timing;
Described first sending module, for when timing reaches described first preset duration, reports to described server by the nonurgent type data preserved in described first preset duration.
Additionally, for achieving the above object, the present invention also proposes a kind of data reporting device, and described data reporting device includes:
Acquisition module, the data being in operation for the application that acquisition software development kit is corresponding, wherein, described data include nonurgent type data and general type data;
3rd sending module, for when the described data gathered are nonurgent type data, call default urgent interface and the transmission of described nonurgent type data is reported application to data, report application to preserve described nonurgent type data for described data, and at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server;
4th sending module, for when the described data gathered are general type data, call default generic interface and the transmission of described general type data is reported application to described data, report application to preserve described general type data for described data, and at interval of the second preset duration, the general type data preserved in described second preset duration are reported to described server;
Wherein, described first preset duration is less than described second preset duration.
Alternatively, described 3rd sending module includes:
Encapsulation unit, for when the described data gathered are nonurgent type data, encapsulating urgent identification information in described nonurgent type data;
Transmitting element, reports application by the described nonurgent type data transmission being packaged with described urgent identification information to data for calling default urgent interface.
Additionally, for achieving the above object, the present invention also proposes a kind of data reporting method, and described data reporting method comprises the following steps:
When receiving the data that SDK sends every time, preserving described data, wherein, described data are that the application that described SDK is corresponding is when being in operation, the data that described SDK gathers, described data include nonurgent type data and general type data;
At interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server;
At interval of the second preset duration, the general type data preserved in described second preset duration are reported to described server;
Wherein, described first preset duration is less than described second preset duration.
Alternatively, before the described step that at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server, also include:
At interval of the first preset duration, the data being packaged with urgent identification information preserved in obtaining described first preset duration, wherein, described SDK, when according to the data form encapsulation of data preset, encapsulates urgent identification information in nonurgent type data;
Using be packaged with described urgent identification information data as nonurgent type data.
Alternatively, described when receiving the data that SDK sends every time, after preserving the step of described data, also include:
Judge whether the described data being currently received are nonurgent type data;
When the described data being currently received are nonurgent type data, it is determined whether have started to timing;
If not starting timing, then start timing;
When timing reaches described first preset duration, the nonurgent type data preserved in described first preset duration is reported to described server.
Additionally, for achieving the above object, the present invention also proposes a kind of data reporting method, and described data reporting method comprises the following steps:
SDK gathers the data that application corresponding to described SDK is in operation, and wherein, described data include nonurgent type data and general type data;
When the described data gathered are nonurgent type data, call default urgent interface and the transmission of described nonurgent type data is reported application to data, report application to preserve described nonurgent type data for described data, and at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server;
When the described data gathered are general type data, call default generic interface and the transmission of described general type data is reported application to described data, report application to preserve described general type data for described data, and at interval of the second preset duration, the general type data preserved in described second preset duration are reported to described server;
Wherein, described first preset duration is less than described second preset duration.
Alternatively, described when the described data gathered are nonurgent type data, call default urgent interface and report the step of application to include to data the transmission of described nonurgent type data:
When the described data gathered are nonurgent type data, described nonurgent type data encapsulates urgent identification information;
Call default urgent interface and the described nonurgent type data transmission being packaged with described urgent identification information is reported application to data.
The data reporting device of present invention proposition and method, when receiving the data that SDK sends every time, no matter these data are nonurgent type data or general type data, memory module first preserves these data, then for the nonurgent type data preserved, first sending module, with the time interval of first preset duration of short period, is reported to server, it is achieved thereby that nonurgent type data can report to server in time;And for the general type data preserved, second sending module is with the time interval of second preset duration of long period, reported to server, thus decrease and be connected number of times with server and number of times that data report, reduce power consumption, therefore, while present invention achieves low-power consumption, report nonurgent type data in time.
Accompanying drawing explanation
Fig. 1 is the hardware architecture diagram realizing each one optional mobile terminal of embodiment of the present invention;
Fig. 2 is the wireless communication system schematic diagram of mobile terminal as shown in Figure 1;
Fig. 3 is the module diagram of data reporting device first embodiment of the present invention;
Fig. 4 is an optional schematic diagram of data reporting system in the present invention;
Fig. 5 is the module diagram of data reporting device the second embodiment of the present invention;
Fig. 6 is the module diagram of data reporting device the 3rd embodiment of the present invention;
Fig. 7 is the module diagram of data reporting device the 4th embodiment of the present invention;
Fig. 8 is the schematic flow sheet of data reporting method first embodiment of the present invention;
Fig. 9 is the schematic flow sheet of data reporting method the second embodiment of the present invention;
Figure 10 is the schematic flow sheet of data reporting method the 3rd embodiment of the present invention;
Figure 11 is the schematic flow sheet of data reporting method the 4th embodiment of the present invention.
The realization of the object of the invention, functional characteristics and advantage will in conjunction with the embodiments, are described further referring to the drawings.
Detailed description of the invention
Should be appreciated that specific embodiment described herein, only in order to explain the present invention, is not intended to limit the present invention.
The mobile terminal realizing each embodiment of the present invention is described referring now to accompanying drawing.In follow-up description, use the suffix being used for representing such as " module ", " parts " or " unit " of element only for the explanation of the beneficially present invention, itself do not have intrinsic meaning.Therefore, " module " can mixedly use with " parts ".
Mobile terminal can be implemented in a variety of manners.Such as, the terminal described in the present invention can include mobile terminal and the fixed terminal of such as numeral TV, desk computer etc. of such as mobile phone, smart phone, notebook computer, digit broadcasting receiver, PDA (personal digital assistant), PAD (panel computer), PMP (portable media player), guider etc..Hereinafter it is assumed that terminal is mobile terminal.However, it will be understood by those skilled in the art that, in addition to being used in particular for the element of mobile purpose, structure according to the embodiment of the present invention can also apply to the terminal of fixed type.
Fig. 1 is the hardware configuration signal of the optional mobile terminal realizing each embodiment of the present invention.
Mobile terminal 100 can include wireless communication unit 110, A/V (audio/video) input block 120, output unit 150, memorizer 160, interface unit 170, controller 180 and power subsystem 190 etc..Fig. 1 shows the mobile terminal with various assembly, it should be understood that be not required for implementing all assemblies illustrated.Can alternatively implement more or less of assembly.Will be discussed in more detail below the element of mobile terminal.
Wireless communication unit 110 generally includes one or more assembly, and it allows the radio communication between mobile terminal 100 and wireless communication system or network.Such as, at least one during wireless communication unit can include mobile communication module 112, wireless Internet module 113, short range communication module 114.
Mobile communication module 112 sends radio signals at least one in base station (such as, access point, node B etc.), exterior terminal and server and/or receives from it radio signal.Such radio signal can include voice call signal, video calling signal or the various types of data sending according to text and/or Multimedia Message and/or receiving.
Wireless Internet module 113 supports the Wi-Fi (Wireless Internet Access) of mobile terminal.This module can internally or externally be couple to terminal.Wi-Fi (Wireless Internet Access) technology involved by this module can include WLAN (WLAN) (Wi-Fi), Wibro (WiMAX), Wimax (worldwide interoperability for microwave access), HSDPA (high-speed downlink packet access) etc..
Short range communication module 114 is the module for supporting junction service.Some examples of short-range communication technology include bluetoothTM, RF identification (RFID), Infrared Data Association (IrDA), ultra broadband (UWB), purple honeybeeTMEtc..
A/V input block 120 is used for receiving audio or video signal.A/V input block 120 can include camera 121 and mike 122, and the view data of the camera 121 static images to being obtained by image capture apparatus in Video Capture pattern or image capture mode or video processes.Picture frame after process may be displayed on display unit 151.Picture frame after camera 121 processes can be stored in memorizer 160 (or other storage medium) or be transmitted via wireless communication unit 110, can provide two or more cameras 121 according to the structure of mobile terminal.Mike 122 can receive sound (voice data) via mike in telephone calling model, logging mode, speech recognition mode etc. operational mode, and can be voice data by such acoustic processing.Audio frequency (voice) data after process can be converted to can be sent to via mobile communication module 112 the form output of mobile communication base station in the case of telephone calling model.Mike 122 can be implemented various types of noise and eliminate noise or the interference that (or suppression) algorithm produces with elimination (or suppression) during receiving and send audio signal.
Interface unit 170 is used as at least one external device (ED) and is connected, with mobile terminal 100, the interface that can pass through.Such as, external device (ED) can include wired or wireless head-band earphone port, external power source (or battery charger) port, wired or wireless FPDP, memory card port, have the port of device of identification module, audio frequency input/output (I/O) port, video i/o port, ear port etc. for connecting.Identification module can be that storage is for verifying that user uses the various information of mobile terminal 100 and can include subscriber identification module (UIM), client identification module (SIM), Universal Subscriber identification module (USIM) etc..It addition, the device (hereinafter referred to as " identifying device ") with identification module can be to take the form of smart card, therefore, identify that device can be connected with mobile terminal 100 via port or other attachment means.Interface unit 170 may be used for receiving from the input (such as, data message, electric power etc.) of external device (ED) and the one or more elements input received being transferred in mobile terminal 100 or may be used for transmitting data between mobile terminal and external device (ED).
Additionally, when mobile terminal 100 is connected with external base, interface unit 170 can serve as allowing to provide the path of mobile terminal 100 or can serve as to allow from the various command signals of base input from base electric power by it and is transferred to the path of mobile terminal by it.May serve as identifying whether mobile terminal is accurately fitted within the signal base from various command signals or the electric power of base input.Output unit 150 is configured to provide output signal (such as, audio signal, video signal, alarm signal, vibration signal etc.) with vision, audio frequency and/or tactile manner.
Output unit 150 can include display unit 151, dio Output Modules 152 etc..
Display unit 151 may be displayed on the information processed in mobile terminal 100.Such as, when mobile terminal 100 is in telephone calling model, display unit 151 can show the user interface (UI) relevant with call or other communicate (such as, text messaging, multimedia file download etc.) or graphic user interface (GUI).When mobile terminal 100 is in video calling pattern or image capture mode, display unit 151 can show image and/or the image of reception, UI or GUI illustrating video or image and correlation function etc. of capture.
Meanwhile, when display unit 151 and touch pad the most superposed on one another with formed touch screen time, display unit 151 can serve as input equipment and output device.Display unit 151 can include at least one in liquid crystal display (LCD), thin film transistor (TFT) LCD (TFT-LCD), Organic Light Emitting Diode (OLED) display, flexible display, three-dimensional (3D) display etc..Some in these display may be constructed such that transparence to allow user to watch from outside, this is properly termed as transparent display, and typical transparent display can for example, TOLED (transparent organic light emitting diode) display etc..According to the specific embodiment wanted, mobile terminal 100 can include two or more display units (or other display device), such as, mobile terminal can include outernal display unit (not shown) and inner display unit (not shown).Touch screen can be used for detecting touch input pressure and touch input position and touch input area.
Dio Output Modules 152 can mobile terminal be in call signal receive under the isotype such as pattern, call mode, logging mode, speech recognition mode, broadcast reception mode time, that wireless communication unit 110 is received or storage in memorizer 160 voice data transducing audio signal and be output as sound.And, dio Output Modules 152 can provide the audio frequency output (such as, call signal receive sound, message sink sound etc.) relevant to the specific function of mobile terminal 100 execution.Dio Output Modules 152 can include speaker, buzzer etc..
Memorizer 160 can store the process performed by controller 180 and the software program controlling operation etc., or can temporarily store the data (such as, telephone directory, message, still image, video etc.) that oneself maybe will export through output.And, memorizer 160 can be to store vibration and the data of audio signal of the various modes about exporting when touching and being applied to touch screen.
Memorizer 160 can include the storage medium of at least one type, described storage medium includes flash memory, hard disk, multimedia card, card-type memorizer (such as, SD or DX memorizer etc.), random access storage device (RAM), static random-access memory (SRAM), read only memory (ROM), Electrically Erasable Read Only Memory (EEPROM), programmable read only memory (PROM), magnetic storage, disk, CD etc..And, mobile terminal 100 can be connected the network storage device of the storage function performing memorizer 160 and cooperate with by network.
Controller 180 generally controls the overall operation of mobile terminal.Such as, controller 180 performs the control relevant to voice call, data communication, video calling etc. and process.Controller 180 can perform pattern recognition process, so that the handwriting input performed on the touchscreen or picture drafting input are identified as character or image.
Power subsystem 190 receives external power or internal power under the control of controller 180 and provides the suitable electric power operated needed for each element and assembly.
Various embodiment described herein can be implemented to use such as computer software, hardware or its any combination of computer-readable medium.Hardware is implemented, embodiment described herein can be by using application-specific IC (ASIC), digital signal processor (DSP), digital signal processing device (DSPD), programmable logic device (PLD), field programmable gate array (FPGA), processor, controller, microcontroller, microprocessor, being designed to perform at least one in the electronic unit of function described herein and implement, in some cases, such embodiment can be implemented in controller 180.Implementing for software, the embodiment of such as process or function can be implemented with allowing the single software module performing at least one function or operation.Software code can be implemented by the software application (or program) write with any suitable programming language, and software code can be stored in memorizer 160 and be performed by controller 180.
So far, oneself is through describing mobile terminal according to its function.Below, for the sake of brevity, the slide type mobile terminal in the various types of mobile terminals that will describe such as folded form, board-type, oscillating-type, slide type mobile terminal etc. is as example.Therefore, the present invention can be applied to any kind of mobile terminal, and is not limited to slide type mobile terminal.
Mobile terminal 100 may be constructed such that utilization operates via frame or the most wired and wireless communication system of packet transmission data and satellite-based communication system as shown in Figure 1.
The communication system being wherein operable to according to the mobile terminal of the present invention is described referring now to Fig. 2.
Such communication system can use different air interfaces and/or physical layer.Such as, the air interface used by communication system includes such as frequency division multiple access (FDMA), time division multiple acess (TDMA), CDMA (CDMA) and UMTS (UMTS) (especially, Long Term Evolution (LTE)), global system for mobile communications (GSM) etc..As non-limiting example, explained below relates to cdma communication system, but such teaching is equally applicable to other type of system.
With reference to Fig. 2, cdma wireless communication system can include that multiple mobile terminal 100, multiple base station (BS) 270, base station controller (BSC) 275 and mobile switching centre (MSC) 2800MSC280 are configured to and Public Switched Telephony Network (PSTN) 290 formation interface.MSC280 is also structured to and the BSC275 formation interface that can be couple to base station 270 via back haul link.If back haul link can construct according to any one in the interface that Ganji knows, described interface includes such as E1/T1, ATM, IP, PPP, frame relay, HDSL, ADSL or xDSL.It will be appreciated that system as shown in Figure 2 can include multiple BSC2750.
Each BS270 can service one or more subregion (or region), by each subregion of multidirectional antenna or the antenna covering pointing to specific direction radially away from BS270.Or, each subregion can be covered by two or more antennas for diversity reception.Each BS270 may be constructed such that support multiple frequencies distribution, and the distribution of each frequency has specific frequency spectrum (such as, 1.25MHz, 5MHz etc.).
Intersecting that subregion and frequency are distributed can be referred to as CDMA Channel.BS270 can also be referred to as base station transceiver subsystem (BTS) or other equivalent terms.In this case, term " base station " may be used for broadly representing single BSC275 and at least one BS270.Base station can also be referred to as " cellular station ".Or, each subregion of specific BS270 can be referred to as multiple cellular station.
In fig. 2 it is shown that several global positioning systems (GPS) satellite 300.Satellite 300 helps to position at least one in multiple mobile terminals 100.
In fig. 2, depict multiple satellite 300, it is understood that be, it is possible to use any number of satellite obtains useful location information.Substitute GPS tracking technique or outside GPS tracking technique, it is possible to use other technology of the position of mobile terminal can be followed the tracks of.It addition, at least one gps satellite 300 can optionally or additionally process satellite dmb transmission.
As a typical operation of wireless communication system, BS270 receives the reverse link signal from various mobile terminals 100.Mobile terminal 100 generally participates in call, information receiving and transmitting communicates with other type of.Each reverse link signal that certain base station 270 receives is processed in specific BS270.The data obtained are forwarded to the BSC275 being correlated with.BSC provides call resource distribution and the mobile management function of the coordination of soft switching process included between BS270.The data received also are routed to MSC280 by BSC275, and it provides the extra route service for forming interface with PSTN290.Similarly, PSTN290 Yu MSC280 forms interface, MSC Yu BSC275 forms interface, and BSC275 correspondingly controls BS270 so that forward link signals to be sent to mobile terminal 100.
Based on above-mentioned mobile terminal hardware configuration and communication system, each embodiment of data reporting device of the present invention is proposed.
As it is shown on figure 3, in the first embodiment, this data reporting device includes:
Memory module 1, for when receiving the data that SDK SDK sends every time, preserving described data, wherein, when the application that described data are corresponding for described SDK is in operation, the data that described SDK gathers, described data include nonurgent type data and general type data;
In the present embodiment, this data reporting device is arranged in mobile terminal, and each application loaded in mobile terminal is integrated with Software of Data Statistics development kit SDK (Software Development Kit, SDK), SDK is integrated in each application, for adding up the startup information of each application, page info, event click information, CRASH information etc..Further, mobile terminal is also loaded with data and reports application.Alternatively, these data report application to be installed in mobile terminal ROM.When during each application to be run by mobile terminal, corresponding data report to server, as shown in Figure 4, each application is corresponding SDK, data report application and server composition data reporting system.Time in each application runs, the SDK acquisition applications of its correspondence is in operation the data of correspondence, and sends the data collected to data and report application.Alternatively, whether SDK, when collecting data, is urgent event according to corresponding event, data is defined as nonurgent type data or general type data.Such as, when event is urgent event, the data of event are defined as nonurgent type data by SDK;Otherwise, the data of event are defined as general type data by SDK.Then, the nonurgent type data determined or the transmission of general type data are reported application to data by SDK.
When receiving the data that SDK sends, the data received are preserved by memory module 1.Wherein, the data received may be for nonurgent type data, it is also possible to for general type data, namely the data that memory module 1 preserves include nonurgent type data and general type data.
First sending module 2, for reporting to server at interval of the first preset duration by the nonurgent type data preserved in described first preset duration;
In the present embodiment, it is previously provided with the first preset duration T1, this first preset duration T1Concrete numerical value can arrange flexibly according to the urgent situation of event, this is not restricted.Such as, when the developer that certain a application is corresponding needs to do activity in certain red-letter day, developer wants to the effect of grasp activity as early as possible, active policy is dynamically adjusted according to user's service condition, namely developer wishes to obtain as early as possible each user when running data corresponding to this application, can be by this first preset duration T1It is set to 10 minutes.First sending module 2 is at interval of the first preset duration T1, just from the first preset duration T1The data of interior preservation inquire nonurgent type data, namely just in current 10 minutes, the data of preservation inquired nonurgent type data at interval of 10 minutes, and the nonurgent type data inquired is reported to server, it is achieved thereby that report nonurgent type data the most in time.
And, due to in each communication of server, while each reported data to server, it is necessary to carry public information of mobile terminal, including the IMEI number of mobile terminal, MAC Address, mobile terminal production firm, operating system, operating system version, mobile terminal model etc..Therefore, in prior art use when SDK receives data every time, just reported to the mode of server, reported a lot of redundant datas.And in the present embodiment, owing to the first sending module 2 is to report a nonurgent type data at interval of the first preset duration, while realizing reporting nonurgent type data in time, also reduce uploading of redundant data, therefore can save the flow of consuming.Simultaneously as just need not be connected with server when receiving nonurgent type data every time, greatly reduce the number of times being connected with server, thus also reached to save the effect of electricity.
Second sending module 3, for reporting to described server at interval of the second preset duration by the general type data preserved in described second preset duration;Wherein, described first preset duration is less than described second preset duration.
Owing to general type data need not quickly report to server, the first sending module 2 is at interval of the first preset duration T1, only nonurgent type data is sent to server, and the general type data preserved is not sent to server.In order to general type data are reported to server, in the present embodiment, except the first above-mentioned preset duration T1, also it is previously provided with the second preset duration T2, the second sending module 3 is at interval of the second preset duration T2The general type data preserved in second preset duration are reported to server.Wherein, this second preset duration T2More than the first preset duration T1, the second preset duration T2Concrete numerical value can arrange flexibly according to practical situation, this is not restricted, such as, arranges the second preset duration T2Concrete numerical value be 24 hours, the general type data preserved in current 24 hours were reported to server at interval of 24 hours by the second sending module 3.
Server is when receiving nonurgent type data that the first sending module 2 reports or the general type data that the second sending module 3 reports, preserve the nonurgent type data or general type data received, and determine nonurgent type data or application corresponding to general type data, then all nonurgent type data corresponding to this application or general type data to preserving are analyzed, know the details that this application runs, thus carry out the associative operations such as next version exploitation of this application further according to the details obtained.
The scheme that the present embodiment proposes, when receiving the data that SDK sends every time, no matter these data are nonurgent type data or general type data, memory module 1 first preserves these data, then for the nonurgent type data preserved, first sending module 2 is with the frequency of first preset duration of short period, reported to server, and for the general type data preserved, second sending module 3 is with the frequency of second preset duration of long period, reported to server, also server will quickly be reported to by nonurgent type data, general type data set reports to server, thus not only achieve nonurgent type data and can report to server in time, also reduce the number of times of mobile terminal Connection Service device, reduce power consumption.
As it is shown in figure 5, propose data reporting device the second embodiment of the present invention.Data reporting device the second embodiment is with the difference of data reporting device first embodiment, and in data reporting device the second embodiment, described data reporting device also includes:
Acquisition module 4, for at interval of the first preset duration, obtain the interior data being packaged with urgent identification information preserved of described first preset duration, wherein, described SDK, when according to the data form encapsulation of data preset, encapsulates urgent identification information in nonurgent type data;
Determining module 5, the data being used for be packaged with described urgent identification information are as nonurgent type data.In the present embodiment, in order to reduce the coupling of data, nonurgent type data and general type data that SDK is sent by memory module 1 are saved together.Therefore, in order to distinguish nonurgent type data and general type data from the data preserved, thus nonurgent type data and general type data are reported to server respectively, in the present embodiment, the data form of pre-defined SDK encapsulation of data, when SDK collects new data, it is not necessary to upgrade database, distinguish nonurgent type data and general type data by urgent identification information.SDK, when according to predefined data form encapsulation of data, will encapsulate urgent identification information, and do not encapsulates urgent identification information in general type data in nonurgent type data.Such as, the data form of definition nonurgent type data is as shown in table 1:
Table 1
Call time in data Application bag name Version information Extension information Urgent identification information
uploadTime packageName version extra urgent
It will be understood by those skilled in the art that, data form is not necessarily the above-mentioned form enumerated, and can be any type, as long as data type and the parameter of data and value can be distinguished, such as json form also can meet demand, or following general data form:
(param1=value1)(param2 =value2)......(paramn-1=valuen-1)(paramn=valuen);
Wherein, param represents the parameter of certain categorical data, and as clicked on the id of event, duration, number of times etc., the value of value representation parameter param, such as download event, 30 seconds, 4 clicks etc..
Further, in the present embodiment, SDK provides urgent interface, and to data, nonurgent type data transmission is reported application.In order to avoid interface fragmentation, and owing to the urgent interface of event has been able to meet business demand, therefore, in the present embodiment, provide only the urgent interface of event, do not provide the urgent interface such as the page, session, Crash, thus avoid data to report application to lose control.
At interval of the first preset duration T1, first acquisition module 4 resolves in current first preset duration T1Whether each data of interior preservation are packaged with urgent identification information, obtain the first preset duration T1Interior preservation is packaged with the data of urgent identification information, determines that data being packaged with urgent identification information that acquisition module 4 gets by module 5, as nonurgent type data, and have urgent ID information data for unencapsulated, determines that module 5 is defined as general type data.Then current first preset duration T that the first sending module 2 will determine that module 5 determines1The nonurgent type data of interior preservation all reports to server.
Alternatively, in the present embodiment, described data reporting device also includes:
Removing module, after the nonurgent type data for preserving in by described first preset duration reports to server, the nonurgent type data preserved in deleting described first preset duration;And after in by described second preset duration, the general type data of preservation report to described server, the general type data preserved in deleting described second preset duration.
When the first sending module 2 is by current first preset duration T1After the nonurgent type data of interior preservation all reports to server, removing module deletes current first preset duration T1The nonurgent type data of interior preservation, namely from the data preserved, delete the nonurgent type data currently reporting to server.Afterwards, in next first preset duration T1In, when receiving the nonurgent type data that SDK sends, memory module 1 preserves, so that it is guaranteed that the nonurgent type data preserved is all first preset duration T1The nonurgent type data inside received, thus add data and report the free memory of application.
Similarly, when the second sending module 3 is by current second preset duration T2After the general type data of interior preservation all report to server, removing module deletes current second preset duration T2The general type data of interior preservation, namely from the data preserved, delete the general type data currently reporting to server.Afterwards, in next second preset duration T2In, when receiving the general type data that SDK sends, memory module 1 preserves, so that it is guaranteed that the general type data preserved are all second preset duration T2The general type data inside received, thus further increase data and report the free memory of application, it is ensured that data report the memory space abundance of application.
The scheme that the present embodiment proposes, when the first sending module 2 is by current first preset duration T1After the nonurgent type data of interior preservation all reports to server, removing module deletes current first preset duration T1The nonurgent type data of interior preservation, and, when the second sending module 3 is by current second preset duration T2After the general type data of interior preservation all report to server, removing module deletes current second preset duration T2The general type data of interior preservation, thus ensure that all nonurgent type data preserved at any time are current first preset duration T1The nonurgent type data inside received, the nonurgent type data before preserved all deletes, and all general type data of preservation are current second preset duration T2The general type data inside received, the general type data before preserved all delete, thus add data and report the free memory of application.
As shown in Figure 6, data reporting device the 3rd embodiment of the present invention is proposed.Data reporting device the 3rd embodiment is with the difference of data reporting device the second embodiment, and in data reporting device the 3rd embodiment, described data reporting device also includes:
Whether the first judge module 6, be nonurgent type data for judging the described data being currently received;
Second judge module 7, for when the described data being currently received are nonurgent type data, it is determined whether have started to timing;
Timing module 8, for when not starting timing, starts timing;
Described first sending module 2, for when timing reaches described first preset duration, reports to described server by the nonurgent type data preserved in described first preset duration.
In the present embodiment, memory module 1 is receiving data that SDK sends and after preserving, and the first judge module 6 judges whether the data being currently received are nonurgent type data.When the first judge module 6 judges the data being currently received not as nonurgent type data, do not carry out response process.When continuing to the data that SDK sends, memory module 1 preserves, and the first judge module 6 judges whether the data being currently received are nonurgent type data.Until when the first judge module 6 judges that the data being currently received are nonurgent type data, now, the second judge module 7 judges whether to have begun to timing.If the second judge module 7 judges now not have started timing, timing module 8 starts timing.The first preset duration T also it is not up in timing1During, when receiving the data that SDK sends every time, no matter the data received are nonurgent type data, or general type data, memory module 1 all preserves.Afterwards, the first preset duration T is reached when timing1Time, the first sending module 2 is from this first preset duration T1The data of interior preservation inquire nonurgent type data, the nonurgent type data inquired is reported to server.Meanwhile, timing is updated to initial time by timing module 8, alternatively, timing is reset.Further, removing module deletes this first preset duration T1The nonurgent type data of interior preservation, namely delete the nonurgent type data currently reporting to server.
In the present embodiment, when timing is updated to initial time, there is not nonurgent type data in the data that memory module 1 preserves.Afterwards, when memory module 1 preserves the data that the SDK received sends again, the first judge module 6 judges whether these data receiving and preserving are nonurgent type data, and when these data are general type data, timing module 8 does not carry out timing.Memory module 1 continues to and preserves the data that SDK sends, until the first judge module 6 judges when the data currently receiving and preserving are nonurgent type data, now, if the second judge module 7 judges not have started timing, then timing module 8 restarts timing.When timing reaches the first preset duration T1Time, the first sending module 2 continues executing with above-mentioned by the first preset duration T1The nonurgent type data of interior preservation reports to the operation of server, just repeats no more at this.
The scheme that the present embodiment proposes, after the nonurgent type data of preservation being reported to server due to each first sending module 2, the nonurgent type data preserved all is deleted by removing module, when memory module 1 preserves the data that the SDK received sends again afterwards, if these data are general type data, then timing module 8 does not carry out timing, until when certain data receiving and preserving are nonurgent type data, timing module 8 just starts timing, when timing reaches the first preset duration, first sending module 2 performs to report to the nonurgent type data preserved in time period the operation of server again.Therefore, the present embodiment need not report nonurgent type data to server according to the frequency of the first preset duration mechanically, add the motility that nonurgent type data reports.
As it is shown in fig. 7, propose data reporting device the 4th embodiment of the present invention.Data reporting device the 4th embodiment is with the difference of any of the above-described embodiment, and described data reporting device includes:
Acquisition module 9, the data being in operation for the application that acquisition software development kit is corresponding, wherein, described data include nonurgent type data and general type data;
3rd sending module 10, for when the described data gathered are nonurgent type data, call default urgent interface and the transmission of described nonurgent type data is reported application to data, report application to preserve described nonurgent type data for described data, and at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server;
4th sending module 11, for when the described data gathered are general type data, call default generic interface and the transmission of described general type data is reported application to described data, report application to preserve described general type data for described data, and at interval of the second preset duration, the general type data preserved in described second preset duration are reported to described server;
Wherein, described first preset duration is less than described second preset duration.
In the present embodiment, each application loaded in mobile terminal is integrated with Software of Data Statistics development kit (Software Development Kit, SDK), SDK is integrated in each application, for adding up the startup information of each application, page info, event click information, CRASH information etc..Data reporting device is arranged in each SDK.Further, mobile terminal is also loaded with data and reports application.When during each application to be run by mobile terminal, corresponding data report to server, as shown in Figure 4, each application is corresponding SDK, data report application and server composition data reporting system.Each application run in time, acquisition module 9 acquisition applications be in operation correspondence data, these data include nonurgent type data and general type data.
Being nonurgent type data or the judgement of general type data for data, SDK can be judged by various flexi modes.Such as, for various different application, some application can be set to the urgent application reported of data previously according to user's requirement, and other application is set to data and need not the urgent application reported.Then when acquisition module 9 gather be data urgent report application run data time, it is judged that these data of collection are nonurgent type data;When acquisition module 9 gather be data need not urgent report application run data time, it is judged that these data of collection are general type data.Or, for a certain application, in running due to application, include various data, can pre-set certain form of data therein is nonurgent type data, and other kinds of data are general type data.Such as, data corresponding to the event that will click on are set to nonurgent type data, then when acquisition module 9 collects data corresponding to click event, it is judged that these data collected are nonurgent type data.
For nonurgent type data and general type data, the 3rd sending module 10 and the 4th sending module 11 are respectively adopted different modes and send to data and report application.Specifically, in the present embodiment, being previously provided with urgent interface corresponding to SDK and generic interface, the nonurgent type data collected transmission is reported application to data for SDK by urgent interface, and generic interface is for reporting application by the transmission of general type data to data.When acquisition module 9 is when collecting nonurgent type data every time, the 3rd sending module 10 calls default urgent interface and to data, the nonurgent type data collected transmission is reported application.Data report to be applied after receiving nonurgent type data, and nonurgent type data is stored in a memory block.When acquisition module 9 is when collecting general type data every time, the 4th sending module 11 calls default generic interface and to data, the general type data collected transmission is reported application.Data report to be applied after receiving general type data, and general type data are stored in another memory block.
In order to avoid interface fragmentation, and owing to the urgent interface of event has been able to meet business demand, therefore, in the present embodiment, provide only the urgent interface of event, do not provide the urgent interface such as the page, session, Crash, thus avoid data to report application to lose control.
In the present embodiment, described 3rd sending module 10 includes:
Encapsulation unit, for when the described data gathered are nonurgent type data, encapsulating urgent identification information in described nonurgent type data;
Transmitting element, reports application by the described nonurgent type data transmission being packaged with described urgent identification information to data for calling default urgent interface.
In order to reduce the coupling of data, make data report application nonurgent type data and general type data to be saved together, namely data report application can distinguish nonurgent type data and general type data from all data being saved together.In the present embodiment, acquisition module 9 is when collecting nonurgent type data, and encapsulation unit, when according to predefined data form encapsulation of data, will encapsulate urgent identification information, and do not encapsulates urgent identification information in general type data in nonurgent type data.Such as, the data form of definition nonurgent type data is as shown in table 1.
It will be understood by those skilled in the art that, data form is not necessarily the above-mentioned form enumerated, and can be any type, as long as data type and the parameter of data and value can be distinguished, such as json form also can meet demand, or following general data form:
(param1=value1)(param2=value2)......(paramn-1=valuen-1)(paramn=valuen);
Wherein, param represents the parameter of certain categorical data, and as clicked on the id of event, duration, number of times etc., the value of value representation parameter param, such as download event, 30 seconds, 4 clicks etc..
Afterwards, transmitting element calls default urgent interface and to data, the described nonurgent type data transmission being packaged with described urgent identification information is reported application.
Data report application at interval of the first preset duration T1, by the first preset duration T1The nonurgent type data of interior preservation reports to server.At interval of the second preset duration T2The general type data preserved in second preset duration are reported to server.Wherein, this second preset duration T2More than the first preset duration T1
Server is when receiving nonurgent type data or the general type data that data report application to report, preserve the nonurgent type data or general type data received, and determine nonurgent type data or application corresponding to general type data, then all nonurgent type data corresponding to this application or general type data to preserving are analyzed, know the details that this application runs, thus carry out the associative operations such as next version exploitation of this application further according to the details obtained.
nullThe scheme that the present embodiment proposes,Acquisition module 9 is when collecting the data that corresponding application runs every time,If these data are nonurgent type data,Then the 3rd sending module 10 calls default urgent interface and to data, nonurgent type data transmission is reported application,Data report application to preserve nonurgent type data,If these data are general type data,Then the 4th sending module 11 calls default generic interface and to data, the transmission of general type data is reported application,Data report application to preserve general type data,Then for the nonurgent type data preserved,Frequency with first preset duration of short period,Reported to server,And for the general type data preserved,Frequency with second preset duration of long period,Reported to server,Also server will quickly be reported to by nonurgent type data、General type data set reports to server,Thus not only achieve nonurgent type data and can report to server in time,Also reduce the number of times of mobile terminal Connection Service device,Reduce power consumption.
The embodiment of the present invention also provides for a kind of data reporting method.
With reference to the schematic flow sheet that Fig. 8, Fig. 8 are data reporting method first embodiment of the present invention, in the first embodiment, this data reporting method comprises the following steps:
Step S10, when receiving the data that SDK sends every time, preserve described data, wherein, described data are that the application that described SDK is corresponding is when being in operation, the data that described SDK gathers, described data include nonurgent type data and general type data;
In the present embodiment, each application loaded in mobile terminal is integrated with Software of Data Statistics development kit (Software Development Kit, SDK), SDK is integrated in each application, for adding up the startup information of each application, page info, event click information, CRASH information etc..Further, mobile terminal is also loaded with data and reports application.Alternatively, these data report application to be installed in mobile terminal ROM.When during each application to be run by mobile terminal, corresponding data report to server, as shown in Figure 4, each application is corresponding SDK, data report application and server composition data reporting system.Time in each application runs, the SDK acquisition applications of its correspondence is in operation the data of correspondence, and sends the data collected to data and report application.Alternatively, whether SDK, when collecting data, is urgent event according to corresponding event, data is defined as nonurgent type data or general type data.Such as, when event is urgent event, the data of event are defined as nonurgent type data by SDK;Otherwise, the data of event are defined as general type data by SDK.Then, the nonurgent type data determined or the transmission of general type data are reported application to data by SDK.
When data report application to receive the data that SDK sends, the data received are preserved.Wherein, the data received may be for nonurgent type data, it is also possible to for general type data, namely data report the data preserved in application to include nonurgent type data and general type data.
Step S20, reports to server at interval of the first preset duration by the nonurgent type data preserved in described first preset duration;
In the present embodiment, it is previously provided with the first preset duration T1, this first preset duration T1Concrete numerical value can arrange flexibly according to the urgent situation of event, this is not restricted.Such as, when the developer that certain a application is corresponding needs to do activity in certain red-letter day, developer wants to the effect of grasp activity as early as possible, active policy is dynamically adjusted according to user's service condition, namely developer wishes to obtain as early as possible each user when running data corresponding to this application, can be by this first preset duration T1It is set to 10 minutes.Data report application at interval of the first preset duration T1, just from the first preset duration T1The data of interior preservation inquire nonurgent type data, namely just in current 10 minutes, the data of preservation inquired nonurgent type data at interval of 10 minutes, and the nonurgent type data inquired is reported to server, it is achieved thereby that report nonurgent type data the most in time.
And, due to in each communication of server, while each reported data to server, it is necessary to carry public information of mobile terminal, including the IMEI number of mobile terminal, MAC Address, mobile terminal production firm, operating system, operating system version, mobile terminal model etc..Therefore, in prior art use when SDK receives data every time, just reported to the mode of server, reported a lot of redundant datas.And in the present embodiment, owing to being to report a nonurgent type data at interval of the first preset duration, while realizing reporting nonurgent type data in time, also reduce uploading of redundant data, therefore can save the flow of consuming.Simultaneously as just need not be connected with server when receiving nonurgent type data every time, greatly reduce the number of times being connected with server, thus also reached to save the effect of electricity.
The general type data preserved in described second preset duration are reported to described server at interval of the second preset duration by step S30;Wherein, described first preset duration is less than described second preset duration.
Owing to general type data need not quickly report to server, data report application at interval of the first preset duration T1, only nonurgent type data is sent to server, and the general type data preserved is not sent to server.In order to general type data are reported to server, in the present embodiment, except the first above-mentioned preset duration T1, also it is previously provided with the second preset duration T2, data report application at interval of the second preset duration T2The general type data preserved in second preset duration are reported to server.Wherein, this second preset duration T2More than the first preset duration T1, the second preset duration T2Concrete numerical value can arrange flexibly according to practical situation, this is not restricted, such as, arranges the second preset duration T2Concrete numerical value be 24 hours, data report to apply, at interval of 24 hours, the general type data preserved in current 24 hours are reported to server.
Server is when receiving nonurgent type data or the general type data that data report application to report, preserve the nonurgent type data or general type data received, and determine nonurgent type data or application corresponding to general type data, then all nonurgent type data corresponding to this application or general type data to preserving are analyzed, know the details that this application runs, thus carry out the associative operations such as next version exploitation of this application further according to the details obtained.
The scheme that the present embodiment proposes, when receiving the data that SDK sends every time, no matter these data are nonurgent type data or general type data, data report application first to preserve these data, then for the nonurgent type data preserved, frequency with first preset duration of short period, reported to server, and for the general type data preserved, frequency with second preset duration of long period, reported to server, also server will quickly be reported to by nonurgent type data, general type data set reports to server, thus not only achieve nonurgent type data and can report to server in time, also reduce the number of times of mobile terminal Connection Service device, reduce power consumption.
As it is shown in figure 9, propose data reporting method the second embodiment of the present invention.Data reporting method the second embodiment is with the difference of data reporting method first embodiment, in data reporting method the second embodiment, before described step S20, also includes:
Step S40, at interval of the first preset duration, obtain the interior data being packaged with urgent identification information preserved of described first preset duration, wherein, described SDK, when according to the data form encapsulation of data preset, encapsulates urgent identification information in nonurgent type data;
Step S50, using be packaged with described urgent identification information data as nonurgent type data.
In the present embodiment, in order to reduce the coupling of data, data report applies the nonurgent type data sent by SDK and general type data to be saved together.Therefore, in order to data report application can distinguish nonurgent type data and general type data from the data preserved, thus report to server respectively, in the present embodiment, the data form of pre-defined SDK encapsulation of data, when SDK collects new data, it is not necessary to upgrade database, distinguish nonurgent type data and general type data by urgent identification information.SDK, when according to predefined data form encapsulation of data, will encapsulate urgent identification information, and do not encapsulates urgent identification information in general type data in nonurgent type data.Such as, the data form of definition nonurgent type data is as shown in table 1.
It will be understood by those skilled in the art that, data form is not necessarily the above-mentioned form enumerated, and can be any type, as long as data type and the parameter of data and value can be distinguished, such as json form also can meet demand, or following general data form:
(param1=value1)(param2 =value2)......(paramn-1=valuen-1)(paramn=valuen);
Wherein, param represents the parameter of certain categorical data, and as clicked on the id of event, duration, number of times etc., the value of value representation parameter param, such as download event, 30 seconds, 4 clicks etc..
Further, in the present embodiment, SDK provides urgent interface, and to data, nonurgent type data transmission is reported application.In order to avoid interface fragmentation, and owing to the urgent interface of event has been able to meet business demand, therefore, in the present embodiment, provide only the urgent interface of event, do not provide the urgent interface such as the page, session, Crash, thus avoid data to report application to lose control.
At interval of the first preset duration T1, data report analytic application in current first preset duration T1Whether each data of interior preservation are packaged with urgent identification information, obtain the first preset duration T1Interior preservation is packaged with the data of urgent identification information, using the data being packaged with urgent identification information that get as nonurgent type data, and has urgent ID information data for unencapsulated, is defined as general type data.Then current first preset duration T that will determine1The nonurgent type data of interior preservation all reports to server.
In the present embodiment, after described step S20, also include:
Step a, the nonurgent type data preserved in deleting described first preset duration;
After described step S30, also include:
Step b, the general type data preserved in deleting described second preset duration.
When data report application by current first preset duration T1After the nonurgent type data of interior preservation all reports to server, data report application to delete current first preset duration T1The nonurgent type data of interior preservation, namely from the data preserved, delete the nonurgent type data currently reporting to server.Afterwards, in next first preset duration T1In, when receiving the nonurgent type data that SDK sends, preserve, namely guarantee that the nonurgent type data that data report application to preserve is all first preset duration T1The nonurgent type data inside received, thus add data and report the free memory of application.
In like manner, report application by current second preset duration T when data2After the general type data of interior preservation all report to server, data report application to delete current second preset duration T2The general type data of interior preservation, namely from the data preserved, delete the general type data currently reporting to server.Afterwards, in next second preset duration T2In, when receiving the general type data that SDK sends, preserve, namely guarantee that the general type data that data report application to preserve are all second preset duration T2The general type data inside received, thus further increase data and report the free memory of application, it is ensured that data report the memory space abundance of application.
The scheme that the present embodiment proposes, when data report application by current first preset duration T1After the nonurgent type data of interior preservation all reports to server, data report application to delete current first preset duration T1The nonurgent type data of interior preservation, and, when data report application by current second preset duration T2After the general type data of interior preservation all report to server, data report application to delete current second preset duration T2The general type data of interior preservation, thus ensure that all nonurgent type data that data report application to preserve at any time are current first preset duration T1The nonurgent type data inside received, the nonurgent type data before preserved all deletes, and all general type data of preservation are current second preset duration T2The general type data inside received, the general type data before preserved all delete, thus add data and report the free memory of application.
As shown in Figure 10, data reporting method the 3rd embodiment of the present invention is proposed.Data reporting method the 3rd embodiment is with the difference of data reporting method the second embodiment, in data reporting method the 3rd embodiment, after described step S10, also includes:
Step S60, it is judged that whether the described data being currently received are nonurgent type data;
Step S70, when the described data being currently received are nonurgent type data, it is determined whether have started to timing;
Step S80, if not starting timing, then starts timing
Step S90, when timing reaches described first preset duration, reports to described server by the nonurgent type data preserved in described first preset duration.
In the present embodiment, data report to apply and are receiving data that SDK sends and after preserving, data report application to judge whether the data being currently received are nonurgent type data.When judging the data being currently received not as nonurgent type data, data report application not perform other operation, simply continue to, when receiving the data that SDK sends, preserve, and judge whether the data being currently received are nonurgent type data.Until when the data that data report application judgement to be currently received are nonurgent type data, now, data report application to judge whether to have begun to timing, if now not having started timing, then data report application to start timing;If the most timing, then continue timing.The first preset duration T also it is not up in timing1During, data report to be applied when receiving the data that SDK sends every time, no matter the data received are nonurgent type data, or general type data, data report application all to preserve.Afterwards, the first preset duration T is reached when timing1Time, data report application from this first preset duration T1The data of interior preservation inquire nonurgent type data, the nonurgent type data inquired is reported to server.Meanwhile, data report application that timing is updated to initial time, alternatively, timing are reset.Further, data report application to delete this first preset duration T1The nonurgent type data of interior preservation, namely delete the nonurgent type data currently reporting to server.
In the present embodiment, when timing is updated to initial time, data report in the data that application preserves and there is not nonurgent type data.Afterwards, when data report application receive the data of SDK transmission again and preserve these data, data report applies whether these data judging to receive and preserve are nonurgent type data, when these data are general type data, does not carry out timing.Data report application to continue to and preserve the data that SDK sends, until judging when the data currently receiving and preserving are nonurgent type data, now, data report application judgement not have started timing, perform to start the operation of timing.When timing reaches the first preset duration T1Time, it is above-mentioned by the first preset duration T that data report application to continue executing with1The nonurgent type data of interior preservation reports to the operation of server, just repeats no more at this.
The scheme that the present embodiment proposes, after reporting application the nonurgent type data of preservation to be reported to server due to data every time, all the nonurgent type data preserved is deleted, when receiving and preserve the data that SDK sends the most again, if these data are general type data, the most do not carry out timing, until when certain data receiving and preserving are nonurgent type data, just start timing, when timing reaches the first preset duration, data report application again to perform to report to the nonurgent type data preserved in time period the operation of server.Therefore, the present embodiment need not report nonurgent type data to server according to the frequency of the first preset duration mechanically, add the motility that nonurgent type data reports.
As shown in figure 11, data reporting method the 4th embodiment of the present invention is proposed.Data reporting method the 4th embodiment is with the difference of any of the above-described embodiment, and described data reporting method comprises the following steps:
Step S100, SDK gathers the data that application corresponding to described SDK is in operation, and wherein, described data include nonurgent type data and general type data;
Step S110, when the described data gathered are nonurgent type data, call default urgent interface and the transmission of described nonurgent type data is reported application to data, report application to preserve described nonurgent type data for described data, and at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to server;
Step S120, when the described data gathered are general type data, call default generic interface and the transmission of described general type data is reported application to described data, report application to preserve described general type data for described data, and at interval of the second preset duration, the general type data preserved in described second preset duration are reported to described server;
Wherein, described first preset duration is less than described second preset duration.
In the present embodiment, each application loaded in mobile terminal is integrated with Software of Data Statistics development kit (Software Development Kit, SDK), SDK is integrated in each application, for adding up the startup information of each application, page info, event click information, CRASH information etc..Further, being also loaded with data and report application in mobile terminal, hereinafter referred to as data report application.When during each application to be run by mobile terminal, corresponding data report to server, as shown in Figure 4, each application is corresponding SDK, data report application and server composition data reporting system.Each application run in time, the SDK acquisition applications of its correspondence be in operation correspondence data, these data include nonurgent type data and general type data.
Being nonurgent type data or the judgement of general type data for data, SDK can be judged by various flexi modes.Such as, for various different application, some application can be set to the urgent application reported of data previously according to user's requirement, and other application is set to data and need not the urgent application reported.Then when SDK collection be data urgent report application run data time, it is judged that these data of collection are nonurgent type data;When SDK collection be data need not urgent report application run data time, it is judged that these data of collection are general type data.Or, for a certain application, in running due to application, include various data, can pre-set certain form of data therein is nonurgent type data, and other kinds of data are general type data.Such as, data corresponding to the event that will click on are set to nonurgent type data, then when SDK collects data corresponding to click event, it is judged that these data collected are nonurgent type data.
SDK, for nonurgent type data and general type data, is respectively adopted different modes and sends to data and report application.Specifically, in the present embodiment, being previously provided with urgent interface corresponding to SDK and generic interface, the nonurgent type data collected transmission is reported application to data for SDK by urgent interface, and generic interface is for reporting application by the transmission of general type data to data.When SDK is when collecting nonurgent type data every time, call default urgent interface and the nonurgent type data collected transmission is reported application to data.Data report to be applied after receiving nonurgent type data, and nonurgent type data is stored in a memory block.When SDK is when collecting general type data every time, call default generic interface and the general type data collected transmission is reported application to data.Data report to be applied after receiving general type data, and general type data are stored in another memory block.
In order to avoid interface fragmentation, and owing to the urgent interface of event has been able to meet business demand, therefore, in the present embodiment, provide only the urgent interface of event, do not provide the urgent interface such as the page, session, Crash, thus avoid data to report application to lose control.
Further, in the present embodiment, described step S110 includes:
Step c, when the described data gathered are nonurgent type data every time, will encapsulate urgent identification information in described nonurgent type data;
Step d, calls default urgent interface and to data, the described nonurgent type data transmission being packaged with described urgent identification information is reported application.
Further, in order to reduce the coupling of data, make data report application nonurgent type data and general type data to be saved together, namely data report application can distinguish nonurgent type data and general type data from all data being saved together.In the present embodiment, SDK is when collecting nonurgent type data, SDK, when according to predefined data form encapsulation of data, will encapsulate urgent identification information, and do not encapsulates urgent identification information in general type data in nonurgent type data.Such as, the data form of definition nonurgent type data is as shown in table 1.
It will be understood by those skilled in the art that, data form is not necessarily the above-mentioned form enumerated, and can be any type, as long as data type and the parameter of data and value can be distinguished, such as json form also can meet demand, or following general data form:
(param1=value1)(param2=value2)......(paramn-1=valuen-1)(paramn=valuen);
Wherein, param represents the parameter of certain categorical data, and as clicked on the id of event, duration, number of times etc., the value of value representation parameter param, such as download event, 30 seconds, 4 clicks etc..
Data report application at interval of the first preset duration T1, by the first preset duration T1The nonurgent type data of interior preservation reports to server.At interval of the second preset duration T2The general type data preserved in second preset duration are reported to server.Wherein, this second preset duration T2More than the first preset duration T1
Server is when receiving nonurgent type data or the general type data that data report application to report, preserve the nonurgent type data or general type data received, and determine nonurgent type data or application corresponding to general type data, then all nonurgent type data corresponding to this application or general type data to preserving are analyzed, know the details that this application runs, thus carry out the associative operations such as next version exploitation of this application further according to the details obtained.
nullThe scheme that the present embodiment proposes,SDK is when collecting the data that corresponding application runs every time,If these data are nonurgent type data,Then call default urgent interface and nonurgent type data transmission is reported application to data,Data report application to preserve nonurgent type data,If these data are general type data,Then call default generic interface and the transmission of general type data is reported application to data,Data report application to preserve general type data,Then for the nonurgent type data preserved,Frequency with first preset duration of short period,Reported to server,And for the general type data preserved,Frequency with second preset duration of long period,Reported to server,Also server will quickly be reported to by nonurgent type data、General type data set reports to server,Thus not only achieve nonurgent type data and can report to server in time,Also reduce the number of times of mobile terminal Connection Service device,Reduce power consumption.
It should be noted that, in this article, term " includes ", " comprising " or its any other variant are intended to comprising of nonexcludability, so that include that the process of a series of key element, method, article or device not only include those key elements, but also include other key elements being not expressly set out, or also include the key element intrinsic for this process, method, article or device.In the case of there is no more restriction, statement " including ... " key element limited, it is not excluded that there is also other identical element in including the process of this key element, method, article or device.
The invention described above embodiment sequence number, just to describing, does not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art is it can be understood that can add the mode of required general hardware platform by software to above-described embodiment method and realize, can certainly pass through hardware, but a lot of in the case of the former is more preferably embodiment.Based on such understanding, the part that prior art is contributed by technical scheme the most in other words can embody with the form of software product, this computer software product is stored in a storage medium (such as ROM/RAM, magnetic disc, CD), including some instructions with so that a station terminal equipment (can be mobile phone, computer, server, air-conditioner, or the network equipment etc.) perform the method described in each embodiment of the present invention.
These are only the preferred embodiments of the present invention; not thereby the scope of the claims of the present invention is limited; every equivalent structure utilizing description of the invention and accompanying drawing content to be made or equivalence flow process conversion; or directly or indirectly it is used in other relevant technical fields, the most in like manner it is included in the scope of patent protection of the present invention.

Claims (10)

1. a data reporting device, it is characterised in that described data reporting device includes:
Memory module, for when receiving the data that SDK sends every time, preserves described Data, wherein, described data are the application that described SDK is corresponding when being in operation, described The data that SDK gathers, described data include nonurgent type data and general type data;
First sending module, is used for preservation in described first preset duration at interval of the first preset duration Nonurgent type data reports to server;
Second sending module, is used for preservation in described second preset duration at interval of the second preset duration General type data report to described server;Wherein, described first preset duration is second pre-less than described If duration.
2. data reporting device as claimed in claim 1, it is characterised in that described data reporting device Also include:
Acquisition module, at interval of the first preset duration, preserving in obtaining described first preset duration Being packaged with the data of urgent identification information, wherein, described SDK is according to the data preset During form encapsulation of data, nonurgent type data encapsulates urgent identification information;
Determining module, the data being used for be packaged with described urgent identification information are as nonurgent type data.
3. data reporting device as claimed in claim 1 or 2, it is characterised in that described data report Device also includes:
Whether the first judge module, be nonurgent type data for judging the described data being currently received;
Second judge module, for when the described data being currently received are nonurgent type data, determines Whether have started to timing;
Timing module, for when not starting timing, starts timing;
Described first sending module, for when timing reaches described first preset duration, by described first The nonurgent type data preserved in preset duration reports to described server.
4. a data reporting device, it is characterised in that described data reporting device includes:
Acquisition module, the data being in operation for the application that acquisition software development kit is corresponding, wherein, Described data include nonurgent type data and general type data;
3rd sending module, for when the described data gathered are nonurgent type data, calling default Described nonurgent type data is sent and reports application to data by urgent interface, reports application for described data Preserve described nonurgent type data, and will preserve in described first preset duration at interval of the first preset duration Nonurgent type data report to server;
4th sending module, for when the described data gathered are general type data, calling default Described general type data are sent and report application to described data by generic interface, report for described data Application preserves described general type data, and at interval of the second preset duration by described second preset duration The general type data preserved report to described server;
Wherein, described first preset duration is less than described second preset duration.
5. data reporting device as claimed in claim 4, it is characterised in that described 3rd sending module Including:
Encapsulation unit, for when the described data gathered are nonurgent type data, at described emergency type Data encapsulate urgent identification information;
Transmitting element, will be packaged with described in described urgent identification information for calling default urgent interface Nonurgent type data transmission reports application to data.
6. a data reporting method, it is characterised in that described data reporting method includes step:
When receiving the data that SDK sends every time, preserve described data, wherein, institute Stating data is the application that described SDK is corresponding when being in operation, described SDK The data gathered, described data include nonurgent type data and general type data;
At interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported to Server;
At interval of the second preset duration, the general type data preserved in described second preset duration are reported to Described server;
Wherein, described first preset duration is less than described second preset duration.
7. data reporting method as claimed in claim 6, it is characterised in that described pre-at interval of first If duration by described first preset duration preserve nonurgent type data report to server step it Before, also include:
At interval of the first preset duration, preserve in obtaining described first preset duration is packaged with urgent mark The data of information, wherein, described SDK according to preset data form encapsulation of data time, Urgent identification information is encapsulated in nonurgent type data;
Using be packaged with described urgent identification information data as nonurgent type data.
Data reporting method the most as claimed in claims 6 or 7, it is characterised in that described every time connecing When receiving the data that SDK sends, after preserving the step of described data, also include:
Judge whether the described data being currently received are nonurgent type data;
When the described data being currently received are nonurgent type data, it is determined whether have started to timing;
If not starting timing, then start timing;
When timing reaches described first preset duration, the urgent class that will preserve in described first preset duration Type data report to described server.
9. a data reporting method, it is characterised in that described data reporting method includes step:
SDK gathers the data that application corresponding to described SDK is in operation, Wherein, described data include nonurgent type data and general type data;
Gather described data be nonurgent type data time, call default urgent interface by described promptly Categorical data sends and reports application to data, reports application to preserve described emergency type number for described data According to, and at interval of the first preset duration, the nonurgent type data preserved in described first preset duration is reported To server;
Gather described data be general type data time, call default generic interface by described commonly Categorical data sends and reports application to described data, reports application to preserve described general category for described data Type data, and the general type data that will preserve in described second preset duration at interval of the second preset duration Report to described server;
Wherein, described first preset duration is less than described second preset duration.
10. data reporting method as claimed in claim 9, it is characterised in that described in the institute gathered State data when being nonurgent type data, call default urgent interface and described nonurgent type data is sent extremely Data report the step of application to include:
When the described data gathered are nonurgent type data, in described nonurgent type data, encapsulation is urgent Identification information;
Call default urgent interface to be sent out by the described nonurgent type data being packaged with described urgent identification information Deliver to data and report application.
CN201610355246.XA 2016-05-25 2016-05-25 Data report method and device Pending CN106027415A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610355246.XA CN106027415A (en) 2016-05-25 2016-05-25 Data report method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610355246.XA CN106027415A (en) 2016-05-25 2016-05-25 Data report method and device

Publications (1)

Publication Number Publication Date
CN106027415A true CN106027415A (en) 2016-10-12

Family

ID=57093298

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610355246.XA Pending CN106027415A (en) 2016-05-25 2016-05-25 Data report method and device

Country Status (1)

Country Link
CN (1) CN106027415A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107018046A (en) * 2017-06-06 2017-08-04 上海鋆创信息技术有限公司 A kind of collecting method, device, terminal and storage medium
CN107343091A (en) * 2017-06-27 2017-11-10 努比亚技术有限公司 Data reporting method and system
CN107463479A (en) * 2017-07-11 2017-12-12 上海精数信息科技有限公司 A kind of social data monitoring system
CN108882223A (en) * 2018-05-30 2018-11-23 努比亚技术有限公司 Using data reporting method, mobile terminal and computer readable storage medium
CN110995615A (en) * 2019-12-02 2020-04-10 德阳瑞能电力科技有限公司 Communication method for multilateral master-slave switching
CN111376255A (en) * 2018-12-29 2020-07-07 深圳市优必选科技有限公司 Robot data acquisition method and device and terminal equipment
CN115002650A (en) * 2021-12-08 2022-09-02 丰疆智能(深圳)有限公司 Data transmission method, device and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104899325A (en) * 2015-06-19 2015-09-09 上海卓悠网络科技有限公司 APP (application) acquired data collection method, terminal, server and system
CN104980304A (en) * 2015-06-15 2015-10-14 上海斐讯数据通信技术有限公司 Alarm control method and alarm control system applied to network system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104980304A (en) * 2015-06-15 2015-10-14 上海斐讯数据通信技术有限公司 Alarm control method and alarm control system applied to network system
CN104899325A (en) * 2015-06-19 2015-09-09 上海卓悠网络科技有限公司 APP (application) acquired data collection method, terminal, server and system

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107018046A (en) * 2017-06-06 2017-08-04 上海鋆创信息技术有限公司 A kind of collecting method, device, terminal and storage medium
CN107343091A (en) * 2017-06-27 2017-11-10 努比亚技术有限公司 Data reporting method and system
CN107463479A (en) * 2017-07-11 2017-12-12 上海精数信息科技有限公司 A kind of social data monitoring system
CN108882223A (en) * 2018-05-30 2018-11-23 努比亚技术有限公司 Using data reporting method, mobile terminal and computer readable storage medium
CN111376255A (en) * 2018-12-29 2020-07-07 深圳市优必选科技有限公司 Robot data acquisition method and device and terminal equipment
CN110995615A (en) * 2019-12-02 2020-04-10 德阳瑞能电力科技有限公司 Communication method for multilateral master-slave switching
CN115002650A (en) * 2021-12-08 2022-09-02 丰疆智能(深圳)有限公司 Data transmission method, device and storage medium

Similar Documents

Publication Publication Date Title
CN106027415A (en) Data report method and device
CN105791581A (en) Application operation method and device and mobile terminal
CN104820552A (en) Split-screen display method for mobile terminal and mobile terminal
CN105101366A (en) Mobile terminal control method and mobile terminal
CN105682057A (en) Message prompting device and message prompting method
CN105099870A (en) Message pushing method and device
CN105611631A (en) Method and device for distributing radio-frequency resources of mobile phone
CN105657844A (en) Resource distribution method and terminal
CN105243126A (en) Cross-screen screen capture method and apparatus
CN106453512A (en) Redis cluster information monitoring device and method
CN106375962A (en) Network searching method and mobile terminal
CN105303398A (en) Information display method and system
CN105739820A (en) Message prompt display method and device
CN104968033A (en) Terminal network processing method and apparatus
CN106791123A (en) User terminal and application processing method
CN106095464B (en) A kind of method and device of the seamless operation of application program
CN105208212A (en) Chatting record display device and method
CN106888495A (en) A kind of method for network access and terminal
CN107066290A (en) A kind of method and apparatus for starting application according to associating policy
CN105095051A (en) Method and device for reminding working state of background application program
CN105764085A (en) Abnormal electricity consumption detection method and terminal
CN105702264A (en) Audio processing device and method
CN106330211A (en) LTE frequency band selecting method and device
CN105554710A (en) Message display method and device
CN105278995A (en) Management method of application, system, server and mobile terminal

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20161012