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

BUG: paths/all configurations don't apply to paths created by HTTP API #1853

Closed
1 of 13 tasks
hu-xd opened this issue May 22, 2023 · 3 comments · Fixed by #1905
Closed
1 of 13 tasks

BUG: paths/all configurations don't apply to paths created by HTTP API #1853

hu-xd opened this issue May 22, 2023 · 3 comments · Fixed by #1905
Labels
bug Something isn't working general

Comments

@hu-xd
Copy link

hu-xd commented May 22, 2023

Which version are you using?

v0.23.2
it seems like v0.22.2 didn't have this problem

Which operating system are you using?

  • Linux amd64 standard
  • Linux amd64 Docker
  • Linux arm64 standard
  • Linux arm64 Docker
  • Linux arm7 standard
  • Linux arm7 Docker
  • Linux arm6 standard
  • Linux arm6 Docker
  • Windows amd64 standard
  • Windows amd64 Docker (WSL backend)
  • macOS amd64 standard
  • macOS amd64 Docker
  • Other (please describe)

Describe the issue

if a path is created by HTTP API /v2/config/paths/add/{name}
the config of this path is initialized as default values, ignoring the config in the paths/all section in the .yml file
especially, the sourceOnDemandStartTimeout are 0s, this makes the path essentially unusable,
since the source connection is closed immediately after connected

Describe how to replicate the issue

  1. start the server
  2. create a path using HTTP API /v2/config/paths/add/test
    { “source”: "rtsp://......" }
  3. read paths info with HTTP API /v2/paths/list
  4. see the sourceOnDemandStartTimeout config of "test" is 0s
  5. open mediamtx.yml file
  6. see the sourceOnDemandStartTimeout config under paths/all section is 10s

Did you attach the server logs?

no

Did you attach a network dump?

no

@aler9
Copy link
Member

aler9 commented Jun 2, 2023

Hello, config parameters under path "all" are not applied to other paths, as mentioned in the configuration file:

The settings under the path "all" are applied to all paths that do not match another entry.

Nonetheless, 10s is the default value of sourceOnDemandStartTimeout, and default values should be applied to API-created paths too, while they are not, and this is a bug.

@aler9 aler9 added bug Something isn't working general labels Jun 2, 2023
aler9 added a commit that referenced this issue Jun 2, 2023
this fixes a regression introduced in v0.23.0.
aler9 added a commit that referenced this issue Jun 2, 2023
@aler9
Copy link
Member

aler9 commented Jun 2, 2023

fixed in v0.23.4

Copy link
Contributor

github-actions bot commented Dec 6, 2023

This issue is being locked automatically because it has been closed for more than 6 months.
Please open a new issue in case you encounter a similar problem.

@github-actions github-actions bot locked and limited conversation to collaborators Dec 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working general
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants