هذه الصفحة غير متوفرة حاليًا بلغتك المحلية. نحن نعمل جاهدين على إضافة المزيد من اللغات. شاكرين تفهمك ودعمك المستمر لنا.

Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ SparkRTC/ User Guide/ Cloud Recording Management/ Configuring a Recording Rule

Configuring a Recording Rule

Updated on 2023-10-16 GMT+08:00

SparkRTC records real-time communication content and stores the recordings in OBS buckets. You can download and share the recordings in OBS. Figure 1 shows the operation process.

Figure 1 Recording process
  1. Create an OBS bucket for storing recordings. If you already have one, go to 2.
  2. Authorize SparkRTC to store recordings in the bucket.
  3. Configure a recording rule for real-time communication. Then you can use the recording rule ID to start a recording task. The recording will be stored in OBS based on the recording settings. You can set a callback URL to obtain notifications about the recording status.
  4. Record content of real-time communication. You can call SparkRTC APIs to start, query, and control cloud recording tasks. SparkRTC performs single-stream recording on images based on the recording rule ID in the API calling request.
  5. View recordings. After the recording is complete, you can receive the callback message of the recording task in the configured callback URL. You can obtain the basic information about the recordings and manage the recordings in OBS, such as downloading, sharing, and deleting them.
    NOTE:

    The resolution of recordings is the same as that of the pushed streams.

Notes

  • Only one recording rule can be configured for an app in each region.
  • Recording will fail if OBS is suspended due to arrears. Ensure that OBS is running properly before starting the recording.
  • Ensure that OBS is not suspended due to arrears. Otherwise, recording will fail. You are advised to buy an OBS package.

Prerequisites

Billing

  • Recording is a billing item based on the total duration of recordings. For details, see SparkRTC Pricing Details.
  • Recordings are stored in OBS buckets. Therefore, OBS charges you for the storage. For details, see OBS Pricing Details.

Step 1: Create an OBS Bucket

If you do not have an OBS bucket for storing recording files, create a bucket by referring to OBS Documentation. If you already have one, go to Step 2: Authorize Access to the OBS Bucket.

NOTICE:

Currently, recordings can be stored only in OBS buckets in CN North-Beijing4.

Step 2: Authorize Access to the OBS Bucket

Authorize SparkRTC to store recordings in OBS buckets. For details, see OBS Authorization.

Step 3: Configure a Recording Rule

  1. Log in to the SparkRTC console.
  2. In the navigation pane, choose Apps.
  3. Click Configure in the row of the app for which a recording callback needs to be created.

    The Configuration page is displayed.

  4. In the Recording Rule area, click Add. The Add Recording Rule page is displayed.
    NOTE:

    Only one recording rule can be configured for an app in each region.

  5. Configure recording parameters according to Table 1.
    Table 1 Recording parameters

    Parameter

    Description

    Storage Bucket

    OBS bucket where the recording is stored.

    Currently, recorded files can be stored only in OBS buckets of CN North-Beijing4.

    Region

    Region where the OBS bucket is deployed.

    Storage Path

    Path of the OBS bucket where the recording is stored.

    Record As

    Recording format, which can be HLS and MP4.

    HLS

    File Naming

    Storage path and filename prefix of M3U8 files.

    Default format:
    {app_id}/{record_format}/{stream}_{file_start_time}/{stream}_{file_start_time}

    The meanings of the preceding variables are as follows:

    • app_id: app ID
    • record_format: recording format
    • stream: stream name
    • file_start_time: file generation time

    Recording Length

    The recording length can be 0 or 1 to 720 minutes (12 hours). If a stream has been recorded for more than 12 hours, another file will be created based on the naming rule. If the recording length is 0, the entire stream is recorded as a file.

    Max Stream Pause Length

    Values:

    • Generate a new file when a stream is paused
    • Do not generate a new file when a stream is paused: The maximum stream pause length is 30 days.
    • Other: If the stream pause length is within the specified range, the system does not generate a new file. Otherwise, a new file is generated.

    MP4

    File Naming

    Storage path and filename prefix of MP4 files.

    Default format:
    {app_id}/{record_format}/{stream}_{file_start_time}/{stream}_{file_start_time}

    The meanings of the preceding variables are as follows:

    • app_id: app ID
    • record_format: recording format
    • stream: stream name
    • file_start_time: file generation time

    Recording Length

    The recording length ranges from 1 to 180 minutes (3 hours). If a stream has been recorded for more than 3 hours, another file will be created based on the naming rule.

    Max Stream Pause Length

    Values:

    • Generate a new file when a stream is paused
    • Other: If the stream pause length is within the specified range, the system does not generate a new file. Otherwise, a new file is generated.
  6. Click OK.

  7. In the recording rule list, enable automatic recording as required. When automatic recording is enabled, if a new room is created under the app, the system automatically performs single-stream recording during real-time communication in the room based on the configured recording rule.
    NOTE:

    Automatic recording takes effect only for rooms created under the app after you enable it.

Step 4: Record Content

After the recording rule is configured, call the SparkRTC APIs to start a cloud recording task. SparkRTC records real-time audio and video content based on the recording rule ID in the API calling request.

Step 5: View Recordings

When the recording is complete, view recordings on the OBS console or through callback messages.

  • Viewing recordings on the OBS console
    1. In the navigation pane of the OBS console, choose Object Storage.
    2. In the bucket list, click the bucket that stores SparkRTC recordings.

      The Overview page is displayed.

    3. In the navigation pane, choose Objects to view the recording information.
    4. Download and share the recordings as required. For details, see OBS Documentation.
  • Viewing recordings through callback messages

    If you configure a recording callback URL, you will receive a recording callback message each time a recording is generated. For details about the configuration method and message fields, see Configuring Recording Callback.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback