Skip to content

SRS HTTP callback does not support WEBRTC streaming. #2498

@CNWenwuGong

Description

@CNWenwuGong

Description'

Please ensure that the markdown structure is maintained.

SRS HTTP callback does not support WEBRTC streaming'

Please ensure that the markdown structure is maintained.

  1. SRS version: 4.0
  2. The log for SRS is as follows:

Please ensure that the markdown structure is maintained.

xxxxxxxxxxxx
  1. The configuration for SRS is as follows:

Please ensure that the markdown structure is maintained.

listen              1935;
max_connections     1000;
daemon              on;
srs_log_tank        console;
srs_log_file        ./objs/srs.log;

http_server {
    enabled         on;
    listen          8080;
    dir             ./objs/nginx/html;
}

http_api {
    enabled         on;
    listen          1985;
}
stats {
    network         0;
    disk            sda sdb xvda xvdb;
}
rtc_server {
    enabled on;
    # Listen at udp://8000
    listen 8000;
    #
    # The $CANDIDATE means fetch from env, if not configed, use * as default.
    #
    # The * means retrieving server IP automatically, from all network interfaces,
    # @see https://github.com/ossrs/srs/wiki/v4_CN_RTCWiki#config-candidate
    candidate 172.16.31.10;
}

vhost __defaultVhost__ {
    rtc {
        enabled     on;
    }
    #http_remux {
     #   enabled     on;
     #   mount       [vhost]/[app]/[stream].flv;
    #}
    http_hooks {
	enabled         on;
        on_stop    http://172.16.31.96:9040/webapi/video/stopVideo;
    }

# Minimum Delay Open, by default it is enabled. When this option is enabled, MR is disabled by default.

Please ensure that the markdown structure is maintained.
    min_latency     on;
# Merged-Read, for the RTMP protocol, in order to improve performance, SRS uses merged-read for upstream reads, which means SRS reads N milliseconds of data at a time during read and write operations.

Please ensure that the markdown structure is maintained.
    mr {
        enabled     off;
# The default value is 350ms, with a range of [300-2000].

Please ensure that the markdown structure is maintained.
        #latency     350;
    }
# Merged-Write, SRS always uses Merged-Write, which means sending packets to the client once every N milliseconds. This algorithm can improve the efficiency of RTMP downstream by about 5 times, with a range of [350-1800].

Please ensure that the markdown structure is maintained.
    mw_latency      100;
    #enabled         on;
    #https://github.com/simple-rtmp-server/srs/wiki/v2_CN_LowLatency#gop-cache
    gop_cache       off;
# Configure the length of the live queue. The server will store data in the live queue, and if it exceeds this length, it will be cleared until the last I-frame.

Please ensure that the markdown structure is maintained.
    #https://github.com/simple-rtmp-server/srs/wiki/v2_CN_LowLatency#%E7%B4%AF%E7%A7%AF%E5%BB%B6%E8%BF%9F
    queue_length    10;
# HTTP-FLV Configuration

Please ensure that the markdown structure is maintained.
    http_remux {
        enabled     on;
        mount [vhost]/[app]/[stream].flv;
        hstrs   on;
    }

    tcp_nodelay     on
    min_latency     on;

    play {
        gop_cache       off;
        queue_length    10;
        mw_latency      100;
    }

    publish {
        mr off;
    }


}

Replay

Please ensure that the markdown structure is maintained.

How to replay bug?

Please ensure that the markdown structure is maintained.

Steps to replay the bug:

  1. Start SRS.
  2. Use FFmpeg command to push stream to SRS.
  3. Play the stream in SRS player using RTC, then close the browser or refresh the page.

Please ensure that the markdown structure is maintained.

Expected behavior:

Please ensure that the markdown structure is maintained.

Expected behavior:

I hope that the set HTTP callback will be called when stopping the video streaming.

Please ensure that the markdown structure is maintained.

TRANS_BY_GPT3

Metadata

Metadata

Labels

DiscussionDiscussion or questions.FeatureIt's a new feature.TransByAITranslated by AI/GPT.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions