François Laignel
6163589ac7
ts/executor: replace tokio with smol-like implementation
...
The threadshare executor was based on a modified version of tokio
which implemented the throttling strategy in the BasicScheduler.
Upstream tokio codebase has significantly diverged from what it
was when the throttling strategy was implemented making it hard
to follow. This means that we can hardly get updates from the
upstream project and when we cherry pick fixes, we can't reflect
the state of the project on our fork's version. As a consequence,
tools such as cargo-deny can't check for RUSTSEC fixes in our fork.
The smol ecosystem makes it quite easy to implement and maintain
a custom async executor. This MR imports the smol parts that
need modifications to comply with the threadshare model and implements
a throttling executor in place of the tokio fork.
Networking tokio specific types are replaced with Async wrappers
in the spirit of [smol-rs/async-io]. Note however that the Async
wrappers needed modifications in order to use the per thread
Reactor model. This means that higher level upstream networking
crates such as [async-net] can not be used with our Async
implementation.
Based on the example benchmark with ts-udpsrc, performances seem on par
with what we achieved using the tokio fork.
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/118
Related to https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/604
2021-12-25 11:25:56 +00:00
François Laignel
db9c38aa93
ts/runtime: shuffle some structs to dedicated modules
2021-12-25 11:25:56 +00:00
François Laignel
c5ef83d5b0
ts/runtime: use a directory for executor module
...
This will ease the introduction of other concepts which are required
for our own executor implementation.
2021-12-25 11:25:56 +00:00
François Laignel
cd0773662f
ts: migrate most tests so that they don't use tokio
2021-12-25 11:25:56 +00:00
Guillaume Desmottes
bba26a9cf5
threadshare: remove unused import
2021-12-22 15:43:32 +01:00
Sebastian Dröge
66e987c174
Fix a couple of new clippy warnings
2021-12-02 22:31:52 +02:00
Sebastian Dröge
13923051a0
Fix compilation after gst::Pad::sticky_events_foreach
API changes
2021-12-01 15:33:45 +02:00
Sebastian Dröge
c46901d150
Fix or silence various new 1.57 clippy warnings
2021-11-30 16:31:50 +02:00
Sebastian Dröge
86f422592b
Update for glib::Enum
/ glib::Boxed
/ glib::flags!
macro renames
2021-11-22 11:04:26 +02:00
Sebastian Dröge
c68f6b2631
Update for GLib signal emit_by_name()
API changes
2021-11-21 18:15:04 +02:00
Sebastian Dröge
55aad51141
Update for glib constructor renames
...
See https://github.com/gtk-rs/gtk-rs-core/pull/384
2021-11-20 14:31:06 +02:00
François Laignel
53bfb58751
ts: update tokio fork for RUSTSEC-2021-0124
...
A data race condition was discovered in tokio, which can lead
to memory corruption. This vulnerability affects our fork.
See:
- https://rustsec.org/advisories/RUSTSEC-2021-0124
- https://github.com/tokio-rs/tokio/issues/4225
- https://github.com/tokio-rs/tokio/pull/4226
- https://github.com/fengalin/tokio/pull/1
Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/174
2021-11-17 14:51:03 +01:00
Sebastian Dröge
e3fbf2078d
Add new fmp4 plugin with muxers for ISO fragmented MP4, DASH and CMAF containers
2021-11-15 14:04:03 +02:00
Bilal Elmoussaoui
82be7b3ac5
adapt to ObjectExt improvements
2021-11-08 14:43:53 +02:00
Sebastian Dröge
d9bda62a47
Update for GLib/GStreamer API changes
...
And clean up a lot of related property/caps/structure code.
2021-11-06 09:34:10 +02:00
Sebastian Dröge
0a7d1639e7
Update to Rust edition 2021 and minimum supported Rust version to 1.56
2021-10-31 17:40:05 +02:00
Sebastian Dröge
b9541b2ca4
Update for GstObjectImpl API change
2021-10-23 12:31:33 +03:00
François Laignel
27b9f0d868
Improve usability thanks to opt-ops
...
The crate option-operations simplifies usage when dealing with
`Option`s, which is often the case with `ClockTime`.
2021-10-18 15:09:47 +02:00
Sebastian Dröge
6ec98ec5e4
Update to pretty-assertions 1.0
2021-10-14 10:20:19 +03:00
François Laignel
ed90b338f8
ts: runtime: add delay_for_at_least
...
The time driver for the threadshare runtime assigns the timer
entries to the nearest throttling time frame so that the timer
fires as close as possible to the expected instant. This means
that the timer might fire before or after the expected instant
(at most `wait / 2` away).
In some cases, we don't want the timer to fire early. The new
function `delay_for_at_least` ensures that the timer is assigned
to the time frame after the expected instant.
2021-09-30 09:00:05 +02:00
Sebastian Dröge
848b296390
Add capi feature to all plugin crates
...
This fixes the build with cargo-c 0.9.2.
2021-08-11 20:51:36 +03:00
Sebastian Dröge
052365ba1a
Fix various needless-borrow clippy warnings and others
2021-07-30 13:53:35 +03:00
Ruben Gonzalez
54d8c5f6a9
Delete minimum GStremer required version for some plugins
...
Tested building the pluging with cargo-c and running gst-inspect-1.0
in a Ubuntu Xenial 18.04 LTS. It contains GStreamer 1.8.3.
2021-07-20 21:49:24 +02:00
Sebastian Dröge
24ec79cd1a
Update versions to 0.8.0 for the master branch
2021-07-09 13:49:33 +03:00
Sebastian Dröge
1c3ae0f89a
Update versions to 0.7.0
2021-07-09 13:49:21 +03:00
François Laignel
5439f14e57
fix clippy warnings
2021-06-05 10:36:22 +02:00
François Laignel
8f81cb8812
generic: migrate to new ClockTime design
2021-06-05 10:36:21 +02:00
François Laignel
8dfc872544
use gst::glib where applicable
2021-06-03 20:53:16 +02:00
Sebastian Dröge
94f75c29a1
threadshare: Use appsink callbacks instead of signals in the tests
2021-05-31 10:33:50 +03:00
Sebastian Dröge
04a60b8f46
Update repository URL for gtk-rs "core" crates
2021-05-13 09:50:08 +03:00
Sebastian Dröge
97b6a9099f
file: Don't use Url::into_string() anymore but the generic Into trait
...
The former is deprecated now.
2021-05-08 09:41:30 +03:00
Sebastian Dröge
ee0b2e79da
threadshare: Fix compilation after cleanup in the glib bindings
2021-05-07 10:24:45 +03:00
Bilal Elmoussaoui
78d9fb521d
rename ToGlib into IntoGlib
2021-04-27 20:45:47 +02:00
Sebastian Dröge
15cf738616
Update for Value trait refactoring
2021-04-25 15:48:55 +03:00
François Laignel
95cdd43f4f
manual fixes remove get prefix round 2
2021-04-20 18:19:58 +02:00
François Laignel
67c5871957
fix-getters-calls 0.3.0 pass
2021-04-20 18:19:58 +02:00
François Laignel
27bc5c89ca
fix-getters-def 0.3.0 pass
2021-04-20 18:19:58 +02:00
François Laignel
c81213b83c
clippy pass
2021-04-13 17:24:20 +02:00
François Laignel
7d17f88941
post fix-getters manual updates
2021-04-13 17:24:20 +02:00
François Laignel
06accc8d98
fix-getters-{def,calls} pass
2021-04-12 15:57:19 +02:00
Sebastian Dröge
5e89d345d8
sodium: Pass &Path instead of &PathBuf
2021-03-25 20:26:15 +02:00
Sebastian Dröge
b919d226b1
threadshare: Update to socket2 0.4
2021-03-21 12:57:10 +02:00
Sebastian Dröge
2cada57efc
Update for the subclassing glib/gstreamer bindings API changes
2021-03-09 17:07:13 +02:00
Sebastian Dröge
aa354058f5
Update pretty-assertions to 0.7, async-tungstenite to 0.13 and num-rational to 0.4
...
Also get rid of the funty workaround as nom now depends on the right
version.
2021-03-09 11:42:33 +02:00
Sebastian Dröge
39a75632c8
threadshare: Update for glib subclass API cleanups
2021-03-08 12:50:03 +02:00
Sebastian Dröge
dc0c5f7611
Update for new #[glib::object_subclass] attribute macro
2021-03-07 18:27:00 +02:00
Sebastian Dröge
5dd0a23986
threadshare: Update for glib::Type API changes
2021-02-25 13:12:12 +02:00
Sebastian Dröge
0616c18703
Update for changed GLib signals API
2021-02-22 17:20:40 +02:00
Sebastian Dröge
cbda137fbf
Fix various warnings from clippy 1.50
2021-02-09 18:57:34 +02:00
Sebastian Dröge
b649e9b076
Use gst::PARAM_FLAG_MUTABLE_PLAYING and others consistently everywhere
...
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/139
2021-01-31 15:43:00 +02:00