Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Neto committed Jan 22, 2024
1 parent 51c1553 commit a5bac95
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 17 deletions.
1 change: 1 addition & 0 deletions objects/Object.php
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,7 @@ static function ignoreTableSecurityCheck()
'audit',
'wallet_log',
'live_restreams_logs',
'live_transmitions',
'clone_SitesAllowed',
'user_notifications',
'email_to_user',
Expand Down
5 changes: 2 additions & 3 deletions plugin/Live/install/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ worker_processes 1;
rtmp {
server {
listen 1935;
buflen 1000ms;
chunk_size 4096;
ping_timeout 30s;
ping 5m;
ping_timeout 4m;
### Use case option (max_streams; default is 32 )
#max_streams 10;
allow play all;
Expand Down
32 changes: 18 additions & 14 deletions plugin/PlayLists/PlayLists.php
Original file line number Diff line number Diff line change
Expand Up @@ -1040,20 +1040,24 @@ public function on_publish_done($live_transmitions_history_id, $users_id, $key,
$key = $lt->getKey();
_error_log("on_publish_done key={$key} live_transmitions_history_id={$live_transmitions_history_id} ");
$isPlayListScheduled = Playlists_schedules::iskeyPlayListScheduled($key);
$pls = new Playlists_schedules($isPlayListScheduled['playlists_schedules']);
if ($pls->getFinish_datetime() > time()) {
$ps = Playlists_schedules::getPlaying($isPlayListScheduled['playlists_schedules']);
$pl = new PlayList($ps->playlists_id);
$title = $pl->getName() . ' [' . $ps->msg . ']';
Rebroadcaster::rebroadcastVideo(
$ps->current_videos_id,
$pl->getUsers_id(),
Playlists_schedules::getPlayListScheduledIndex($isPlayListScheduled['playlists_schedules']),
$title
);
} else {
_error_log("on_publish_done is complete {$pls->getFinish_datetime()} < " . time() . " | " . date('Y/m/d H:i:s', $pls->getFinish_datetime()) . ' < ' . date('Y/m/d H:i:s', time()));
self::setScheduleStatus($key, Playlists_schedules::STATUS_COMPLETE);
if(!empty($isPlayListScheduled['playlists_schedules'])){
$pls = new Playlists_schedules($isPlayListScheduled['playlists_schedules']);
if ($pls->getFinish_datetime() > time()) {
$ps = Playlists_schedules::getPlaying($isPlayListScheduled['playlists_schedules']);
$pl = new PlayList($ps->playlists_id);
$title = $pl->getName() . ' [' . $ps->msg . ']';
Rebroadcaster::rebroadcastVideo(
$ps->current_videos_id,
$pl->getUsers_id(),
Playlists_schedules::getPlayListScheduledIndex($isPlayListScheduled['playlists_schedules']),
$title
);
} else {
_error_log("on_publish_done is complete {$pls->getFinish_datetime()} < " . time() . " | " . date('Y/m/d H:i:s', $pls->getFinish_datetime()) . ' < ' . date('Y/m/d H:i:s', time()));
self::setScheduleStatus($key, Playlists_schedules::STATUS_COMPLETE);
}
}else{
_error_log("on_publish_done is complete isPlayListScheduled=".json_encode($isPlayListScheduled));
}
}

Expand Down

0 comments on commit a5bac95

Please sign in to comment.