Skip to content

Commit

Permalink
Merge branch 'main' into fix/http-nest-router
Browse files Browse the repository at this point in the history
  • Loading branch information
yukiiiteru authored Aug 26, 2024
2 parents 9d811cb + f2b7f7c commit 21759ca
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 4 additions & 1 deletion volo-thrift/src/codec/default/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ use crate::{context::ThriftContext, EntryMessage, ThriftMessage};
pub mod framed;
pub mod thrift;
pub mod ttheader;
// mod mesh_header;

/// Trait for encoding a [`ThriftMessage`] in place.
///
/// [`ZeroCopyEncoder`] tries to encode a message without copying large data taking the advantage
/// of [`LinkedBytes`], which can insert a [`Bytes`] into the middle of a [`bytes::BytesMut`] and
/// uses writev.
Expand Down Expand Up @@ -74,6 +75,8 @@ pub trait ZeroCopyEncoder: Send + Sync + 'static {
) -> Result<(usize, usize), ThriftException>;
}

/// Trait for decoding a [`ThriftMessage`] in place.
///
/// [`ZeroCopyDecoder`] tries to decode a message without copying large data, so the [`Bytes`] in
/// the `decode` method is not designed to be reused, and the implementation can use
/// `Bytes::split_to` to get a [`Bytes`] and hand it to the user directly.
Expand Down
2 changes: 2 additions & 0 deletions volo/src/discovery/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ pub struct Change<K> {
pub removed: Vec<Arc<Instance>>,
}

/// Get the difference of two address lists.
///
/// [`diff_address`] provides a naive implementation that compares prev and next only by the
/// address, and returns the [`Change`], which means that the `updated` is always empty when using
/// this implementation.
Expand Down

0 comments on commit 21759ca

Please sign in to comment.