Method and device for automatic client tracking

By listening to client operation events and reading the attribute values ​​of the operation object, and combining AOP technology and custom attribute values ​​to generate configuration information tables, the existing point burial method has solved the problem of high development costs and inconsistent data, and achieved low-cost and accurate data collection and reduced garbage data.

CN114706738BActive Publication Date: 2025-08-19CHINA CONSTRUCTION BANK
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210163338.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-22
Publication Date
2025-08-19
Estimated Expiration
2042-02-22

AI Technical Summary

Technical Problem

The existing client point burying methods have problems such as high development costs, inconsistent data formats, difficulty in customizing event names and reducing spam data, and cannot meet the complex business needs of large application software.

Method used

By listening to operation events on the client page, using pre-inserted acquisition code to read the attribute value of the operation object, and determining whether it contains the pre-configured event name, only the attribute value that meets the conditions is uploaded to the back-end server, and combining AOP technology and custom attribute values ​​to generate a configuration information table to achieve automatic burial of points.

Benefits of technology

It reduces the cost of burying points, reduces spam data, improves data recognition rate, reduces the pressure on back-end servers, and achieves accurate collection based on business needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114706738B_ABST
    Figure CN114706738B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and device for automatically tracking user activity on a client, relating to the technical field of big data analysis. The method comprises: monitoring user operation events on a client page and determining the operation object corresponding to the operation event; reading the attribute value of the operation object using pre-inserted acquisition code based on an instance of the operation object; determining whether the attribute value contains a pre-configured event name; and if the attribute value contains the pre-configured event name, uploading the attribute value of the operation object to a backend server. The present invention can reduce the development cost of tracking activity, enable the definition of attributes such as event names according to business needs, and reduce junk data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of big data analysis, and in particular to a method and device for automatic client tracking. Background Art

[0002] This section is intended to provide a background or context to the embodiments of the invention that are recited in the claims. No statement herein is admitted to be prior art by virtue of its inclusion in this section.

[0003] As software development projects grow larger and system business processes become more diverse, the complexity of project architectures increases. With numerous application (App) clients and ever-changing user network environments, detailed user behavior data is required to continuously track software products in all aspects and analyze the underlying reasons why users take certain actions or don't take them. Comprehensive statistical analysis of user behavior data across multiple indicators and dimensions, such as user attributes and usage behavior, is required to continuously optimize software products and provide comprehensive data support for software product operations and promotion decisions. Without accurate and comprehensive user behavior data as support, subsequent analysis may be difficult to obtain accurate and insightful results, resulting in a lack of data support in the marketing closed loop and making refined operations even more difficult to implement.

[0004] Event tracking, also known as event tracking, is the technology and implementation process for capturing, processing, and transmitting specific user behaviors or events. It can be categorized into client-side tracking and server-side tracking. Client-side tracking involves recording the actions and trajectories generated by a user while using a webpage, and transmitting this data to the server via the network. Currently, there are three client-side tracking methods: code tracking, full tracking, and visual tracking.

[0005] Code tracking means directly inserting tracking code into a certain logic, and sending the collected user behavior data through pre-written code when an event occurs. For example, Figure 1 The data collection process of code tracking is shown in Figure 2. Figure 1 As shown, the user operates the client (clicks or browses a page, etc.) to trigger the corresponding business logic code; the client converts the user behavior data into tracking element data and calls the tracking method of the Software Development Kit (SDK); the SDK tracking method saves the user behavior data to the local database; the client reads the local database and uploads the collected user behavior data to the back-end server in a standardized manner.

[0006] Code tracking requires a large amount of handwritten tracking code, which is mixed with the original business logic code, affecting code quality and maintenance costs, and increasing development costs. For enterprise-level applications, there are many functions involved, many collaborators, and low efficiency. It also depends on the App version, and some users may not have updated the version, resulting in data loss.

[0007] Compared with code tracking, full tracking does not require application developers to write code or only needs to write a small amount of code. By inserting the tracking logic into the original file during the compilation phase, all or most user behavior data can be automatically collected in advance. Figure 2 As shown, full embedding uses AOP (Aspect Oriented Programming) technology, or monitors lifecycle events, and uniformly processes collection events such as page browsing and button clicks. After the event is triggered, the SDK embedding method is called to convert the collected data into embedding model data and save it to the local database. The local database is then read to upload the standardized collection data to the back-end server. Taking Android as an example, the registerActivityLifecycleCallbacks method is used in appliction (a system component in Android, representing the class of the application) to monitor the life cycle of each operation page to automatically collect page browsing data. For events such as clicks, ASM and Gradle plug-ins are used to inject the SDK click event logic code into the original click logic during compilation, and the collection logic is automatically triggered when the user clicks.

[0008] However, full embedding can only collect data on the original attributes of the page or control; the amount of data collected is large, which takes up a lot of storage space; it is also impossible to name events in the way the business wants, making it difficult to organize and process data.

[0009] Visual tracking refers to a method in which users connect to the data access management page of the user behavior analysis tool through their devices, and directly operate on the interactive page elements that are effective after interaction to implement data tracking. Figure 3 The data collection process of visual tracking is shown in Figure 2. Figure 3 After the app establishes a connection with the server's visualization tool interface, it sends device information to the server, which then sends a screen drawing request to the app. The app processes the drawing request, generates a control tree, and sends the generated control tree and screenshots to the server. The server displays the screenshots and records the control tree. Administrators or business personnel mark the desired tracking points and name the specified events, saving the event identifier and parameters to the configuration table. The configuration information is synchronized and sent to the server, which updates the tracking point configuration information collection. The SDK automatically matches the collection and transmission of user behavior data according to the configuration information.

[0010] Visual tracking also has certain defects. It cannot obtain customized data and can only save configurations through the information of the control tree. When matching collection, it can only match collection events based on the control information. When the interface is a public interface, it is impossible to distinguish specific business functions based solely on the control information, that is, it is impossible to name and distinguish multiple events on the public interface. In addition, the visual interface is deployed to the server and interacts with the server, which increases development difficulty and cost.

[0011] As can be seen above, each of the three existing tracking methods has its shortcomings. Furthermore, large-scale application software encompasses complex and ever-changing business requirements, which cannot be met by a single tracking method alone. A combination of several tracking methods is often required. Different tracking methods also use different formats for collected data and uploaded to the server, making it impossible to meet the server's requirement for a unified upload format. Furthermore, different tracking methods have varying development costs. Achieving low-cost tracking, defining custom attributes such as event names based on business needs, tracing user data back through collected data, and reducing junk data are pressing challenges. Summary of the Invention

[0012] An embodiment of the present invention provides a method for automatically tracking events on a client, which is used to reduce the development cost of tracking events, define attributes such as event names according to business needs, and reduce junk data. The method includes:

[0013] Monitor the user's operation events on the client page and determine the operation object corresponding to the operation event;

[0014] According to the instance of the operation object, using the pre-inserted acquisition code to read the attribute value of the operation object;

[0015] Determining whether the attribute value contains a pre-configured event name;

[0016] If the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the backend server.

[0017] In one implementation of the embodiment of the present invention, the operation object includes a page and a control. Before reading the system property value of the operation object using the pre-inserted acquisition code according to the instance of the operation object, the method further includes:

[0018] Insert the pre-written first acquisition code into the page lifecycle method;

[0019] Use AOP technology to insert the pre-written second collection code into the onClick event of the control click;

[0020] According to the instance of the operation object, the attribute value of the operation object is read using the pre-inserted acquisition code, including:

[0021] When the operation object is a page, the attribute value of the page is read using the first acquisition code according to the instance of the page;

[0022] When the operation object is a control, the property value of the control is read using the second acquisition code according to the instance of the control.

[0023] In one implementation of the embodiment of the present invention, the operation object includes a page and a control. Before reading the attribute value of the operation object using the pre-inserted acquisition code according to the instance of the operation object, the method further includes:

[0024] Receive the custom property value of the operation object configured by the developer; the custom property value of the page includes the page event name and page ID, and the custom property value of the control includes the control event name and the page ID of the page where the control is located;

[0025] According to the instance of the operation object, the attribute value of the operation object is read using the pre-inserted acquisition code, including:

[0026] According to the instance of the operation object, the system property value and / or custom property value of the operation object is read using the pre-inserted acquisition code; wherein, the system property value of the page includes the page class name, the previous page class name, the page path, the page width and height, the page screen horizontal and vertical orientation and the page title; the system property value of the control includes the control ID, the control content, the control path, the control type and the page class name of the page where the control is located.

[0027] In one implementation of the embodiment of the present invention, after receiving the custom attribute value of the operation object configured by the developer, the method further includes:

[0028] Generate a configuration information table based on the custom attribute values and system attribute values of the operation object;

[0029] Determining whether the attribute value contains a pre-configured event name includes:

[0030] It is determined according to the configuration information table whether the attribute value contains a pre-configured event name.

[0031] In one implementation of the embodiment of the present invention, after determining whether the attribute value includes a pre-configured event name, the method further includes:

[0032] If the attribute value does not contain the event name of the operation event, matching the read attribute value of the operation object with the attribute value of the operation object in the configuration information table;

[0033] If the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table, the attribute value of the corresponding operation object in the configuration information table is merged with the attribute value of the read operation object and uploaded to the backend server.

[0034] In one implementation of the embodiment of the present invention, matching the read attribute value of the operation object with the attribute value of the operation object in the configuration information table includes:

[0035] When the operation object is a page, match the read page class name, page title, and previous page class name with the attribute value of the operation object in the configuration information table;

[0036] When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

[0037] In one implementation of the embodiment of the present invention, after matching the read attribute value of the operation object with the attribute value of the operation object in the configuration information table, the method further includes:

[0038] If the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table, the operation event is determined as a non-upload event.

[0039] An embodiment of the present invention further provides a device for automatically tracking events on a client, which is used to reduce the development cost of tracking events, define attributes such as event names according to business needs, and reduce junk data. The device includes:

[0040] The monitoring module is used to monitor the user's operation events on the client page and determine the operation object corresponding to the operation event;

[0041] A reading module, configured to read the attribute value of the operation object using the pre-inserted acquisition code according to the instance of the operation object;

[0042] A judgment module, used to judge whether the attribute value contains a pre-configured event name;

[0043] The communication module is used to upload the attribute value of the operation object to the backend server when the attribute value contains a pre-configured event name.

[0044] In one implementation of the embodiment of the present invention, the operation object includes a page and a control, and the device further includes a code insertion module for:

[0045] Insert the pre-written first acquisition code into the page lifecycle method;

[0046] Use AOP technology to insert the pre-written second collection code into the onClick event of the control click;

[0047] Read module for:

[0048] When the operation object is a page, the attribute value of the page is read using the first acquisition code according to the instance of the page;

[0049] When the operation object is a control, the property value of the control is read using the second acquisition code according to the instance of the control.

[0050] In one implementation of the embodiment of the present invention, the operation object includes a page and a control, and the communication module is further configured to:

[0051] Receive the custom property value of the operation object configured by the developer; the custom property value of the page includes the page event name and page ID, and the custom property value of the control includes the control event name and the page ID of the page where the control is located;

[0052] Read module for:

[0053] According to the instance of the operation object, the system property value and / or custom property value of the operation object is read using the pre-inserted acquisition code; wherein, the system property value of the page includes the page class name, the previous page class name, the page path, the page width and height, the page screen horizontal and vertical orientation and the page title; the system property value of the control includes the control ID, the control content, the control path, the control type and the page class name of the page where the control is located.

[0054] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0055] Configuration module, used to generate a configuration information table based on the custom attribute values and system attribute values of the operation object;

[0056] Judgment module, used to:

[0057] It is determined according to the configuration information table whether the attribute value contains a pre-configured event name.

[0058] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0059] A matching module, configured to match the read attribute value of the operation object with the attribute value of the operation object in the configuration information table when the attribute value does not contain the event name of the operation event;

