Skip to content

Commit

Permalink
update dependencies and codegen (#93)
Browse files Browse the repository at this point in the history
* bump prost to 0.13.4, update generated files

* add missing conditional gate that is required for prost without capnp

* update capnp, capnpc, and generated code

* update most benched dependencies to their latest versions

* update rkyv also

* update bilrost and flatbuffers
  • Loading branch information
mumbleskates authored Jan 3, 2025
1 parent 2af6a9f commit b846556
Show file tree
Hide file tree
Showing 11 changed files with 314 additions and 338 deletions.
34 changes: 17 additions & 17 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ build = "build.rs"
# Some features may require multiple dependencies to compile properly
# For example, benchmarking bincode requires two features: "serde" and "bincode"
[dependencies]
bilrost = { version = "=0.1010.0", optional = true }
bilrost = { version = "=0.1011.0", optional = true }
bincode1 = { package = "bincode", version = "=1.3.3", optional = true }
# Can't call it bincode2 because of a current issue of bincode2
bincode = { package = "bincode", version = "=2.0.0-rc.3", optional = true }
bitcode = { version = "=0.6.3", optional = true }
borsh = { version = "=1.5.1", features = ["derive"], optional = true }
capnp = { version = "=0.19.7", optional = true }
borsh = { version = "=1.5.3", features = ["derive"], optional = true }
capnp = { version = "=0.20.3", optional = true }
cbor4ii = { version = "=0.3.3", features = [
"use_std",
"serde1",
Expand All @@ -58,24 +58,24 @@ ciborium = { version = "=0.2.2", optional = true }
criterion = "=0.5.1"
databuf = { version = "=0.5.0", optional = true }
dlhn = { version = "=0.1.7", optional = true }
flatbuffers = { version = "=24.3.25", optional = true }
flatbuffers = { version = "=24.12.23", optional = true }
libflate = "=2.1.0"
msgpacker = { version = "=0.4.3", optional = true }
msgpacker = { version = "=0.4.5", optional = true }
nachricht-serde = { version = "=0.4.0", optional = true }
nanoserde = { version = "=0.1.37", optional = true }
parity-scale-codec = { version = "=3.6.12", features = [
"full",
], optional = true }
parity-scale-codec-derive = { version = "=3.6.12", optional = true }
postcard = { version = "=1.0.10", features = ["alloc"], optional = true }
postcard = { version = "=1.1.1", features = ["alloc"], optional = true }
pot = { version = "=3.0.1", optional = true }
pprof = { version = "=0.13.0", features = ["flamegraph"], optional = true }
prost = { version = "=0.13.2", optional = true }
pprof = { version = "=0.14.0", features = ["flamegraph"], optional = true }
prost = { version = "=0.13.4", optional = true }
rand = "=0.8.5"
rkyv = { version = "=0.8.5", optional = true }
rkyv = { version = "=0.8.9", optional = true }
rmp-serde = { version = "=1.3.0", optional = true }
ron = { version = "=0.8.1", optional = true }
serde = { version = "=1.0.210", features = ["derive"] }
serde = { version = "=1.0.216", features = ["derive"] }
serde_bare = { version = "=0.5.0", optional = true }
serde-brief = { version = "=0.1.0", features = [
"std",
Expand All @@ -84,11 +84,11 @@ serde_cbor = { version = "=0.11.2", optional = true }
serde_json = { version = "=1.0.128", features = [
"float_roundtrip",
], optional = true }
simd-json = { version = "=0.13.10", optional = true }
simd-json-derive = { version = "=0.13.0", optional = true }
simd-json = { version = "=0.14.3", optional = true }
simd-json-derive = { version = "=0.15.0", optional = true }
speedy = { version = "=0.8.7", optional = true }
savefile = { version = "=0.17.7", optional = true }
savefile-derive = { version = "=0.17.7", optional = true }
savefile = { version = "=0.18.5", optional = true }
savefile-derive = { version = "=0.18.5", optional = true }
wiring = { version = "=0.2.2", optional = true }
zstd = "=0.13.2"

Expand Down Expand Up @@ -139,10 +139,10 @@ regenerate-prost = ["dep:prost-build"]
rand_pcg = "0.3.1"

[build-dependencies]
capnp = "=0.19.7"
capnpc = { version = "=0.19.0", optional = true }
capnp = "=0.20.3"
capnpc = { version = "=0.20.1", optional = true }
flatc-rust = { version = "=0.2.0", optional = true }
prost-build = { version = "=0.13.2", optional = true }
prost-build = { version = "=0.13.4", optional = true }

[[bench]]
harness = false
Expand Down
2 changes: 1 addition & 1 deletion src/bench_rkyv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use rkyv::{
Archive, Deserialize, Serialize,
};

pub type BenchSerializer<'a> = HighSerializer<'a, AlignedVec, ArenaHandle<'a>, Failure>;
pub type BenchSerializer<'a> = HighSerializer<AlignedVec, ArenaHandle<'a>, Failure>;
pub type BenchDeserializer = HighDeserializer<Failure>;
pub type BenchValidator<'a> = HighValidator<'a, Failure>;

Expand Down
44 changes: 22 additions & 22 deletions src/datasets/log/log_capnp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ pub mod address {
impl ::capnp::traits::Pipelined for Owned { type Pipeline = Pipeline; }

pub struct Reader<'a> { reader: ::capnp::private::layout::StructReader<'a> }
impl <'a,> ::core::marker::Copy for Reader<'a,> {}
impl <'a,> ::core::clone::Clone for Reader<'a,> {
impl <> ::core::marker::Copy for Reader<'_,> {}
impl <> ::core::clone::Clone for Reader<'_,> {
fn clone(&self) -> Self { *self }
}

impl <'a,> ::capnp::traits::HasTypeId for Reader<'a,> {
impl <> ::capnp::traits::HasTypeId for Reader<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructReader<'a>> for Reader<'a,> {
Expand All @@ -32,7 +32,7 @@ pub mod address {
}
}

impl <'a,> ::core::fmt::Debug for Reader<'a,> {
impl <> ::core::fmt::Debug for Reader<'_,> {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::result::Result<(), ::core::fmt::Error> {
core::fmt::Debug::fmt(&::core::convert::Into::<::capnp::dynamic_value::Reader<'_>>::into(*self), f)
}
Expand All @@ -56,7 +56,7 @@ pub mod address {
}
}

impl <'a,> Reader<'a,> {
impl <> Reader<'_,> {
pub fn reborrow(&self) -> Reader<'_,> {
Self { .. *self }
}
Expand All @@ -83,10 +83,10 @@ pub mod address {
}

pub struct Builder<'a> { builder: ::capnp::private::layout::StructBuilder<'a> }
impl <'a,> ::capnp::traits::HasStructSize for Builder<'a,> {
impl <> ::capnp::traits::HasStructSize for Builder<'_,> {
const STRUCT_SIZE: ::capnp::private::layout::StructSize = ::capnp::private::layout::StructSize { data: 1, pointers: 0 };
}
impl <'a,> ::capnp::traits::HasTypeId for Builder<'a,> {
impl <> ::capnp::traits::HasTypeId for Builder<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructBuilder<'a>> for Builder<'a,> {
Expand Down Expand Up @@ -116,7 +116,7 @@ pub mod address {
}
}

impl <'a,> ::capnp::traits::SetterInput<Owned<>> for Reader<'a,> {
impl <> ::capnp::traits::SetterInput<Owned<>> for Reader<'_,> {
fn set_pointer_builder(mut pointer: ::capnp::private::layout::PointerBuilder<'_>, value: Self, canonicalize: bool) -> ::capnp::Result<()> { pointer.set_struct(&value.reader, canonicalize) }
}

Expand Down Expand Up @@ -292,12 +292,12 @@ pub mod log {
impl ::capnp::traits::Pipelined for Owned { type Pipeline = Pipeline; }

pub struct Reader<'a> { reader: ::capnp::private::layout::StructReader<'a> }
impl <'a,> ::core::marker::Copy for Reader<'a,> {}
impl <'a,> ::core::clone::Clone for Reader<'a,> {
impl <> ::core::marker::Copy for Reader<'_,> {}
impl <> ::core::clone::Clone for Reader<'_,> {
fn clone(&self) -> Self { *self }
}

impl <'a,> ::capnp::traits::HasTypeId for Reader<'a,> {
impl <> ::capnp::traits::HasTypeId for Reader<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructReader<'a>> for Reader<'a,> {
Expand All @@ -312,7 +312,7 @@ pub mod log {
}
}

impl <'a,> ::core::fmt::Debug for Reader<'a,> {
impl <> ::core::fmt::Debug for Reader<'_,> {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::result::Result<(), ::core::fmt::Error> {
core::fmt::Debug::fmt(&::core::convert::Into::<::capnp::dynamic_value::Reader<'_>>::into(*self), f)
}
Expand Down Expand Up @@ -395,10 +395,10 @@ pub mod log {
}

pub struct Builder<'a> { builder: ::capnp::private::layout::StructBuilder<'a> }
impl <'a,> ::capnp::traits::HasStructSize for Builder<'a,> {
impl <> ::capnp::traits::HasStructSize for Builder<'_,> {
const STRUCT_SIZE: ::capnp::private::layout::StructSize = ::capnp::private::layout::StructSize { data: 2, pointers: 5 };
}
impl <'a,> ::capnp::traits::HasTypeId for Builder<'a,> {
impl <> ::capnp::traits::HasTypeId for Builder<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructBuilder<'a>> for Builder<'a,> {
Expand Down Expand Up @@ -428,7 +428,7 @@ pub mod log {
}
}

impl <'a,> ::capnp::traits::SetterInput<Owned<>> for Reader<'a,> {
impl <> ::capnp::traits::SetterInput<Owned<>> for Reader<'_,> {
fn set_pointer_builder(mut pointer: ::capnp::private::layout::PointerBuilder<'_>, value: Self, canonicalize: bool) -> ::capnp::Result<()> { pointer.set_struct(&value.reader, canonicalize) }
}

Expand Down Expand Up @@ -719,12 +719,12 @@ pub mod logs {
impl ::capnp::traits::Pipelined for Owned { type Pipeline = Pipeline; }

pub struct Reader<'a> { reader: ::capnp::private::layout::StructReader<'a> }
impl <'a,> ::core::marker::Copy for Reader<'a,> {}
impl <'a,> ::core::clone::Clone for Reader<'a,> {
impl <> ::core::marker::Copy for Reader<'_,> {}
impl <> ::core::clone::Clone for Reader<'_,> {
fn clone(&self) -> Self { *self }
}

impl <'a,> ::capnp::traits::HasTypeId for Reader<'a,> {
impl <> ::capnp::traits::HasTypeId for Reader<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructReader<'a>> for Reader<'a,> {
Expand All @@ -739,7 +739,7 @@ pub mod logs {
}
}

impl <'a,> ::core::fmt::Debug for Reader<'a,> {
impl <> ::core::fmt::Debug for Reader<'_,> {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::result::Result<(), ::core::fmt::Error> {
core::fmt::Debug::fmt(&::core::convert::Into::<::capnp::dynamic_value::Reader<'_>>::into(*self), f)
}
Expand Down Expand Up @@ -782,10 +782,10 @@ pub mod logs {
}

pub struct Builder<'a> { builder: ::capnp::private::layout::StructBuilder<'a> }
impl <'a,> ::capnp::traits::HasStructSize for Builder<'a,> {
impl <> ::capnp::traits::HasStructSize for Builder<'_,> {
const STRUCT_SIZE: ::capnp::private::layout::StructSize = ::capnp::private::layout::StructSize { data: 0, pointers: 1 };
}
impl <'a,> ::capnp::traits::HasTypeId for Builder<'a,> {
impl <> ::capnp::traits::HasTypeId for Builder<'_,> {
const TYPE_ID: u64 = _private::TYPE_ID;
}
impl <'a,> ::core::convert::From<::capnp::private::layout::StructBuilder<'a>> for Builder<'a,> {
Expand Down Expand Up @@ -815,7 +815,7 @@ pub mod logs {
}
}

impl <'a,> ::capnp::traits::SetterInput<Owned<>> for Reader<'a,> {
impl <> ::capnp::traits::SetterInput<Owned<>> for Reader<'_,> {
fn set_pointer_builder(mut pointer: ::capnp::private::layout::PointerBuilder<'_>, value: Self, canonicalize: bool) -> ::capnp::Result<()> { pointer.set_struct(&value.reader, canonicalize) }
}

Expand Down
5 changes: 1 addition & 4 deletions src/datasets/log/prost.log.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// This file is @generated by prost-build.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Address {
#[prost(uint32, tag = "1")]
pub x0: u32,
Expand All @@ -11,7 +10,6 @@ pub struct Address {
#[prost(uint32, tag = "4")]
pub x3: u32,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Log {
#[prost(message, optional, tag = "1")]
Expand All @@ -29,7 +27,6 @@ pub struct Log {
#[prost(uint64, tag = "7")]
pub size: u64,
}
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Logs {
#[prost(message, repeated, tag = "1")]
Expand Down
Loading

0 comments on commit b846556

Please sign in to comment.