forked from twilight-rs/twilight
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
release: 2023-03-28 (twilight-rs#2183)
* release: 2023-03-26 updates * fix
- Loading branch information
1 parent
9c74649
commit 35dfeec
Showing
3 changed files
with
54 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# 2023-03-28 Updates | ||
|
||
We've published minor versions of a number of crates. This release is composed | ||
of bugfixes, performance improvements, and documentation improvements. | ||
|
||
## Bugfixes | ||
|
||
The [gateway queue]'s [`DayLimiter`] now properly calculates when the session | ||
resets. | ||
|
||
The [`UpdateGuildSticker`] request now uses the specified audit log reason; | ||
prior, it was accidentally ignoring the reason. | ||
|
||
Discord's Clyde AI bot has a unique avatar hash. Unlike other hashes that are | ||
hex based, Clyde's avatar hash is simply "clyde". We now handle deserialization | ||
of Clyde's avatar in our [`ImageHash`] optimization. | ||
|
||
## Documentation Improvements | ||
|
||
The [`Event::IntegrationDelete`] and [`Event::IntegrationUpdate`] variants' | ||
documentation was inversed, and has now been corrected. | ||
|
||
[`Standby`] now has an example of how to timeout futures and streams. | ||
|
||
## Performance Improvements | ||
|
||
The gateway's [`CommandRatelimiter`] performance has been improved by over 98%, | ||
with common calls being reduced from around 4 microseconds to around 57 | ||
nanoseconds. This is something that can be used by users, and is also used by | ||
shards when sending commands, making common operations just a bit more speedy. | ||
Impressive! | ||
|
||
Avatars, banners, icons, and other assets are received as hashes, which we have | ||
[`ImageHash`] for as a performance improvement in storage. Instead of storing | ||
hashes as heap-allocated strings, we store them as 16 bytes on the stack. | ||
The performance of the deserialization and parsing of hashes is now 38% faster. | ||
|
||
Caching users received in [`InteractionCreate`] events is now a bit faster in | ||
some situations due to [keying into a HashMap][`HashMap::get`] to check for the | ||
existence of a user instead of [iterating over the HashMap][`HashMap::iter`]. | ||
|
||
[`CommandRatelimiter`]: https://docs.rs/twilight-gateway/0.15.2/twilight_gateway/struct.CommandRatelimiter.html | ||
[`DayLimiter`]: https://docs.rs/twilight-gateway-queue/0.15.2/twilight_gateway_queue/struct.LocalQueue.html | ||
[`Event::IntegrationDelete`]: https://docs.rs/twilight-model/0.15.2/twilight_model/gateway/event/enum.Event.html#variant.IntegrationDelete | ||
[`Event::IntegrationUpdate`]: https://docs.rs/twilight-model/0.15.2/twilight_model/gateway/event/enum.Event.html#variant.IntegrationUpdate | ||
[`HashMap::get`]: https://doc.rust-lang.org/stable/std/collections/hash_map/struct.HashMap.html#method.get | ||
[`HashMap::iter`]: https://doc.rust-lang.org/stable/std/collections/hash_map/struct.HashMap.html#method.iter | ||
[`ImageHash`]: https://docs.rs/twilight-model/0.15.2/twilight_model/util/image_hash/struct.ImageHash.html | ||
[`InteractionCreate`]: https://docs.rs/twilight-model/0.15.2/twilight_model/gateway/payload/incoming/struct.InteractionCreate.html | ||
[`Standby`]: https://docs.rs/twilight-standby/0.15.2/twilight_standby/struct.Standby.html | ||
[`UpdateGuildSticker`]: https://docs.rs/twilight-http/0.15.2/twilight_http/request/guild/sticker/struct.UpdateGuildSticker.html | ||
[gateway queue]: https://docs.rs/twilight-gateway-queue/0.15.2/twilight_gateway_queue/index.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
# Version History | ||
|
||
- [0.15 - 2023-02-05](./0.15/summary.md) | ||
- [0.15.2 - 2023-03-28](./0.15/2023-03-28.md) | ||
- [0.15.1 - 2023-02-26](./0.15/2023-02-26.md) |