Flashduty Docs
中文EnglishRoadmapAPI官网控制台
中文EnglishRoadmapAPI官网控制台
  1. Session Replay
  • Introduction
  • On-call
    • Getting Started
      • Quick start
      • FAQ
      • Product Comparison
    • Incidents
      • What is an Incident
      • View Incidents
      • Handle Incidents
      • Escalations and Assignments
      • Custom Fields
      • Custom Actions
      • Alert Noise Reduction
      • Past Incidents
      • Outlier Incidents
    • Configure On-call
      • Channels
      • Integrate Alerts
      • Alert Noise Reduction
      • Escalation Rules
      • Label Enrichment
      • Schedules
      • Templates
      • Service Calendars
      • Preferences
      • Alert Routing
      • Silence and Inhibition
      • Filters
      • Notification Bots
      • Alert Pipeline
    • Advanced Features
      • Referencing Variables
      • Dynamic Assignment
      • Insights
    • Integrations
      • Alerts integration
        • Standard Alert Integration
        • Email Integration
        • Nightingale/FlashCat Integration
        • Prometheus Integration
        • Grafana Integration
        • Zabbix Integration
        • Uptime Kuma Integration
        • Alibaba Cloud ARMS Integration
        • Alibaba Cloud Monitor CM Event Integration
        • Alibaba Cloud Monitor CM Metrics Integration
        • Alibaba Cloud SLS Integration
        • AWS CloudWatch Integration
        • Azure Monitor Integration
        • Baidu Cloud BCM Integration
        • Huawei Cloud CES Integration
        • Influxdata Integration
        • Open Falcon Integration
        • PagerDuty Integration
        • Tencent BlueKing Integration
        • Tencent Cloud CLS Integration
        • Tencent Cloud Monitor CM Integration
        • Tencent Cloud EventBridge
        • OceanBase Integration
        • Graylog Integration
        • Skywalking Integration
        • Sentry Integration
        • Jiankongbao Integration
        • AWS EventBridge Integration
        • Dynatrace Integration
        • Huawei Cloud LTS Integration
        • GCP Integration
        • Splunk Alert Events Integration
        • AppDynamics Alert Integration
        • SolarWinds Alert Events Integration
        • Volcengine CM Alert Events Integration
        • Volcengine CM Event Center Integration
        • Volcengine TLS Integration
        • OpManager Integration
        • Meraki Integration
        • Keep Integration
        • ElastAlert2 Alert Integration
        • StateCloud Alert Events
        • Guance Alert Events
        • Zilliz Alert Events
        • Huawei Cloud APM Alerts
        • zstack integration
      • Change integration
        • Standard Change Event
        • Jira Issue Events
      • IM integration
        • Feishu (Lark) Integration Guide
        • Dingtalk Integration
        • WeCom Integration
        • Slack Integration
        • Microsoft Teams Integration
      • Single Sign-On
        • Authing Integration
        • Keycloak Guide
        • OpenLDAP Guide
      • Webhooks
        • Alert webhook
        • Incident webhook
        • Costom action
        • ServiceNow Sync
        • Jira Sync
      • Other
        • Link Integration
  • RUM
    • Getting Started
      • Introduction
      • Quick start
      • FAQ
    • Applications
      • Applications
      • SDK Integration
      • Advanced Configuration
      • Analysis Dashboard
    • Performance Monitoring
      • Overview
      • Metrics
      • Performance Analysis
      • Performance Optimize
    • Error Tracking
      • Overview
      • Error Reporting
      • Issues
      • Source Mapping
      • Error Grouping
      • Issue States
      • Issue Alerting
    • Session Replay
      • View Session Replay
      • Overview
      • SDK Configuration
      • Privacy Protection
    • Others
      • Terminology
      • Data Collection
      • Data Security
  • Platform
    • Teams and Members
    • Permissions
    • Single Sign-On
  • Terms
    • Terms of Service
    • User Agreement/Privary Policy
    • SLA
    • Data Security
  1. Session Replay

SDK Configuration

Overview#

Flashduty RUM's session replay functionality is integrated into the RUM SDK. By simply configuring sampling rates and privacy rules, you can quickly enable replay functionality.

Enable Collection#

Automatic Collection#

The replay SDK is already integrated into the RUM SDK. Configure the sampling rate to enable replay functionality.
提示
Sampling Method: When the client SDK initializes a session, it generates a random number between 0-1 and compares it with rate/100. If it falls within the range, that session will be collected as a sample, and replay data will be collected and reported within the session cycle.
Based on sampled session, the session will be
Based on the session being sampled, the session replay sampling rate (sessionReplaySampleRate) will be applied for a second round of calculation and sampling.
By default, after configuring the sampling rate, automatic collection will be enabled after RUM.init() is executed. If you want to manually control the collection timing (such as collecting data after user login), you can first enable the manual collection switch, then manually call the record method.
After enabling collection, you can stop collection using the stopSessionReplayRecording() method.

Force Enable#

In certain scenarios, even if the sampling rate is not hit, you may still want to collect data for that session (such as monitoring newly launched features, or capturing subsequent operations after an exception), you can force enable replay by calling the startSessionReplayRecording({ force: true }) method.
警告
Note: Force enable will only take effect when the current session is sampled but sessionReplay is not sampled. If the session itself is not sampled, even forcing replay enable will be ineffective.

Disable Collection#

If you need to disable the collection functionality, adjust the corresponding replay sampling rate to 0 or simply remove the configuration item.

How It Works#

The session replay SDK is implemented based on rrweb.
During the recording phase, the recording SDK takes snapshots of the current DOM and CSS styles, and collects corresponding events when user behaviors occur (DOM changes, mouse movements, clicks, form inputs, etc.). Data is reported after serialization, compression, and removal of sensitive information.
During the replay phase, the playback SDK reconstructs the DOM based on snapshots and converts event behaviors to DOM changes for display at appropriate times.
Before data reporting, the SDK performs data compression in advance and executes this CPU-intensive operation in a web worker, which does not affect main thread rendering.
The SDK compatibility is consistent with the RUM SDK, supporting browsers above IE11.

Next Steps#

View Session Replays
Learn About Privacy Protection Settings

添加官方技术支持微信

在这里,获得使用上的任何帮助,快速上手FlashDuty

微信扫码交流
修改于 2025-08-15 06:29:56
上一页
Overview
下一页
Privacy Protection
Built with