Skip to content

Commit d2d51b5

Browse files
rohan-b99claude
andcommitted
chore: resolve forward-port conflicts in dedup tests, Dockerfile and lockfile
- deduplication.rs: take dev's deterministic test_dedup_service (#10393), keep the 3.x cancellation tests and their imports - Dockerfile.repo: rust 1.99.0 on the 3.x trixie base - Cargo.lock: keep terminal_size, still used on 3.x Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent d03158b commit d2d51b5

3 files changed

Lines changed: 2 additions & 35 deletions

File tree

‎Cargo.lock‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7695,7 +7695,6 @@ dependencies = [
76957695
"once_cell",
76967696
"rustix",
76977697
"windows-sys 0.61.0",
7698-
<<<<<<< HEAD
76997698
]
77007699

77017700
[[package]]
@@ -7706,8 +7705,6 @@ checksum = "230a1b821ccbd75b185820a1f1ff7b14d21da1e442e22c0863ea5f08771a8874"
77067705
dependencies = [
77077706
"rustix",
77087707
"windows-sys 0.61.0",
7709-
=======
7710-
>>>>>>> origin/dev
77117708
]
77127709

77137710
[[package]]

‎apollo-router/src/plugins/traffic_shaping/deduplication.rs‎

Lines changed: 1 addition & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -248,17 +248,14 @@ where
248248

249249
#[cfg(test)]
250250
mod tests {
251-
<<<<<<< HEAD
252251
use std::time::Duration;
253252

253+
use futures::FutureExt;
254254
use futures::future::BoxFuture;
255255
use http::StatusCode;
256256
use tokio::time::Instant;
257257
use tower::BoxError;
258258
use tower::Layer;
259-
=======
260-
use futures::FutureExt;
261-
>>>>>>> origin/dev
262259
use tower::Service;
263260
use tower::ServiceExt;
264261
use tower_test::mock::Handle;
@@ -269,20 +266,7 @@ mod tests {
269266
use crate::services::SubgraphResponse;
270267
use crate::services::subgraph;
271268

272-
<<<<<<< HEAD
273-
// Testing strategy:
274-
// - Two calls with the same cache key are joined in the same task via tokio::join!.
275-
// join! polls fut1 first: it locks the wait_map, inserts an entry, calls the inner
276-
// service, and yields (pending on the mock response). join! then polls fut2: it finds
277-
// the entry and joins the shared fetch. Both are suspended before the driver ever
278-
// responds. This ordering is structural — cooperative scheduling in a single task —
279-
// not a timing assumption.
280-
// - The driver handles exactly one request. If dedup fails and fut2 reaches the inner
281-
// service a second time, the closed handle returns an error and res2 fails.
282-
#[tokio::test(flavor = "multi_thread")]
283-
=======
284269
#[tokio::test]
285-
>>>>>>> origin/dev
286270
async fn test_dedup_service() {
287271
let (mock, mut handle) = tower_test::mock::pair::<SubgraphRequest, SubgraphResponse>();
288272
let mut svc = QueryDeduplicationService::new(mock);
@@ -293,20 +277,10 @@ mod tests {
293277
svc.ready().await.expect("it is ready");
294278
let mut fut2 = svc.call(request);
295279

296-
<<<<<<< HEAD
297-
// tokio::join! polls fut1 first. fut1 inserts a wait_map entry and yields waiting
298-
// for the inner service response. join! then polls fut2, which finds the entry and
299-
// joins the shared fetch. Both are suspended before the driver responds,
300-
// guaranteeing deduplication.
301-
let (res1, res2) = tokio::join!(fut1, fut2);
302-
res1.expect("fut1 joined");
303-
res2.expect("fut2 joined");
304-
=======
305280
// Poll both callers before the mock answers: fut1 starts the fetch and fut2 subscribes
306281
// to its result.
307282
assert!(futures::poll!(&mut fut1).is_pending());
308283
assert!(futures::poll!(&mut fut2).is_pending());
309-
>>>>>>> origin/dev
310284

311285
let (req, responder) = handle.next_request().await.expect("the mock is called");
312286
assert!(

‎dockerfiles/diy/dockerfiles/Dockerfile.repo‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,7 @@
55
# environment specifically to support those hosts. Use an older build base
66
# (or a static musl target) here if you need that compatibility instead.
77
# renovate-automation: rustc version
8-
<<<<<<< HEAD
9-
FROM rust:1.98.1-slim-trixie as build
10-
=======
11-
FROM rust:1.99.0-slim-bookworm as build
12-
>>>>>>> origin/dev
8+
FROM rust:1.99.0-slim-trixie as build
139

1410
# Set our working directory for the build
1511
WORKDIR /usr/src/router

0 commit comments

Comments
 (0)