[0060] The communication module is also used to merge the attribute value of the corresponding operation object in the configuration information table with the attribute value of the read operation object and upload them to the backend server if the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table.

[0061] In one implementation of the embodiment of the present invention, the matching module is configured to:

[0062] When the operation object is a page, match the read page class name, page title, and previous page class name with the attribute value of the operation object in the configuration information table;

[0063] When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

[0064] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0065] The determination module is configured to determine the operation event as a non-upload event when the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table.

[0066] An embodiment of the present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned method of automatic client tracking when executing the computer program.

[0067] An embodiment of the present invention also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the above-mentioned method of automatic client tracking.

[0068] An embodiment of the present invention also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the above-mentioned method of automatic client tracking.

[0069] In an embodiment of the present invention, the user's operation events on the client page are monitored, and the operation object corresponding to the operation event is determined. The attribute value of the operation object is read using the pre-inserted acquisition code. When the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the back-end server. In this way, the attribute value of the operation object can be automatically collected by embedding a small amount of acquisition code, which reduces the number of required embedding codes and avoids mixing the embedding code with normal business logic, thereby reducing development costs. In addition, by pre-configuring the attribute values such as the event name of the operation event, the attribute value of the operation event containing the event name in the attribute value is uploaded, which realizes accurate identification of the acquisition event and improves the recognition rate of the acquired data. At the same time, it limits the scope of the operation events to be acquired, quickly filters out the required acquisition data, reduces redundant data, and relieves the pressure on the back-end server. BRIEF DESCRIPTION OF THE DRAWINGS

[0070] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work. In the drawings:

[0071] Figure 1 This is a schematic diagram of a data collection process for code embedding in the prior art;

[0072] Figure 2 This is a schematic diagram of a data collection process for all buried points in the prior art;

[0073] Figure 3 This is a schematic diagram of a data collection process for visualizing buried points in the prior art;

[0074] Figure 4 This is a flow chart of a method for automatically tracking data on a client side according to an embodiment of the present invention;

[0075] Figure 5 Another flow chart of a method for automatic tracking of client data in an embodiment of the present invention;

[0076] Figure 6 Another flow chart of a method for automatic tracking of client data in an embodiment of the present invention;

[0077] Figure 7 Another flow chart of a method for automatic tracking of client data in an embodiment of the present invention;

[0078] Figure 8 Another flow chart of a method for automatic tracking of client data in an embodiment of the present invention;

[0079] Figure 9 This is a schematic diagram of the structure of a device for automatic tracking of client data in an embodiment of the present invention;

[0080] Figure 10 Schematic diagram of the structure of a computer device in an embodiment of the present invention. DETAILED DESCRIPTION

[0081] To make the purpose, technical solutions and advantages of the embodiments of the present invention more clear, the embodiments of the present invention are further described in detail below with reference to the accompanying drawings. Here, the exemplary embodiments of the present invention and their descriptions are used to explain the present invention, but are not intended to limit the present invention.

[0082] First of all, it should be noted that the acquisition, storage, use, and processing of data in the technical solution of the present invention comply with the relevant provisions of national laws and regulations.

[0083] The embodiment of the present invention provides a method for automatically tracking points on a client. Figure 4 As shown, the method includes the following steps 401 to 404:

[0084] Step 401: Monitor the user's operation events on the client page and determine the operation object corresponding to the operation event.

[0085] The operation objects include pages and controls, and the operation events include opening and closing of pages, and clicking or exposing of controls, which are respectively called page browsing events and control click events.

[0086] Step 402: According to the instance of the operation object, the attribute value of the operation object is read using the pre-inserted acquisition code.

[0087] In order to realize the reading of property values of pages and controls respectively, in an embodiment of the present invention, before using the pre-inserted collection code to read the system property value of the operation object according to the instance of the operation object, a pre-written first collection code is inserted into the page life cycle method; and the pre-written second collection code is inserted into the onClick event of the control click using AOP technology.

