mirror of
				https://github.com/ossrs/srs.git
				synced 2025-03-09 15:49:59 +00:00 
			
		
		
		
	add todo for reload the source components.
This commit is contained in:
		
							parent
							
								
									53f4ce3604
								
							
						
					
					
						commit
						cdde293785
					
				
					 1 changed files with 12 additions and 0 deletions
				
			
		| 
						 | 
				
			
			@ -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);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue