Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DVR: Obtain complex recording rules for a specific stream from the API, with dvr_apply being the fixed rule. #2181

Closed
houxuexianhan opened this issue Feb 1, 2021 · 7 comments
Assignees
Labels
DVR DVR to FLV or MP4. Feature It's a new feature. TransByAI Translated by AI/GPT.
Milestone

Comments

@houxuexianhan
Copy link

houxuexianhan commented Feb 1, 2021

Description

dvr_apply does not support wildcards. When dvr_apply is configured for a specific stream, the custom output file path does not take effect.

  1. SRS Version: v3.0.155
  2. SRS Log:

(Note: Please provide the actual logs for accurate translation)


xxxxxxxxxxxx

Config for SRS:

Please provide the specific configuration for SRS.


 dvr{
  	enabled         on;
	dvr_apply	dvr/a
	dvr_path	/var/www/html/[app]/[stream].[2006][01][02][15][04][05][999].mp4;
	dvr_plan	session;
	dvr_duration	30;
	dvr_wait_keyframe       on;
	time_jitter             full; 
    }


Expected Behavior

It is desired to have support for wildcard configuration like live/* in dvr_apply.
Once dvr_apply is configured for a specific stream, the recording file path should be effective according to dvr_path.

TRANS_BY_GPT3

@winlinvip winlinvip changed the title v3.0.155 dvr_apply不支持通配符。当配置了dvr_apply为某个流之后,自定义输出的文件保存路径不生效。 DVR:支持通配符。当配置了dvr_apply为某个流之后,自定义输出的文件保存路径不生效。 Feb 28, 2021
@winlinvip winlinvip added the Feature It's a new feature. label Feb 28, 2021
@robertluoxu
Copy link

robertluoxu commented May 19, 2021

I hope the DVR path can support online OSS storage.

TRANS_BY_GPT3

@winlinvip
Copy link
Member

winlinvip commented Aug 22, 2021

Regarding supporting cloud storage, refer to #1193.

Hope the DVR path can support online OSS storage.

TRANS_BY_GPT3

@winlinvip winlinvip self-assigned this Aug 22, 2021
@winlinvip
Copy link
Member

winlinvip commented Aug 22, 2021

Previously, it was accomplished through configuring dvr_apply, but this method cannot handle complex matching and is only suitable for fixed rule matching, which is prone to problems #2282.

For complex matching, such as wildcard or dynamic adjustment needs, it is better to call the HTTP API to determine whether to record a certain stream, for example:

dvr_filter http://xxx

Note: Please note that this dvr_filter needs to be implemented by your own service, not by SRS.

By requesting this API, it returns whether to record this stream and some necessary configurations.

This way, you don't have to rely on SRS to perform complex recording logic.

TRANS_BY_GPT3

@winlinvip winlinvip added this to the SRS 5.0 release milestone Aug 26, 2021
@winlinvip winlinvip changed the title DVR:支持通配符。当配置了dvr_apply为某个流之后,自定义输出的文件保存路径不生效。 DVR:从API获取某个流是否应该录制 Aug 30, 2021
@winlinvip winlinvip assigned xiaozhihong and unassigned winlinvip Aug 30, 2021
@winlinvip winlinvip changed the title DVR:从API获取某个流是否应该录制 DVR:从API获取某个流是否应该录制,而不通过配置dvr_apply Aug 30, 2021
@winlinvip winlinvip added the DVR DVR to FLV or MP4. label Aug 30, 2021
@winlinvip winlinvip changed the title DVR:从API获取某个流是否应该录制,而不通过配置dvr_apply DVR:从API获取某个流的复杂的录制规则,dvr_apply作为简单的过滤规则 Aug 30, 2021
@winlinvip winlinvip changed the title DVR:从API获取某个流的复杂的录制规则,dvr_apply作为简单的过滤规则 DVR:从API获取某个流的复杂的录制规则,dvr_apply作为固定的规则 Aug 30, 2021
@lxge
Copy link

lxge commented Sep 22, 2021

dvr_filter

Hello, may I ask how to dynamically configure 4.0, adjust the recording time period? After calling the raw API and getting a return code of 0, there is no actual effect.

TRANS_BY_GPT3

@guoronghui
Copy link

guoronghui commented Feb 15, 2022

4.0 no longer supports RAW API recording, right?

TRANS_BY_GPT3

@winlinvip
Copy link
Member

winlinvip commented Feb 16, 2022

Essentially, what everyone wants is dynamic recording, where they can decide whether or not to record the stream and how to do it based on their own business needs.

The RAW API can only achieve very limited capabilities and has many issues, which is why this solution has been removed.

The alternative solution is a dynamic Forward-like approach, which can be referenced at: #1342

Dynamic Forward support has been quickly implemented and dynamic DVR will be done in the future.

TRANS_BY_GPT3

@winlinvip
Copy link
Member

winlinvip commented Feb 16, 2022

Dup to #1577

Duplicate Issue, I have closed this one.

TRANS_BY_GPT3

peipeiguo added a commit to peipeiguo/srs that referenced this issue Sep 7, 2022
@winlinvip winlinvip added the TransByAI Translated by AI/GPT. label Jul 25, 2023
@winlinvip winlinvip changed the title DVR:从API获取某个流的复杂的录制规则,dvr_apply作为固定的规则 DVR: Obtain complex recording rules for a specific stream from the API, with dvr_apply being the fixed rule. Jul 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DVR DVR to FLV or MP4. Feature It's a new feature. TransByAI Translated by AI/GPT.
Projects
None yet
Development

No branches or pull requests

6 participants