[0088] An instance is a concrete representation of an object, used to simulate something concrete or prototype in the real world. An instance represents an object, such as an application, page, or control, and identifies it. OnClick is an event that occurs when a click occurs in mobile app development.

[0089] Page lifecycle methods can be registered separately and separated from business function codes. Therefore, inserting the first acquisition code into the page lifecycle method will not affect the implementation of the business function code.

[0090] After the first and second acquisition codes are deployed, different acquisition codes are used to read the attribute values of the operation objects, depending on the operation object. Specifically, when a page is opened or closed, the operation object is determined to be the page, triggering the page lifecycle method. Based on the page instance, the first acquisition code is used to read the page attribute values. When a user clicks or a control is exposed, the operation object is determined to be a control, automatically triggering the onClick event. The second acquisition code inserted in the onClick event holds a reference to the currently clicked control instance. Based on the control instance, the second acquisition code is used to read the control attribute values.

[0091] Property values are divided into custom property values and system property values. Custom property values are configured by developers. Figure 5 As shown, before executing step 402 to read the attribute value of the operation object using the pre-inserted acquisition code according to the instance of the operation object, the following step 501 may also be executed:

[0092] Step 501: Receive the custom attribute value of the operation object configured by the developer.

[0093] The custom property value of a page includes the page event name and the page ID, and the custom property value of a control includes the control event name and the page ID of the page where the control is located.

[0094] After step 501 is executed, step 402 may be executed as follows:

[0095] Step 4021: Based on the instance of the operation object, use the pre-inserted acquisition code to read the system attribute value and / or custom attribute value of the operation object.

[0096] Pages and controls each have a common base class, and event properties are uniformly defined in the base class. When developing specific functions, developers can add or modify custom property values of pages or controls in the corresponding base class.

[0097] System property values are generally set for pages or controls during development. The system property values for a page include the page class name, previous page class name, page path, page width and height, screen orientation, and page title. The system property values for a control include the control ID, control content, control path, control type, and the page class name of the page where the control is located.

[0098] Taking into account that some operation objects, such as existing pages or interfaces integrated with certain third-party SDKs, may not necessarily have custom attribute values, therefore, depending on the instance of the operation object, the attribute values read by the pre-inserted collection code may include system attribute values, custom attribute values, or no custom attribute values.

[0099] It should be noted that if a custom property value in a page or control has the same property name as a system property value, the custom property value takes precedence.

[0100] Step 403: Determine whether the attribute value contains a pre-configured event name.

[0101] In another implementation of the embodiment of the present invention, in order to facilitate the determination of whether the attribute value of the read operation object contains a pre-configured event name, such as Figure 6 As shown, after executing step 501 to receive the custom attribute value of the operation object configured by the developer, the following step 601 may be executed:

[0102] Step 601: Generate a configuration information table according to the custom attribute values and system attribute values of the operation object.

[0103] The configuration information table contains all operation objects and their corresponding custom attribute values and system attribute values.

[0104] After executing step 601, step 403 is executed as follows:

[0105] Step 4031: Determine whether the attribute value contains a pre-configured event name according to the configuration information table.

[0106] The configuration information table can be generated by the backend server and then sent to the client. The client compares the read attribute value with attributes such as the event name in the configuration information table to determine whether the attribute value contains the pre-configured event name.

[0107] Step 404: If the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the backend server.

[0108] In addition to uploading the attribute values of the operation object, other data related to the operation event other than the attribute values can also be uploaded according to the developer's settings, such as the time and location of the operation event.

[0109] Considering that each time the attribute value of the operation object is collected, the data is uploaded to the back-end server in real time. This operation is relatively frequent and will occupy more transmission resources. In an embodiment of the present invention, the collected attribute values can be first stored in a local database and then uploaded to the back-end server in a unified manner.

[0110] In another implementation, Figure 7 As shown, after executing step 403, the following steps 701 and 702 may also be executed:

[0111] Step 701: If the attribute value does not contain the event name of the operation event, then match the attribute value of the read operation object with the attribute value of the operation object in the configuration information table;

[0112] Step 702: If the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table, the attribute value of the corresponding operation object in the configuration information table is merged with the attribute value of the read operation object and uploaded to the backend server.

[0113] Specifically, when the operation object is a page, the read page class name, page title, and previous page class name are matched with the attribute values of the operation object in the configuration information table.

[0114] When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

[0115] Since some operation objects whose data you want to collect may not be configured with custom attribute values, but these operation objects are within the collection range of the tracking point, in this case, the system attribute values of the obtained operation objects can be mapped with the configuration information table. Taking the page as an example, the system attribute values of the read operation objects are matched with the attribute values of the operation objects in the configuration information table with the same page class name, the same page title, and the same previous page class name.

[0116] If the match is successful, the event name matched in the configuration information table is used as the event name of this operation event, and the attribute value of the corresponding operation object in the configuration information table is merged with the attribute value of the read operation object and uploaded to the backend server.

[0117] In another implementation, Figure 8 As shown, if the attribute value does not contain the event name of the operation event in step 701, after matching the attribute value of the read operation object with the attribute value of the operation object in the configuration information table, the following step 801 may be further executed:

[0118] Step 801: If the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table, the current operation event is determined as a non-upload event.

[0119] The configuration information table contains the attribute values of the operation events that the developer configures to be collected. If the attribute values of the read operation object fail to match the attribute values of the operation object in the configuration information table, it indicates that the operation event is outside the collection range of the tracking point, and therefore the operation event is determined to be an event that will not be uploaded.

[0120] In an embodiment of the present invention, the user's operation events on the client page are monitored, and the operation object corresponding to the operation event is determined. The attribute value of the operation object is read using the pre-inserted acquisition code. When the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the back-end server. In this way, the attribute value of the operation object can be automatically collected by embedding a small amount of acquisition code, which reduces the number of required embedding codes and avoids mixing the embedding code with normal business logic, thereby reducing development costs. In addition, by pre-configuring the attribute values such as the event name of the operation event, the attribute value of the operation event containing the event name in the attribute value is uploaded, which realizes accurate identification of the acquisition event and improves the recognition rate of the acquired data. At the same time, it limits the scope of the operation events to be acquired, quickly filters out the required acquisition data, reduces redundant data, and relieves the pressure on the back-end server.

[0121] The present invention also provides a device for automatically burying points on the client side, as described in the following embodiments. Since the principle of solving the problem by the device is similar to that of the method for automatically burying points on the client side, the implementation of the device can refer to the implementation of the method for automatically burying points on the client side, and the repeated parts will not be repeated.

[0122] like Figure 9 As shown, the device 900 includes a monitoring module 901 , a reading module 902 , a judgment module 903 and a communication module 904 .

[0123] The monitoring module 901 is used to monitor the operation events of the user on the client page and determine the operation object corresponding to the operation event;

[0124] The reading module 902 is used to read the attribute value of the operation object using the pre-inserted acquisition code according to the instance of the operation object;

[0125] The judging module 903 is used to judge whether the attribute value contains a pre-configured event name;

[0126] The communication module 904 is configured to upload the attribute value of the operation object to the backend server when the attribute value contains the event name of the operation event.

[0127] In one implementation of the embodiment of the present invention, the operation object includes a page and a control, and the device further includes a code insertion module for:

[0128] Insert the pre-written first acquisition code into the page lifecycle method;

[0129] Use AOP technology to insert the pre-written second collection code into the onClick event of the control click;

[0130] Read module for:

[0131] When the operation object is a page, the first acquisition code is used to read the attribute value of the page according to the instance of the page;

[0132] When the operation object is a control, the property value of the control is read using the second acquisition code according to the instance of the control.

[0133] In one implementation of the embodiment of the present invention, the operation object includes a page and a control, and the communication module is further used to:

[0134] Receive the custom property value of the operation object configured by the developer; the custom property value of the page includes the page event name and page ID, and the custom property value of the control includes the control event name and the page ID of the page where the control is located;

[0135] Read module for:

