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

Process update via API causes process metadata to become unavailable #698

Open
hrtkpf opened this issue Feb 25, 2024 · 2 comments
Open

Process update via API causes process metadata to become unavailable #698

hrtkpf opened this issue Feb 25, 2024 · 2 comments
Labels
bug Program error or software error or software anomaly.

Comments

@hrtkpf
Copy link

hrtkpf commented Feb 25, 2024

Hey,

I have create a process via the Web UI. I am now trying to dynamically update its network source via the API. For that, I am using a minimal config which only includes the things I need to be updated, i.e. the source address. All other properties should remain unchanged.

However, after the config update is sent via the /api/v3/process/{processId} endpoint, its metadata seems to be removed. This becomes visible in the Web UI: When trying to edit the process, no data is available (no network sources, no metadata etc.). The stream name then displays as "Main Channel" instead of the actual name.
The DevTools show that a request to /api/v3/process/restreamer-ui%3Aingest%3A9f61f582-f7b3-46c0-9d1f-e4da4397fb6d/metadata/restreamer-ui returns 404 (this request should return the metadata).

The actual network source update works and the stream automatically reloads the source, just the metadata seems to be missing after the update.

I am using datarhei-core v16.14.0 (linux/arm64) / 2.8.0 / 2024-02-02 in a container.

To Reproduce
Steps to reproduce the behavior:

  1. Create a new process via the Web UI
  2. Update the process via the /api/v3/process/{processId} endpoint using a minimal config. The API call can easily be reproduced using curl: curl -X PUT "https://restreamer/api/v3/process/restreamer-ui:ingest:9f61f582-f7b3-46c0-9d1f-e4da4397fb6d" -H "Content-Type: application/json" -H "Authorization: Bearer $JWT" -d '{"id":"restreamer-ui:ingest:9f61f582-f7b3-46c0-9d1f-e4da4397fb6d","input":[{"address":"https://new-network-source"}]}'. Omitting the ID in the config update results in the same situation. Using a non-minimal config with just the network source changed also causes the same issue.

Expected behavior
The process metadata should remain available after the update and the Web UI should show the current stream source and metadata (name, author, license etc.).

@hrtkpf hrtkpf added the bug Program error or software error or software anomaly. label Feb 25, 2024
@hrtkpf
Copy link
Author

hrtkpf commented Feb 25, 2024

Related: #668

@ioppermann
Copy link
Member

This bug has been fixed in the dev branch. You can pull the datarhei/restreamer:dev docker image to test it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Program error or software error or software anomaly.
Projects
None yet
Development

No branches or pull requests

2 participants