mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
For RTMP edge/forward, pass vhost in tcUrl, not in stream. 3.0.156
This commit is contained in:
parent
4d18835f3c
commit
6e43ef6866
8 changed files with 38 additions and 29 deletions
|
@ -124,8 +124,10 @@ srs_error_t SrsEdgeRtmpUpstream::connect(SrsRequest* r, SrsLbRoundRobin* lb)
|
|||
if ((err = sdk->connect()) != srs_success) {
|
||||
return srs_error_wrap(err, "edge pull %s failed, cto=%dms, sto=%dms.", url.c_str(), srsu2msi(cto), srsu2msi(sto));
|
||||
}
|
||||
|
||||
if ((err = sdk->play(_srs_config->get_chunk_size(req->vhost))) != srs_success) {
|
||||
|
||||
// For RTMP client, we pass the vhost in tcUrl when connecting,
|
||||
// so we publish without vhost in stream.
|
||||
if ((err = sdk->play(_srs_config->get_chunk_size(req->vhost), false)) != srs_success) {
|
||||
return srs_error_wrap(err, "edge pull %s stream failed", url.c_str());
|
||||
}
|
||||
|
||||
|
@ -504,8 +506,10 @@ srs_error_t SrsEdgeForwarder::start()
|
|||
if ((err = sdk->connect()) != srs_success) {
|
||||
return srs_error_wrap(err, "sdk connect %s failed, cto=%dms, sto=%dms.", url.c_str(), srsu2msi(cto), srsu2msi(sto));
|
||||
}
|
||||
|
||||
if ((err = sdk->publish(_srs_config->get_chunk_size(req->vhost))) != srs_success) {
|
||||
|
||||
// For RTMP client, we pass the vhost in tcUrl when connecting,
|
||||
// so we publish without vhost in stream.
|
||||
if ((err = sdk->publish(_srs_config->get_chunk_size(req->vhost), false)) != srs_success) {
|
||||
return srs_error_wrap(err, "sdk publish");
|
||||
}
|
||||
|
||||
|
@ -515,7 +519,7 @@ srs_error_t SrsEdgeForwarder::start()
|
|||
if ((err = trd->start()) != srs_success) {
|
||||
return srs_error_wrap(err, "coroutine");
|
||||
}
|
||||
srs_trace("edge-fwr publish url %s", url.c_str());
|
||||
srs_trace("edge-fwr publish url %s, stream=%s%s", url.c_str(), req->stream.c_str(), req->param.c_str());
|
||||
|
||||
return err;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue