1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-02-13 20:01:56 +00:00

add todo for reload the source components.

This commit is contained in:
winlin 2015-08-25 22:59:17 +08:00
parent 53f4ce3604
commit cdde293785

View file

@ -1161,6 +1161,8 @@ int SrsSource::on_reload_vhost_forward(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
// forwarders
destroy_forwarders();
if ((ret = create_forwarders()) != ERROR_SUCCESS) {
@ -1181,6 +1183,8 @@ int SrsSource::on_reload_vhost_hls(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
#ifdef SRS_AUTO_HLS
hls->on_unpublish();
if ((ret = hls->on_publish(_req)) != ERROR_SUCCESS) {
@ -1201,6 +1205,8 @@ int SrsSource::on_reload_vhost_hds(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
#ifdef SRS_AUTO_HDS
hds->on_unpublish();
if ((ret = hds->on_publish(_req)) != ERROR_SUCCESS) {
@ -1221,6 +1227,8 @@ int SrsSource::on_reload_vhost_dvr(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
#ifdef SRS_AUTO_DVR
// cleanup dvr
dvr->on_unpublish();
@ -1250,6 +1258,8 @@ int SrsSource::on_reload_vhost_transcode(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
#ifdef SRS_AUTO_TRANSCODE
encoder->on_unpublish();
if ((ret = encoder->on_publish(_req)) != ERROR_SUCCESS) {
@ -1270,6 +1280,8 @@ int SrsSource::on_reload_vhost_exec(string vhost)
return ret;
}
// TODO: FIXME: maybe should ignore when publish already stopped?
ng_exec->on_unpublish();
if ((ret = ng_exec->on_publish(_req)) != ERROR_SUCCESS) {
srs_error("start exec failed. ret=%d", ret);