[0136] According to the instance of the operation object, the system property value and / or custom property value of the operation object is read using the pre-inserted acquisition code; among them, the system property value of the page includes the page class name, the previous page class name, the page path, the page width and height, the page screen horizontal and vertical orientation and the page title; the system property value of the control includes the control ID, the control content, the control path, the control type and the page class name of the page where the control is located.

[0137] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0138] Configuration module, used to generate a configuration information table based on the custom attribute values and system attribute values of the operation object;

[0139] Judgment module, used to:

[0140] Determine whether the attribute value contains a pre-configured event name according to the configuration information table.

[0141] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0142] A matching module, configured to match the read attribute value of the operation object with the attribute value of the operation object in the configuration information table when the attribute value does not contain the event name of the operation event;

[0143] The communication module is also used to merge the attribute value of the corresponding operation object in the configuration information table with the attribute value of the read operation object and upload them to the backend server if the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table.

[0144] In one implementation of the embodiment of the present invention, the matching module is configured to:

[0145] When the operation object is a page, match the read page class name, page title, and previous page class name with the attribute value of the operation object in the configuration information table;

[0146] When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

[0147] In one implementation of the embodiment of the present invention, the apparatus further includes:

[0148] The determination module is configured to determine the operation event as a non-upload event when the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table.

[0149] In an embodiment of the present invention, the user's operation events on the client page are monitored, and the operation object corresponding to the operation event is determined. The attribute value of the operation object is read using the pre-inserted acquisition code. When the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the back-end server. In this way, the attribute value of the operation object can be automatically collected by embedding a small amount of acquisition code, which reduces the number of required embedding codes and avoids mixing the embedding code with normal business logic, thereby reducing development costs. In addition, by pre-configuring the attribute values such as the event name of the operation event, the attribute value of the operation event containing the event name in the attribute value is uploaded, which realizes accurate identification of the acquisition event and improves the recognition rate of the acquired data. At the same time, it limits the scope of the operation events to be acquired, quickly filters out the required acquisition data, reduces redundant data, and relieves the pressure on the back-end server.

[0150] An embodiment of the present invention further provides a computer device, Figure 10 Schematic diagram of a computer device in an embodiment of the present invention. The computer device can implement all steps of the method for automatic client tracking in the above embodiment. The computer device specifically includes the following contents:

[0151] Processor 1001, memory 1002, communications interface 1003 and communication bus 1004;

[0152] The processor 1001, memory 1002, and communication interface 1003 communicate with each other via the communication bus 1004; the communication interface 1003 is used to implement information transmission between related devices;

[0153] The processor 1001 is used to call the computer program in the memory 1002, and when the processor executes the computer program, the method of automatic client tracking in the above embodiment is implemented.

[0154] An embodiment of the present invention also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, it implements the above-mentioned method of automatic client tracking.

[0155] An embodiment of the present invention also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the above-mentioned method of automatic client tracking.

[0156] It will be understood by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Thus, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0157] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowcharts and / or block diagrams, as well as combinations of processes and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowcharts and / or block diagrams. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0158] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0159] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 The steps for the function specified in one or more boxes.

[0160] The specific embodiments described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for automatically tracking points on a client, characterized in that: The method comprises: Monitor the user's operation events on the client page and determine the operation objects corresponding to the operation events, including pages and controls; Receive the custom property value of the operation object configured by the developer; the custom property value of the page includes the page event name and page ID, and the custom property value of the control includes the control event name and the page ID of the page where the control is located; Insert the pre-written first acquisition code into the page life cycle method; use AOP technology to insert the pre-written second acquisition code into the onClick event of the control click; the page life cycle method is registered separately and separated from the business function code; When the operation object is a page, the system property value and / or custom property value of the page is read using a first acquisition code according to the instance of the page; when the operation object is a control, the system property value and / or custom property value of the control is read using a second acquisition code according to the instance of the control; wherein the system property value of the page includes the page class name, the previous page class name, the page path, the page width and height, the page screen orientation and the page title; the system property value of the control includes the control ID, the control content, the control path, the control type and the page class name of the page where the control is located; if the custom property value in the page or control has the same property name as the system property value, the custom property value shall prevail; Determining whether the attribute value contains a pre-configured event name; If the attribute value contains a pre-configured event name, the attribute value of the operation object is uploaded to the backend server.

2. The method according to claim 1, characterized in that After receiving the custom property value of the operation object configured by the developer, the method further includes: Generate a configuration information table based on the custom attribute values and system attribute values of the operation object; Determining whether the attribute value contains a pre-configured event name includes: It is determined according to the configuration information table whether the attribute value contains a pre-configured event name.

3. The method according to claim 2, characterized in that After determining whether the attribute value includes a pre-configured event name, the method further includes: If the attribute value does not contain the event name of the operation event, matching the read attribute value of the operation object with the attribute value of the operation object in the configuration information table; If the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table, the attribute value of the corresponding operation object in the configuration information table is merged with the attribute value of the read operation object and uploaded to the backend server.

4. The method according to claim 3, characterized in that Match the attribute values of the read operation object with the attribute values of the operation object in the configuration information table, including: When the operation object is a page, match the read page class name, page title, and previous page class name with the attribute value of the operation object in the configuration information table; When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

5. The method according to claim 3 or 4, characterized in that After matching the read attribute value of the operation object with the attribute value of the operation object in the configuration information table, the method further includes: If the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table, the operation event is determined as a non-upload event.

6. A device for automatic tracking of client points, characterized in that: The device comprises: The monitoring module is used to monitor the user's operation events on the client page and determine the operation object corresponding to the operation event; The code insertion module is used to: insert the pre-written first acquisition code into the page life cycle method; use AOP technology to insert the pre-written second acquisition code into the onClick event of the control click; The communication module is used to receive the custom property values of the operation objects configured by the developer. The custom property values of the page include the page event name and page ID, and the custom property values of the control include the control event name and the page ID of the page where the control is located. The page lifecycle methods are registered separately and separated from the business function code. a reading module configured to, when the operation object is a page, read the system property values and / or custom property values of the page using a first acquisition code according to an instance of the page; and, when the operation object is a control, read the system property values and / or custom property values of the control using a second acquisition code according to an instance of the control; wherein the system property values of the page include the page class name, the previous page class name, the page path, the page width and height, the page screen orientation, and the page title; the system property values of the control include the control ID, the control content, the control path, the control type, and the page class name of the page where the control is located; if a custom property value in a page or control has the same property name as a system property value, the custom property value shall prevail; A judgment module, used to judge whether the attribute value contains a pre-configured event name; The communication module is further configured to upload the attribute value of the operation object to the backend server when the attribute value contains a pre-configured event name.

7. The device according to claim 6, characterized in that The device further comprises: Configuration module, used to generate a configuration information table based on the custom attribute values and system attribute values of the operation object; Judgment module, used to: It is determined according to the configuration information table whether the attribute value contains a pre-configured event name.

8. The device according to claim 7, characterized in that The device further comprises: A matching module, configured to match the read attribute value of the operation object with the attribute value of the operation object in the configuration information table when the attribute value does not contain the event name of the operation event; The communication module is also used to merge the attribute value of the corresponding operation object in the configuration information table with the attribute value of the read operation object and upload them to the backend server if the attribute value of the read operation object successfully matches the attribute value of the operation object in the configuration information table.

9. The device according to claim 8, characterized in that Matching modules for: When the operation object is a page, match the read page class name, page title, and previous page class name with the attribute value of the operation object in the configuration information table; When the operation object is a control, the page class name of the page where the control is located, the page title of the page where the control is located, the class name of the previous page where the control is located, and the control content are matched with the attribute values of the operation object in the configuration information table.

10. The device according to claim 8 or 9, characterized in that The device further comprises: The determination module is configured to determine the operation event as a non-upload event when the attribute value of the read operation object fails to match the attribute value of the operation object in the configuration information table.

11. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method according to any one of claims 1 to 5 is implemented.

12. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.

13. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • Data reporting method and device, data obtaining method and device, equipment and medium

    CN111741046A