Skip to content

Bump songbird from 0.3.2 to 0.4.0#191

Open
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/cargo/songbird-0.4.0
Open

Bump songbird from 0.3.2 to 0.4.0#191
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/cargo/songbird-0.4.0

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot Bot commented on behalf of github Dec 4, 2023

Bumps songbird from 0.3.2 to 0.4.0.

Release notes

Sourced from songbird's releases.

v0.4.0 — Nightingale

Possessing a beautiful, creative, and evocative song through both night and day, the humble Nightingale has long been seen as a symbol of poetry and love.

In keeping with the spirit of this release's passerine of choice, songbird now sings more melodiously than ever! This release has been a long time coming, and as such Nightingale brings several huge changes to how songbird is used and how it performs.


The largest change by far is a complete overhaul of all code relating to audio decoding, mixing, and loading from different locations, driven by Symphonia. Broadly, this means that we handle every part of the audio pipeline in-process and ffmpeg is entirely removed, saving significant memory and CPU and letting you scale to more voice calls on one box. Another boon is that reading in-memory audio now Just Works: if you can treat it as a &[u8], then you're good to go! Having this level of control also lets us expand our list of file-formats supporting direct Opus passthrough to include Ogg Opus and WebM/MKV, as well as the DCA format. Given that many sites will serve WebM, this is a significant saving on CPU time for many playback use cases. Additionally, we now handle HTTP reconnection logic internally, offering more reliable behaviour than certain downloader -> ffmpeg process chains would provide. Symphonia format support is significant, and you can enable and disable exactly the codecs and containers you need at compile-time.

Voice receive has been given its own fair share of improvements. Most importantly, all receive sessions now make use of per-user jitter bufferssongbird will now delay decoding of all users to correctly reorder audio packets, smooth out network latency jitter, and to help synchronize playback of several speakers. Receive functionality is now feature-gated and disabled by default, and so won't affect compile-time or runtime performance if you don't want to make use of it.

Finally, songbird now includes a new deadline-aware audio scheduler, which will pack as many concurrent Calls as possible onto a single thread. Compared to the previous model we now reduce thread counts, CPU use, and context switching – for context, up to 660 live Opus-passthrough-enabled calls can run on a single thread on a Ryzen 5700X. This is also helped by how we now park all Calls without any active Tracks onto a single shared event handling async task.


All in all, we're really excited to see what you build with these new tools and performance improvements.

Thanks to the following for their contributions:

Upgrade Pathway

Inputs:

  • ytdl etc. are removed and replaced with new lazy initialisers – read the docs on how to create sources from a URL or local path.
  • All inputs are now lazy by default, so Restartable is no longer needed.
  • Inputs can no longer directly output raw audio, as symphonia must always parse a container/codec pair. We've included a custom RawReader container format and the RawAdapter transform to support this.
  • Metadata is now split according to what you can learn when creating a source (AuxMetadata, e.g. info learned from a web scrape) and what metadata is encoded in a track itself (Metadata). Metadata can only be read once a track is fully initialised and parsed.
  • Songbird can now better encode an audio source's lifecycle from uninitialised, to readable, to having its headers fully parsed. Read the examples on how they can be manipulated, particularly if you want to make use of metadata.
  • Songbird's audio systems have undergone the most change in this release, so this list is non-exhaustive.

... (truncated)

Changelog

Sourced from songbird's changelog.

[0.4.0] — 2023-11-27 — Nightingale

Possessing a beautiful, creative, and evocative song through both night and day, the humble Nightingale has long been seen as a symbol of poetry and love.

In keeping with the spirit of this release's passerine of choice, songbird now sings more melodiously than ever! This release has been a long time coming, and as such Nightingale brings several huge changes to how songbird is used and how it performs.


The largest change by far is a complete overhaul of all code relating to audio decoding, mixing, and loading from different locations, driven by Symphonia. Broadly, this means that we handle every part of the audio pipeline in-process and ffmpeg is entirely removed, saving significant memory and CPU and letting you scale to more voice calls on one box. Another boon is that reading in-memory audio now Just Works: if you can treat it as a &[u8], then you're good to go! Having this level of control also lets us expand our list of file-formats supporting direct Opus passthrough to include Ogg Opus and WebM/MKV, as well as the DCA format. Given that many sites will serve WebM, this is a significant saving on CPU time for many playback use cases. Additionally, we now handle HTTP reconnection logic internally, offering more reliable behaviour than certain downloader -> ffmpeg process chains would provide. Symphonia format support is significant, and you can enable and disable exactly the codecs and containers you need at compile-time.

Voice receive has been given its own fair share of improvements. Most importantly, all receive sessions now make use of per-user jitter bufferssongbird will now delay decoding of all users to correctly reorder audio packets, smooth out network latency jitter, and to help synchronize playback of several speakers. Receive functionality is now feature-gated and disabled by default, and so won't affect compile-time or runtime performance if you don't want to make use of it.

Finally, songbird now includes a new deadline-aware audio scheduler, which will pack as many concurrent Calls as possible onto a single thread. Compared to the previous model we now reduce thread counts, CPU use, and context switching – for context, up to 660 live Opus-passthrough-enabled calls can run on a single thread on a Ryzen 5700X. This is also helped by how we now park all Calls without any active Tracks onto a single shared event handling async task.


All in all, we're really excited to see what you build with these new tools and performance improvements.

Thanks to the following for their contributions:

Upgrade Pathway

Inputs:

  • ytdl etc. are removed and replaced with new lazy initialisers – read the docs on how to create sources from a URL or local path.
  • All inputs are now lazy by default, so Restartable is no longer needed.
  • Inputs can no longer directly output raw audio, as symphonia must always parse a container/codec pair. We've included a custom RawReader container format and the RawAdapter transform to support this.
  • Metadata is now split according to what you can learn when creating a source (AuxMetadata, e.g. info learned from a web scrape) and what metadata is encoded in a track itself (Metadata). Metadata can only be read once a track is fully initialised and parsed.
  • Songbird can now better encode an audio source's lifecycle from uninitialised, to readable, to having its headers fully parsed. Read the examples on how they can be manipulated, particularly if you want to make use of metadata.

... (truncated)

Commits
  • 873aeae Chore: Release v0.4.0
  • 22ceb17 Chore: Fixup examples, bump version pre-push
  • 1ec569b Driver: Remove RwLock from ThreadPool (#206)
  • 1f616da Chore: Release v0.4.0-rc-2
  • cc53312 Deps: Re-disable default Serenity features
  • 3809616 Chore: Release v0.4.0-rc
  • 91640f6 Chore: Cleanup clippy lints
  • 1487da1 Chore: Upgrade serenity to 0.12.0-rc
  • 0ef0e4f Chore: Bump DiscoRTP version
  • 3d307aa Fix clippy pedantic warnings (#204)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [songbird](https://github.com/serenity-rs/songbird) from 0.3.2 to 0.4.0.
- [Release notes](https://github.com/serenity-rs/songbird/releases)
- [Changelog](https://github.com/serenity-rs/songbird/blob/current/CHANGELOG.md)
- [Commits](serenity-rs/songbird@v0.3.2...v0.4.0)

---
updated-dependencies:
- dependency-name: songbird
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file rust Pull requests that update Rust code labels Dec 4, 2023
@github-actions github-actions Bot enabled auto-merge (squash) December 4, 2023 09:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant