This can easily lead to deadlocks. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8933>