Skip to content

Commit

Permalink
feat: add task id to GetPieceNumbersRequest (#204)
Browse files Browse the repository at this point in the history
Signed-off-by: Gaius <[email protected]>
  • Loading branch information
gaius-qi authored Nov 6, 2023
1 parent db4b1f4 commit 5b85c45
Show file tree
Hide file tree
Showing 7 changed files with 114 additions and 83 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dragonfly-api"
version = "2.0.40"
version = "2.0.41"
authors = ["Gaius <[email protected]>"]
edition = "2021"
license = "Apache-2.0"
Expand Down
174 changes: 93 additions & 81 deletions pkg/apis/dfdaemon/v2/dfdaemon.pb.go

Large diffs are not rendered by default.

11 changes: 11 additions & 0 deletions pkg/apis/dfdaemon/v2/dfdaemon.pb.validate.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions pkg/apis/dfdaemon/v2/dfdaemon.proto
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ option go_package = "d7y.io/api/v2/pkg/apis/dfdaemon/v2;dfdaemon";

// GetPieceNumbersRequest represents gets piece numbers request of GetPieceNumbers.
message GetPieceNumbersRequest {
// Task id.
string task_id = 1 [(validate.rules).string.min_len = 1];
}

// GetPieceNumbersResponse represents gets piece numbers response of GetPieceNumbers.
Expand Down
2 changes: 2 additions & 0 deletions proto/dfdaemon.proto
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ import "google/protobuf/empty.proto";

// GetPieceNumbersRequest represents gets piece numbers request of GetPieceNumbers.
message GetPieceNumbersRequest {
// Task id.
string task_id = 1;
}

// GetPieceNumbersResponse represents gets piece numbers response of GetPieceNumbers.
Expand Down
Binary file modified src/descriptor.bin
Binary file not shown.
6 changes: 5 additions & 1 deletion src/dfdaemon.v2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@
#[derive(serde::Serialize, serde::Deserialize)]
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct GetPieceNumbersRequest {}
pub struct GetPieceNumbersRequest {
/// Task id.
#[prost(string, tag = "1")]
pub task_id: ::prost::alloc::string::String,
}
/// GetPieceNumbersResponse represents gets piece numbers response of GetPieceNumbers.
#[derive(serde::Serialize, serde::Deserialize)]
#[allow(clippy::derive_partial_eq_without_eq)]
Expand Down

0 comments on commit 5b85c45

Please sign in to comment.