Reporting configuration

Updated at:

This topic describes how to configure the sample rate for a page in the console. This lets you adjust the data reporting ratio as needed.

Overview

After you integrate the software development kit (SDK) into an application, the SDK reports sampled data based on the default platform configuration. The reporting configuration feature lets you customize SDK data reporting and sampling based on your business needs.

Module sampling configuration

Step 1: Enable sampling

Click the Event Reporting Switch to enable or disable sampling for the target module.

Important

If you enable sampling, data is reported based on the sampling configuration. If you disable sampling, the module stops reporting data.

Step 2: Configure sampling and reporting rules

  1. Select the target module tab and click Create Rule.

  2. In the Create Rule dialog box, configure the reporting rule and sample rate for the module as needed.

    1. Sample rate: If you want to control the data stream or do not need to process all data, you can configure a sample rate. The SDK randomly selects and reports a percentage of the total data based on this rate.

    2. Filter conditions: If your business scenario requires you to track specific metrics, you can configure filter conditions. You can connect multiple filter conditions with AND or OR.

    For example, if you set `app.version` to `1.0.0` and the sample rate to 60%, the SDK collects only data from application version 1.0.0. It then randomly selects and reports 60% of that data.

The following table lists the configurable rule fields for each plugin. The common fields can be configured for all feature modules.

Plugin type

Field name

Field description

Common fields

app.version

Application version

app.channel

SDK initialization channel number

device.version

Version of the browser

device.os

System

device.resolution

Resolution

device.model

Device model

eventTime

Reporting time

sdk.version

Plugin SDK version

user.id

User ID

user.nick

User nickname

userAgent

Browser user agent

uri

Page URI

JS errors

payload.type

Error type

payload.name

Error name

payload.filename

Error file

Blank screen

payload.reason

Blank screen trigger timing

Performance

payload.name

Performance metric name

Static resources

payload.requestUri

Static resource URI

payload.code

HTTP status code

payload.resourceType

Resource type

Requests

payload.requestUri

Request URI

payload.code

HTTP status code

payload.method

Request method

payload.headers

Request header

Whitelist configuration

To focus on the data reported by a specific user, you can create a whitelist. After you create a whitelist, the SDK fully samples and reports all data from all feature modules for that device or user.

Note

The UserID is the `UserID` field that is passed during SDK initialization.