Skip to content

Commit df3602c

Browse files
committed
chore: Update dependencies and modify proto file for integration tests
1 parent f1486d4 commit df3602c

File tree

7 files changed

+17
-13
lines changed

7 files changed

+17
-13
lines changed

Diff for: Cargo.lock

+4-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: Cargo.toml

+2-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ metrics-exporter-prometheus = { version = "0.15.3", default-features = false, fe
1818
"http-listener",
1919
"uds-listener",
2020
] }
21-
prost = "0.11"
21+
prost = "0.13"
2222
rand = { version = "0.8", default-features = false }
2323
rustc-hash = { version = "1.1" }
2424
serde = { version = "1.0", features = ["std", "derive"] }
@@ -37,6 +37,7 @@ once_cell = { version = "1.20" }
3737
hyper = { version = "1.5.2", default-features = false }
3838
http = "1.2.0"
3939
http-serde = "2.1.1"
40+
http-body-util = "0.1"
4041

4142

4243
[profile.release]

Diff for: integration/ducks/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ anyhow = "1.0"
1212
bytes = { workspace = true }
1313
entropy = "0.4"
1414
hyper = { version = "1.5.2", features = ["http1", "server"] }
15+
http-body-util = { workspace = true }
1516
once_cell = { workspace = true }
1617
shared = { path = "../shared" }
1718
sketches-ddsketch = "0.3"

Diff for: integration/shared/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ tonic = { workspace = true, default-features = false, features = [
1414
"prost",
1515
"transport",
1616
] }
17-
prost = "0.11"
17+
prost = { workspace = true }
1818
serde_json = "1.0"
1919

2020
[build-dependencies]

Diff for: integration/shared/proto/integration_api.proto

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,25 @@
11
syntax = "proto3";
22
package integration_api;
3-
import "google/protobuf/empty.proto";
4-
import "google/protobuf/descriptor.proto";
53

64
// Integration test target service. This is hosted by Ducks.
75
service IntegrationTarget {
86
// (Not implemented) Get a stream of log messages from the target
97
//
108
// this is necessary for modes where ducks is launched by lading
11-
rpc GetLogs (google.protobuf.Empty) returns (stream LogMessage) {}
9+
rpc GetLogs (Empty) returns (stream LogMessage) {}
1210

1311
// Launch a test endpoint
1412
rpc StartTest (TestConfig) returns (ListenInfo) {}
1513

1614
// Request all recorded metrics
17-
rpc GetMetrics (google.protobuf.Empty) returns (Metrics) {}
15+
rpc GetMetrics (Empty) returns (Metrics) {}
1816

1917
// Shut down all operations and exit
20-
rpc Shutdown (google.protobuf.Empty) returns (google.protobuf.Empty) {}
18+
rpc Shutdown (Empty) returns (Empty) {}
2119
}
2220

21+
message Empty {}
22+
2323
// Holds a json-serialized [`DucksConfig`]
2424
message TestConfig {
2525
string json_blob = 1;

Diff for: integration/shared/src/lib.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
use integration_api::TestConfig;
22
use serde::{Deserialize, Serialize};
3+
use tonic::IntoRequest;
4+
use tonic::Request;
35

46
#[allow(clippy::derive_partial_eq_without_eq)]
57
pub mod integration_api {
6-
use tonic::{IntoRequest, Request};
78
tonic::include_proto!("integration_api");
89
}
910

Diff for: lading/src/generator/http.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ impl Http {
193193
/// Function will panic if it is unable to create HTTP requests for the
194194
/// target.
195195
pub async fn spin(mut self) -> Result<(), Error> {
196-
let client: Client<HttpConnector, Body> = Client::builder()
196+
let client: Client<HttpConnector, BoxBody> = Client::builder()
197197
.pool_max_idle_per_host(self.parallel_connections as usize)
198198
.retry_canceled_requests(false)
199199
.build_http();
@@ -217,7 +217,7 @@ impl Http {
217217
let body = Body::from(blk.bytes.clone());
218218
let block_length = blk.bytes.len();
219219

220-
let mut request: Request<Body> = Request::builder()
220+
let mut request: Request<BoxBody> = Request::builder()
221221
.method(method.clone())
222222
.uri(&uri)
223223
.header(CONTENT_LENGTH, block_length)

0 commit comments

Comments
 (0)