Skip to content

Add async backoff test for accept loop#297

Merged
leynos merged 6 commits intomainfrom
codex/add-async-test-for-accept_loop-backoff
Aug 12, 2025
Merged

Add async backoff test for accept loop#297
leynos merged 6 commits intomainfrom
codex/add-async-test-for-accept_loop-backoff

Conversation

@leynos
Copy link
Copy Markdown
Owner

@leynos leynos commented Aug 9, 2025

Summary

  • refactor accept loop to accept a generic listener
  • test backoff delays using a mock listener that always errors

Testing

  • make fmt
  • make lint
  • make test

closes #294


https://chatgpt.com/codex/tasks/task_e_6896851cd32083229ab75609438062c4

Summary by Sourcery

Abstract the accept loop over a new async Listener trait, adapt the existing TcpListener to this interface, and add a test to ensure the loop applies exponential backoff delays correctly when accept errors occur

New Features:

  • Introduce an async Listener trait for generic connection acceptance

Enhancements:

  • Generalize accept_loop to work with any Listener implementation instead of concrete TcpListener
  • Implement Listener trait for TcpListener

Tests:

  • Add an asynchronous test using a mock listener to verify exponential backoff delays in accept_loop

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 9, 2025

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Warning

Rate limit exceeded

@leynos has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 5 minutes and 2 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 9a3c324 and 2ad2597.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (3)
  • Cargo.toml (1 hunks)
  • docs/mocking-network-outages-in-rust.md (1 hunks)
  • src/server/runtime.rs (7 hunks)

Summary by CodeRabbit

  • New Features
    • Configurable back-off for accepting new connections, improving resilience during transient network issues.
  • Documentation
    • Updated Rust example terminology to use a clearer trait name.
  • Tests
    • Added deterministic tests validating exponential back-off behaviour.
  • Chores
    • Added a testing library as a development dependency.

Walkthrough

Introduce an AcceptListener trait and BackoffConfig; implement AcceptListener for TcpListener; make accept_loop generic over AcceptListener and accept shutdown/tracker/backoff parameters; add async tests with a MockAcceptListener to validate exponential backoff; rename a docs example trait to AcceptListener.

Changes

Cohort / File(s) Summary
Accept loop abstraction & tests
src/server/runtime.rs
Add pub(super) trait AcceptListener and BackoffConfig; implement AcceptListener for TcpListener; generalise accept_loop to Arc<L> where L: AcceptListener + Send + Sync + 'static; add shutdown: CancellationToken, tracker: TaskTracker, backoff_config: BackoffConfig params; add mock accept listener and async test verifying exponential backoff timings.
Documentation example rename
docs/mocking-network-outages-in-rust.md
Rename example trait ListenerAcceptListener in the accept-loop snippet; keep async fn accept(&self) -> io::Result<(Box<dyn Stream>, SocketAddr)>; unchanged.
Dev-dependencies
Cargo.toml
Add mockall = "0.13.1" under [dev-dependencies] for mocking in tests.

Sequence Diagram(s)

sequenceDiagram
  participant AcceptLoop
  participant AcceptListener
  participant Backoff
  participant Worker

  loop accept cycle
    AcceptLoop->>AcceptListener: accept()
    alt success
      AcceptListener-->>AcceptLoop: (TcpStream, SocketAddr)
      AcceptLoop->>Worker: spawn connection task
      Backoff-->>AcceptLoop: reset backoff
    else failure
      AcceptListener-->>AcceptLoop: io::Error
      AcceptLoop->>Backoff: compute next delay
      Backoff-->>AcceptLoop: delay (exponential)
      AcceptLoop->>AcceptLoop: await delay or observe shutdown
    end
  end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~18 minutes

Assessment against linked issues

Objective Addressed Explanation
Add async test for accept_loop backoff behaviour [#294]
Simulate accept_loop with mock listener returning repeated errors [#294]
Observe backoff and retry logic end-to-end in async context [#294]
Implement mock listener struct with required trait [#294]

Possibly related PRs

Suggested reviewers

  • codescene-delta-analysis

"New listener named, ready to chart,
Errors echo — backoff takes heart,
Five, ten, twenty, the intervals grow,
Mocked doors slam, then open — go,
Tests hum steady, the runtime aglow."

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch codex/add-async-test-for-accept_loop-backoff

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@sourcery-ai
Copy link
Copy Markdown
Contributor

sourcery-ai Bot commented Aug 9, 2025

Reviewer's Guide

The PR refactors the accept loop to abstract over a generic Listener trait and adds an async test verifying exponential backoff behavior using a mock listener that always errors.

Sequence diagram for accept_loop with MockListener and exponential backoff

sequenceDiagram
    participant accept_loop
    participant MockListener
    participant CancellationToken
    loop until cancelled
        accept_loop->>MockListener: accept()
        MockListener-->>accept_loop: Err(io::Error)
        accept_loop->>accept_loop: wait (exponential backoff)
    end
    accept_loop->>CancellationToken: check cancel
    accept_loop-->>accept_loop: exit loop
Loading

Class diagram for Listener trait and implementations

classDiagram
    class Listener {
        <<trait>>
        +accept() io::Result<(TcpStream, SocketAddr)> [async]
        +local_addr() io::Result<SocketAddr>
    }
    class TcpListener {
        +accept() io::Result<(TcpStream, SocketAddr)> [async]
        +local_addr() io::Result<SocketAddr>
    }
    class MockListener {
        +calls: Arc<Mutex<Vec<Instant>>>
        +accept() io::Result<(TcpStream, SocketAddr)> [async]
        +local_addr() io::Result<SocketAddr>
    }
    Listener <|.. TcpListener
    Listener <|.. MockListener
Loading

Class diagram for updated accept_loop function

classDiagram
    class accept_loop {
        +listener: Arc<L>
        +factory: F
        +on_success: Option<PreambleCallback<T>>
        +on_failure: Option<PreambleErrorCallback>
        +token: CancellationToken
        +tracker: TaskTracker
        +backoff_config: BackoffConfig
        +async fn accept_loop()
    }
    class Listener {
        <<trait>>
    }
    accept_loop --> Listener: uses
Loading

File-Level Changes

Change Details Files
Introduce a generic Listener trait for accept_loop
  • Define async_trait-based Listener trait with accept and local_addr methods
  • Implement Listener for TcpListener
  • Update accept_loop signature to accept Arc where L: Listener and add trait bounds
  • Adjust accept_loop invocation in tests to specify the new generic parameter
src/server/runtime.rs
Add async backoff delay test using a MockListener
  • Create MockListener struct tracking accept call timestamps
  • Implement Listener for MockListener to always return an error and record calls
  • Write test_accept_loop_exponential_backoff_async verifying delays match backoff intervals
  • Add necessary imports (Mutex, async_trait, Instant) for the new test
src/server/runtime.rs

Assessment against linked issues

Issue Objective Addressed Explanation
#294 Simulate the accept_loop with a mock listener that returns repeated errors in an async test.
#294 Implement a mock listener struct with the necessary trait, making it return errors on accept calls.
#294 Run the accept_loop in the test to assert the backoff behaviour asynchronously.

Possibly linked issues


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

sourcery-ai[bot]

This comment was marked as resolved.

Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, no comments

Edit Code Review Bot Settings | Greptile

@leynos
Copy link
Copy Markdown
Owner Author

leynos commented Aug 12, 2025

@coderabbitai Have the following now been resolved?

  • Consider using tokio::time::pause and advance in your backoff test instead of real sleeps to make the timing assertions deterministic and avoid flaky tests.
  • The new Listener trait name is quite generic—consider renaming it (e.g. AcceptListener) to clarify its role and avoid potential naming collisions.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🔭 Outside diff range comments (1)
src/server/runtime.rs (1)

188-199: Add module-level documentation for the public function.

Add documentation explaining the purpose, parameters, and behaviour of this newly exposed pub(super) function.

+/// Accepts incoming connections and spawns tasks to handle them.
+///
+/// This function runs an accept loop that:
+/// - Accepts connections from the provided listener
+/// - Spawns connection handler tasks using the provided factory
+/// - Applies exponential backoff on accept errors
+/// - Respects the shutdown signal
+///
+/// # Type Parameters
+///
+/// * `F` - Factory function that creates `WireframeApp` instances
+/// * `T` - Preamble type for connection handshaking
+/// * `L` - Listener type implementing `AcceptListener`
 pub(super) async fn accept_loop<F, T, L>(
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bd5bf50 and 97cb7a6.

📒 Files selected for processing (2)
  • docs/mocking-network-outages-in-rust.md (1 hunks)
  • src/server/runtime.rs (7 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
docs/**/*.md

📄 CodeRabbit Inference Engine (docs/documentation-style-guide.md)

docs/**/*.md: Use British English based on the Oxford English Dictionary (en-oxendict) for documentation text.
The word "outwith" is acceptable in documentation.
Keep US spelling when used in an API, for example color.
Use the Oxford comma in documentation text.
Treat company names as collective nouns in documentation (e.g., "Lille Industries are expanding").
Write headings in sentence case in documentation.
Use Markdown headings (#, ##, ###, etc.) in order without skipping levels.
Follow markdownlint recommendations for Markdown files.
Provide code blocks and lists using standard Markdown syntax.
Always provide a language identifier for fenced code blocks; use plaintext for non-code text.
Use - as the first level bullet and renumber lists when items change.
Prefer inline links using [text](url) or angle brackets around the URL; avoid reference-style links like [foo][bar].
Ensure blank lines before and after bulleted lists and fenced blocks in Markdown.
Ensure tables have a delimiter line below the header row in Markdown.
Expand any uncommon acronym on first use, for example, Continuous Integration (CI).
Wrap paragraphs at 80 columns in documentation.
Wrap code at 120 columns in documentation.
Do not wrap tables in documentation.
Use sequentially numbered footnotes referenced with [^1] and place definitions at the end of the file.
Where it adds clarity, include Mermaid diagrams in documentation.
When embedding figures, use ![alt text](path/to/image) and provide concise alt text describing the content.
Add a brief description before each Mermaid diagram in documentation for screen readers.

Document examples showing how to deprecate old message versions gracefully

Write the official documentation for the new features. Create separate guides for "Duplex Messaging & Pushes", "Streaming Responses", and "Message Fragmentation". Each guide must include runnable examples and explain the relevant concepts and APIs.

docs/**/*.md: Use docs/ markdown ...

Files:

  • docs/mocking-network-outages-in-rust.md
docs/**/*.{md,rs}

📄 CodeRabbit Inference Engine (docs/multi-packet-and-streaming-responses-design.md)

docs/**/*.{md,rs}: The official documentation and examples must exclusively use the declarative Response model for handler responses.
The async-stream pattern must be documented as the canonical approach for dynamic stream generation.

Files:

  • docs/mocking-network-outages-in-rust.md
**/*.md

📄 CodeRabbit Inference Engine (AGENTS.md)

**/*.md: Markdown paragraphs and bullet points must be wrapped at 80 columns
Markdown code blocks must be wrapped at 120 columns
Do not wrap tables and headings in Markdown
Use dashes (-) for list bullets in Markdown
Use GitHub-flavoured Markdown footnotes ([^1])

Files:

  • docs/mocking-network-outages-in-rust.md

⚙️ CodeRabbit Configuration File

**/*.md: * Avoid 2nd person or 1st person pronouns ("I", "you", "we")

  • Use en-GB-oxendict (-ize / -our) spelling and grammar
  • Headings must not be wrapped.
  • Documents must start with a level 1 heading
  • Headings must correctly increase or decrease by no more than one level at a time
  • Use GitHub-flavoured Markdown style for footnotes and endnotes.
  • Numbered footnotes must be numbered by order of appearance in the document.

Files:

  • docs/mocking-network-outages-in-rust.md
**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

**/*.rs: Use precise names; boolean names should start with is/has/should
Use en-GB-oxendict spelling and grammar in comments
Function documentation must include clear examples; test documentation should omit redundant examples
Keep code files ≤ 400 lines; split long switch/dispatch logic by feature; move large test data to external files
Disallow Clippy warnings
Fix warnings emitted during tests in code rather than silencing them
Extract helper functions for long functions; adhere to separation of concerns and CQRS
Group related parameters into meaningful structs when functions have many parameters
Consider using Arc for large error returns to reduce data size
Each Rust module must begin with a module-level //! comment describing purpose and utility
Document public APIs with Rustdoc /// comments to enable cargo doc generation
Prefer immutable data; avoid unnecessary mut
Handle errors with Result instead of panicking where feasible
Avoid unsafe code unless necessary and document any usage clearly
Place function attributes after doc comments
Do not use return in single-line functions
Use predicate functions for conditional criteria with more than two branches
Do not silence lints except as a last resort
Lint suppressions must be tightly scoped and include a clear reason
Prefer #[expect(..)] over #[allow(..)] for lints
Prefer .expect() over .unwrap()
Use concat!() to combine long string literals rather than escaping newlines
Prefer single-line function bodies where appropriate (e.g., pub fn new(id: u64) -> Self { Self(id) })
Prefer semantic error enums deriving std::error::Error via thiserror for inspectable conditions

Files:

  • src/server/runtime.rs

⚙️ CodeRabbit Configuration File

**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.

  • Adhere to single responsibility and CQRS

  • Place function attributes after doc comments.

  • Do not use return in single-line functions.

  • Move conditionals with >2 branches into a predicate function.

  • Avoid unsafe unless absolutely necessary.

  • Every module must begin with a //! doc comment that explains the module's purpose and utility.

  • Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar

  • Lints must not be silenced except as a last resort.

    • #[allow] is forbidden.
    • Only narrowly scoped #[expect(lint, reason = "...")] is allowed.
    • No lint groups, no blanket or file-wide suppression.
    • Include FIXME: with link if a fix is expected.
  • Where code is only used by specific features, it must be conditionally compiled or a conditional expectation for unused_code applied.

  • Use rstest fixtures for shared setup and to avoid repetition between tests.

  • Replace duplicated tests with #[rstest(...)] parameterised cases.

  • Prefer mockall for mocks/stubs.

  • Prefer .expect() over .unwrap()

  • Ensure that any API or behavioural changes are reflected in the documentation in docs/

  • Ensure that any completed roadmap steps are recorded in the appropriate roadmap in docs/

  • Files must not exceed 400 lines in length

    • Large modules must be decomposed
    • Long match statements or dispatch tables should be decomposed by domain and collocated with targets
    • Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.

Files:

  • src/server/runtime.rs
{src,tests}/**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

Write unit and behavioural tests for new functionality

Files:

  • src/server/runtime.rs
🧬 Code Graph Analysis (1)
src/server/runtime.rs (3)
src/server/config/mod.rs (2)
  • local_addr (216-218)
  • new (45-57)
tests/preamble.rs (1)
  • oneshot (71-71)
src/server/test_util.rs (1)
  • factory (18-20)
🔍 MCP Research (2 servers)

Deepwiki:

  • src/server.rs:392-429: The accept loop in worker_task implements exponential backoff on accept errors — starts with a 10ms delay, doubles the delay after each error up to a 1s cap, and resets the delay to 10ms after a successful accept. (DeepWiki search result)
  • docs/mocking-network-outages-in-rust.md:427-435: Shows an example using tokio-test::io::Builder to inject io::Error into streams, which can be adapted to simulate accept() errors for testing backoff behavior. (DeepWiki search result)

Context7:

🔇 Additional comments (5)
src/server/runtime.rs (4)

24-27: LGTM! Well-designed trait abstraction.

The AcceptListener trait provides a clean abstraction for the accept loop, enabling effective testing whilst maintaining production behaviour. The trait methods align perfectly with the requirements for mocking network behaviour.


30-36: LGTM! Clean trait implementation.

The implementation correctly delegates to the underlying TcpListener methods. The explicit method paths (TcpListener::accept, TcpListener::local_addr) avoid ambiguity.


339-357: LGTM! Well-structured mock implementation.

The MockListener provides excellent test infrastructure. Recording call times with Instant::now() enables precise backoff timing verification. The implementation correctly returns errors to trigger the backoff logic.


360-407: Excellent async test implementation!

This test comprehensively verifies the exponential backoff behaviour:

  • Uses start_paused = true for deterministic time control
  • Correctly advances time to trigger backoff delays (5ms → 10ms → 20ms)
  • Verifies actual intervals between accept calls
  • Properly cleans up with cancellation and tracker closure

The test aligns perfectly with the PR objectives and the documented backoff behaviour from the external context.

docs/mocking-network-outages-in-rust.md (1)

582-584: LGTM! Documentation correctly updated.

The trait name change from Listener to AcceptListener in the documentation correctly reflects the implementation in src/server/runtime.rs.

Comment thread src/server/runtime.rs
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 12, 2025

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check if the trait is named AcceptListener and examine the test implementation
echo "=== Checking trait name ==="
rg "trait.*AcceptListener" src/

echo "=== Checking test implementation for timing control ==="
rg -A 20 "test_accept_loop_exponential_backoff_async" src/

echo "=== Looking for tokio::time::pause usage ==="
rg "tokio::time::pause\|time::pause\|pause()" src/

echo "=== Looking for advance usage ==="
rg "advance\|yield_now" src/

Length of output: 1774


🏁 Script executed:

#!/bin/bash
# Get the complete test function implementation
echo "=== Complete test function implementation ==="
rg -A 50 "async fn test_accept_loop_exponential_backoff_async" src/server/runtime.rs

echo "=== Check imports for timing utilities ==="
rg "use.*time" src/server/runtime.rs

echo "=== Look for sleep or timing calls in the test ==="
rg -B 5 -A 5 "sleep\|Duration\|Instant" src/server/runtime.rs

Length of output: 1982


🏁 Script executed:

#!/bin/bash
# Check the imports at the top of the file
echo "=== File imports ==="
head -50 src/server/runtime.rs | rg "use\|mod\|extern"

echo "=== Look for test configuration attributes ==="
rg -B 10 -A 2 "test_accept_loop_exponential_backoff_async" src/server/runtime.rs

echo "=== Check for tokio-test related imports or configurations ==="
rg -i "tokio.*test\|pause\|advance\|yield_now" src/server/runtime.rs

Length of output: 884


@leynos Yes, both issues have been resolved:

Trait renaming: The trait has been renamed from Listener to AcceptListener, making it more specific and avoiding potential naming collisions.

Deterministic timing: The test now uses #[tokio::test(start_paused = true)] with advance() and yield_now() for controlled time progression instead of real sleeps. This approach provides deterministic timing assertions and prevents flaky tests.

The implementation uses tokio's built-in time control features (which is actually preferable to tokio-test) by:

  • Starting the test with paused time via start_paused = true
  • Using advance(Duration::from_millis(ms)).await to precisely control time progression
  • Using yield_now().await to allow tasks to process between time advances

This ensures the backoff timing behavior (5ms → 10ms → 20ms) is tested deterministically without any race conditions or timing dependencies.

Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 file reviewed, 1 comment

Edit Code Review Bot Settings | Greptile

Comment thread src/server/runtime.rs Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🔭 Outside diff range comments (4)
src/server/runtime.rs (4)

38-53: Fix en-GB spelling in docs (“behaviour” not “behavior”).

Align with the project’s en-GB spelling guideline and keep terminology consistent in this module’s docs.

Apply this diff:

-/// Controls retry behavior when `accept()` calls fail on the server's TCP listener.
+/// Controls retry behaviour when `accept()` calls fail on the server's TCP listener.

239-251: Parameter list is getting long; group related inputs.

Reduce the cognitive load by grouping accept-loop inputs into a context struct (e.g., AcceptLoopArgs) to avoid a 7-parameter signature and ease future extension.

Example shape outside this range:

pub(super) struct AcceptLoopArgs<F, T, L> {
    pub listener: Arc<L>,
    pub factory: F,
    pub on_success: Option<PreambleCallback<T>>,
    pub on_failure: Option<PreambleErrorCallback>,
    pub shutdown: CancellationToken,
    pub tracker: TaskTracker,
    pub backoff: BackoffConfig,
}

Then accept AcceptLoopArgs by value in accept_loop.


271-275: Augment error log with back-off metadata.

Emit the next retry delay to aid triage when accept storms happen.

Apply this diff:

-                    let local_addr = listener.local_addr().ok();
-                    tracing::warn!(error = ?e, ?local_addr, "accept error");
-                    sleep(delay).await;
-                    delay = (delay * 2).min(backoff_config.max_delay);
+                    let local_addr = listener.local_addr().ok();
+                    tracing::warn!(error = ?e, ?local_addr, retry_in = ?delay, "accept error; backing off");
+                    sleep(delay).await;
+                    delay = (delay * 2).min(backoff_config.max_delay);

281-466: Reduce file size by moving tests to a sibling tests module.

The file is 467 lines, exceeding the 400-line limit. Extract the #[cfg(test)] module into a dedicated src/server/runtime/tests.rs (or tests/ integration tests if suitable) and mod tests; gate it to bring this file back under the limit.

♻️ Duplicate comments (1)
src/server/runtime.rs (1)

410-465: Async back-off test is deterministic and thorough.

Start the clock paused, advance in discrete steps with yield_now() between, and assert the 5→10→20ms sequence. The immediate first-call assertion is present and correct.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 97cb7a6 and 74bf9cd.

📒 Files selected for processing (1)
  • src/server/runtime.rs (7 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

**/*.rs: Use precise names; boolean names should start with is/has/should
Use en-GB-oxendict spelling and grammar in comments
Function documentation must include clear examples; test documentation should omit redundant examples
Keep code files ≤ 400 lines; split long switch/dispatch logic by feature; move large test data to external files
Disallow Clippy warnings
Fix warnings emitted during tests in code rather than silencing them
Extract helper functions for long functions; adhere to separation of concerns and CQRS
Group related parameters into meaningful structs when functions have many parameters
Consider using Arc for large error returns to reduce data size
Each Rust module must begin with a module-level //! comment describing purpose and utility
Document public APIs with Rustdoc /// comments to enable cargo doc generation
Prefer immutable data; avoid unnecessary mut
Handle errors with Result instead of panicking where feasible
Avoid unsafe code unless necessary and document any usage clearly
Place function attributes after doc comments
Do not use return in single-line functions
Use predicate functions for conditional criteria with more than two branches
Do not silence lints except as a last resort
Lint suppressions must be tightly scoped and include a clear reason
Prefer #[expect(..)] over #[allow(..)] for lints
Prefer .expect() over .unwrap()
Use concat!() to combine long string literals rather than escaping newlines
Prefer single-line function bodies where appropriate (e.g., pub fn new(id: u64) -> Self { Self(id) })
Prefer semantic error enums deriving std::error::Error via thiserror for inspectable conditions

Files:

  • src/server/runtime.rs

⚙️ CodeRabbit Configuration File

**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.

  • Adhere to single responsibility and CQRS

  • Place function attributes after doc comments.

  • Do not use return in single-line functions.

  • Move conditionals with >2 branches into a predicate function.

  • Avoid unsafe unless absolutely necessary.

  • Every module must begin with a //! doc comment that explains the module's purpose and utility.

  • Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar

  • Lints must not be silenced except as a last resort.

    • #[allow] is forbidden.
    • Only narrowly scoped #[expect(lint, reason = "...")] is allowed.
    • No lint groups, no blanket or file-wide suppression.
    • Include FIXME: with link if a fix is expected.
  • Where code is only used by specific features, it must be conditionally compiled or a conditional expectation for unused_code applied.

  • Use rstest fixtures for shared setup and to avoid repetition between tests.

  • Replace duplicated tests with #[rstest(...)] parameterised cases.

  • Prefer mockall for mocks/stubs.

  • Prefer .expect() over .unwrap()

  • Ensure that any API or behavioural changes are reflected in the documentation in docs/

  • Ensure that any completed roadmap steps are recorded in the appropriate roadmap in docs/

  • Files must not exceed 400 lines in length

    • Large modules must be decomposed
    • Long match statements or dispatch tables should be decomposed by domain and collocated with targets
    • Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.

Files:

  • src/server/runtime.rs
{src,tests}/**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

Write unit and behavioural tests for new functionality

Files:

  • src/server/runtime.rs
🧬 Code Graph Analysis (1)
src/server/runtime.rs (2)
src/server/config/mod.rs (2)
  • local_addr (216-218)
  • new (45-57)
src/server/test_util.rs (1)
  • factory (18-20)
🔍 MCP Research (1 server)

Deepwiki:

  • Document WireframeServer: src/server.rs contains an "Accept Error Recovery" snippet that initializes backoff with Duration::from_millis(10), doubles the delay on each accept error, and caps it at Duration::from_secs(1) while logging the accept error (see WireframeServer: src/server.rs:392 and src/server.rs:425-429)
  • Document WireframeServer: several places describe the worker/task architecture using a shared Arc among worker tasks (e.g., WireframeServer worker pool and diagrams referencing Arc) — code/docs still reference Arc as the shared listener (see WireframeServer: src/server.rs:49-75)
🔇 Additional comments (5)
src/server/runtime.rs (5)

23-27: Generalise the accept loop behind AcceptListener (good abstraction).

Define a small, focused trait for acceptance and local_addr and keep it pub(super). This cleanly decouples the accept loop from TcpListener and enables deterministic testing. Bound Send + Sync at call sites rather than the trait, which is the right choice.


29-36: TcpListener implementation is correct and minimal.

Delegate to the inherent methods directly. Keep the one-liner for local_addr as-is; it’s concise and idiomatic.


59-66: Backoff defaults align with documented standard.

Initial delay of 10ms and cap of 1s match the “Accept Error Recovery” defaults in WireframeServer docs.


373-387: Shut-down path test is solid.

Spawn the loop, cancel, close the tracker, and assert timely completion under a timeout. This gives good confidence in the cancellation precedence with select! { biased; }.


390-409: MockListener is minimal and effective.

Record timestamps on each accept attempt and return errors. Keep it simple and thread-safe with Mutex<...>.

Comment thread src/server/runtime.rs
Comment thread src/server/runtime.rs
Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 file reviewed, no comments

Edit Code Review Bot Settings | Greptile

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🔭 Outside diff range comments (6)
src/server/runtime.rs (6)

236-284: Make back-off sleep cancellable to avoid delayed shutdown.

Cancellation during back-off currently waits until sleep(delay) completes before exiting, delaying shutdown. Gate the sleep with select! so the loop exits immediately on shutdown.

Apply this diff:

                 Err(e) => {
                     let local_addr = listener.local_addr().ok();
                     tracing::warn!(error = ?e, ?local_addr, "accept error");
-                    sleep(delay).await;
-                    delay = (delay * 2).min(backoff_config.max_delay);
+                    // Wait for either shutdown or the back-off delay before retrying.
+                    select! {
+                        () = shutdown.cancelled() => break,
+                        _ = sleep(delay) => {}
+                    }
+                    delay = (delay * 2).min(backoff_config.max_delay);
                 }

88-96: Correct error semantics in run documentation.

run never propagates transient accept failures; it logs and continues with back-off. It returns an error only for pre-run issues (e.g., missing listener). Align the docs with behaviour.

Apply this diff:

-    /// # Errors
-    ///
-    /// Returns an [`io::Error`] if accepting a connection fails.
+    /// # Errors
+    ///
+    /// Returns an [`io::Error`] if the server was not properly initialised (e.g., no listener
+    /// was bound) before running. Transient `accept` failures are logged and retried with back-off.

127-131: Correct error semantics in run_with_shutdown documentation.

This method does not return errors for runtime accept failures; it logs and retries. It returns an error only if the server was not bound.

Apply this diff:

-    /// # Errors
-    ///
-    /// Returns an [`io::Error`] if accepting a connection fails during runtime.
+    /// # Errors
+    ///
+    /// Returns an [`io::Error`] only if the server was not bound before starting. Runtime `accept`
+    /// failures are logged and retried with exponential back-off.

236-256: Enforce all documented BackoffConfig invariants.

Add a debug assertion ensuring max_delay is non-zero and initial_delay is non-zero (already covered), and document that max_delay must be ≥ 1ms explicitly if that’s a requirement.

Apply this diff:

     debug_assert!(
         backoff_config.initial_delay >= Duration::from_millis(1),
         "initial_delay must be at least 1ms",
     );
     debug_assert!(
         backoff_config.initial_delay <= backoff_config.max_delay,
         "initial_delay must not exceed max_delay",
     );
+    debug_assert!(
+        backoff_config.max_delay >= Duration::from_millis(1),
+        "max_delay must be at least 1ms"
+    );

1-472: Split this module to keep files ≤ 400 lines.

This file is 472 lines; the guideline caps files at 400. Move tests into tests/server/runtime.rs (integration) or a sibling src/server/runtime/tests.rs (with #[cfg(test)]) to reduce size. Keep the runtime code focused.

I can generate the new test module layout if you want.


275-280: Augment logs with next retry delay.

Emit the current delay in the warning to aid diagnostics when accept flaps.

Apply this diff:

-                    tracing::warn!(error = ?e, ?local_addr, "accept error");
+                    tracing::warn!(error = ?e, ?local_addr, ?delay, "accept error; retrying after back-off");
♻️ Duplicate comments (1)
src/server/runtime.rs (1)

38-50: Remove empty doc lines to satisfy style checks.

Tidy doc comments by removing standalone /// lines.

Apply this diff:

-///
-/// Controls retry behaviour when `accept()` calls fail on the server's TCP listener.
+/// Controls retry behaviour when `accept()` calls fail on the server's TCP listener.
 /// The back-off starts at `initial_delay` and doubles on each failure, capped at `max_delay`.
-///
-///
+///
 /// # Default Values
-///
 /// - `initial_delay`: 10 milliseconds
-///
 /// - `max_delay`: 1 second
-///
 ///
 /// # Invariants
 ///
 /// - `initial_delay` must not exceed `max_delay`
 /// - `initial_delay` must be at least 1 millisecond
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 74bf9cd and 3c3cad4.

📒 Files selected for processing (1)
  • src/server/runtime.rs (7 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

**/*.rs: Use precise names; boolean names should start with is/has/should
Use en-GB-oxendict spelling and grammar in comments
Function documentation must include clear examples; test documentation should omit redundant examples
Keep code files ≤ 400 lines; split long switch/dispatch logic by feature; move large test data to external files
Disallow Clippy warnings
Fix warnings emitted during tests in code rather than silencing them
Extract helper functions for long functions; adhere to separation of concerns and CQRS
Group related parameters into meaningful structs when functions have many parameters
Consider using Arc for large error returns to reduce data size
Each Rust module must begin with a module-level //! comment describing purpose and utility
Document public APIs with Rustdoc /// comments to enable cargo doc generation
Prefer immutable data; avoid unnecessary mut
Handle errors with Result instead of panicking where feasible
Avoid unsafe code unless necessary and document any usage clearly
Place function attributes after doc comments
Do not use return in single-line functions
Use predicate functions for conditional criteria with more than two branches
Do not silence lints except as a last resort
Lint suppressions must be tightly scoped and include a clear reason
Prefer #[expect(..)] over #[allow(..)] for lints
Prefer .expect() over .unwrap()
Use concat!() to combine long string literals rather than escaping newlines
Prefer single-line function bodies where appropriate (e.g., pub fn new(id: u64) -> Self { Self(id) })
Prefer semantic error enums deriving std::error::Error via thiserror for inspectable conditions

Files:

  • src/server/runtime.rs

⚙️ CodeRabbit Configuration File

**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.

  • Adhere to single responsibility and CQRS

  • Place function attributes after doc comments.

  • Do not use return in single-line functions.

  • Move conditionals with >2 branches into a predicate function.

  • Avoid unsafe unless absolutely necessary.

  • Every module must begin with a //! doc comment that explains the module's purpose and utility.

  • Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar

  • Lints must not be silenced except as a last resort.

    • #[allow] is forbidden.
    • Only narrowly scoped #[expect(lint, reason = "...")] is allowed.
    • No lint groups, no blanket or file-wide suppression.
    • Include FIXME: with link if a fix is expected.
  • Where code is only used by specific features, it must be conditionally compiled or a conditional expectation for unused_code applied.

  • Use rstest fixtures for shared setup and to avoid repetition between tests.

  • Replace duplicated tests with #[rstest(...)] parameterised cases.

  • Prefer mockall for mocks/stubs.

  • Prefer .expect() over .unwrap()

  • Ensure that any API or behavioural changes are reflected in the documentation in docs/

  • Ensure that any completed roadmap steps are recorded in the appropriate roadmap in docs/

  • Files must not exceed 400 lines in length

    • Large modules must be decomposed
    • Long match statements or dispatch tables should be decomposed by domain and collocated with targets
    • Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.

Files:

  • src/server/runtime.rs
{src,tests}/**/*.rs

📄 CodeRabbit Inference Engine (AGENTS.md)

Write unit and behavioural tests for new functionality

Files:

  • src/server/runtime.rs
🧬 Code Graph Analysis (1)
src/server/runtime.rs (3)
src/server/config/mod.rs (2)
  • local_addr (216-218)
  • new (45-57)
tests/preamble.rs (1)
  • oneshot (71-71)
src/server/test_util.rs (1)
  • factory (18-20)
🔍 MCP Research (1 server)

Deepwiki:

🔇 Additional comments (2)
src/server/runtime.rs (2)

439-446: LGTM: Assert the initial accept happens immediately.

The additional assertion for the first immediate accept call resolves the earlier feedback and strengthens test determinism.


447-470: LGTM: Deterministic back-off test with paused time.

The test cleanly asserts the 5ms → 10ms → 20ms sequence using start_paused, advance, and yield_now(), and cancels/awaits cleanly.

Comment thread src/server/runtime.rs
Comment thread src/server/runtime.rs Outdated
Comment thread src/server/runtime.rs Outdated
Comment thread src/server/runtime.rs
Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, no comments

Edit Code Review Bot Settings | Greptile

@leynos
Copy link
Copy Markdown
Owner Author

leynos commented Aug 12, 2025

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 12, 2025

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🔭 Outside diff range comments (5)
src/server/runtime.rs (5)

320-320: Replace unwrap() with .expect(...) to satisfy project guidelines.

Avoid unwrap() in tests per the coding guidelines.

Apply this diff:

-        assert!(result.unwrap().is_ok());
+        assert!(result.expect("server did not finish in time").is_ok());

363-363: Replace unwrap() with .expect(...) to satisfy project guidelines.

Avoid unwrap() in tests per the coding guidelines.

Apply this diff:

-        assert!(result.unwrap().is_ok());
+        assert!(result.expect("server did not finish in time").is_ok());

95-101: Correct the “Errors” section for run: accept failures are retried, not returned.

The accept loop handles errors with exponential back-off; run only errors when there is no bound listener.

Apply this diff:

-    /// # Errors
-    ///
-    /// Returns an [`io::Error`] if accepting a connection fails.
+    /// # Errors
+    ///
+    /// Returns an [`io::Error`] if the server was not bound to a listener.
+    /// Accept failures are retried with exponential back-off and do not surface as errors.

132-135: Align run_with_shutdown error docs with actual behaviour.

This function does not bubble up accept errors; it only errors if no listener was bound.

Apply this diff:

-    /// # Errors
-    ///
-    /// Returns an [`io::Error`] if accepting a connection fails during runtime.
+    /// # Errors
+    ///
+    /// Returns an [`io::Error`] if the server was not bound to a listener.
+    /// Accept failures are retried with exponential back-off and do not surface as errors.

288-465: Reduce module size below 400 lines by extracting tests.

The file is 466 lines. Adhere to the 400-line limit. Move the #[cfg(test)] mod tests block into a sibling test module or integration tests to keep the runtime module focused and maintainable.

Follow-up outline:

  • Create src/server/runtime/tests.rs (or tests/accept_backoff.rs) and move the test module there.
  • Keep MockAcceptListener generation in the same module as the trait (you already gate it with #[cfg_attr(test, automock)]), so tests can import super::MockAcceptListener.
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 3c3cad4 and 9a3c324.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (2)
  • Cargo.toml (1 hunks)
  • src/server/runtime.rs (7 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*.rs

⚙️ CodeRabbit Configuration File

**/*.rs: * Seek to keep the cyclomatic complexity of functions no more than 12.

  • Adhere to single responsibility and CQRS

  • Place function attributes after doc comments.

  • Do not use return in single-line functions.

  • Move conditionals with >2 branches into a predicate function.

  • Avoid unsafe unless absolutely necessary.

  • Every module must begin with a //! doc comment that explains the module's purpose and utility.

  • Comments and docs must follow en-GB-oxendict (-ize / -our) spelling and grammar

  • Lints must not be silenced except as a last resort.

    • #[allow] is forbidden.
    • Only narrowly scoped #[expect(lint, reason = "...")] is allowed.
    • No lint groups, no blanket or file-wide suppression.
    • Include FIXME: with link if a fix is expected.
  • Where code is only used by specific features, it must be conditionally compiled or a conditional expectation for unused_code applied.

  • Use rstest fixtures for shared setup and to avoid repetition between tests.

  • Replace duplicated tests with #[rstest(...)] parameterised cases.

  • Prefer mockall for mocks/stubs.

  • Prefer .expect() over .unwrap()

  • Ensure that any API or behavioural changes are reflected in the documentation in docs/

  • Ensure that any completed roadmap steps are recorded in the appropriate roadmap in docs/

  • Files must not exceed 400 lines in length

    • Large modules must be decomposed
    • Long match statements or dispatch tables should be decomposed by domain and collocated with targets
    • Large blocks of inline data (e.g., test fixtures, constants or templates) must be moved to external files and inlined at compile-time or loaded at run-time.

Files:

  • src/server/runtime.rs
🧬 Code Graph Analysis (1)
src/server/runtime.rs (2)
src/server/config/mod.rs (2)
  • local_addr (216-218)
  • new (45-57)
src/server/test_util.rs (1)
  • factory (18-20)
🔇 Additional comments (3)
Cargo.toml (1)

43-43: Add mockall for test-only mocking — LGTM.

Keep mocking confined to tests as you’ve done. This aligns with the test guidelines.

src/server/runtime.rs (2)

251-258: Validate back-off invariants — LGTM.

The debug assertions correctly enforce documented invariants and fail fast in debug builds.


441-444: Deterministic timing approach — LGTM.

Use of #[tokio::test(start_paused = true)], advance, and yield_now deterministically validates the 5ms → 10ms → 20ms back-off sequence. The initial immediate accept assertion is correctly enforced.

Also applies to: 452-463

Comment thread src/server/runtime.rs
@leynos leynos force-pushed the codex/add-async-test-for-accept_loop-backoff branch from 1662717 to 2ad2597 Compare August 12, 2025 22:45
Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 file reviewed, no comments

Edit Code Review Bot Settings | Greptile

@leynos
Copy link
Copy Markdown
Owner Author

leynos commented Aug 12, 2025

@coderabbitai new GitHub issue, please:

288-465: Reduce module size below 400 lines by extracting tests.

The file is 466 lines. Adhere to the 400-line limit. Move the #[cfg(test)] mod tests block into a sibling test module or integration tests to keep the runtime module focused and maintainable.

Follow-up outline:

Create src/server/runtime/tests.rs (or tests/accept_backoff.rs) and move the test module there.
Keep MockAcceptListener generation in the same module as the trait (you already gate it with #[cfg_attr(test, automock)]), so tests can import super::MockAcceptListener.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Aug 12, 2025

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

I'll create a GitHub issue for reducing the module size by extracting tests.

@leynos I've created a GitHub issue to track the module size reduction task. The issue includes your specific outline for extracting the tests while keeping the MockAcceptListener generation properly accessible.


🏁 Script executed:

#!/bin/bash
# Create GitHub issue for extracting tests to reduce module size
gh issue create \
  --title "Reduce module size below 400 lines by extracting tests" \
  --body "## Problem

The runtime module (src/server/runtime.rs) is currently 466 lines, exceeding the 400-line limit. Move the \`#[cfg(test)] mod tests\` block into a sibling test module or integration tests to keep the runtime module focused and maintainable.

## Follow-up outline

1. Create \`src/server/runtime/tests.rs\` (or \`tests/accept_backoff.rs\`) and move the test module there.
2. Keep \`MockAcceptListener\` generation in the same module as the trait (already gated with \`#[cfg_attr(test, automock)]\`), so tests can import \`super::MockAcceptListener\`.

## Context

- Lines 288-465 contain the test module that should be extracted
- This issue was identified during PR review

## Backlinks

- PR: https://github.com/leynos/wireframe/pull/297
- Comment: https://github.com/leynos/wireframe/pull/297#discussion_r1879740000

Requested by: @leynos" \
  --assignee leynos

Length of output: 996


@leynos Successfully created GitHub issue #307: Reduce module size below 400 lines by extracting tests

The issue includes your detailed follow-up outline and has been assigned to you.

@leynos leynos merged commit 1f1a430 into main Aug 12, 2025
5 checks passed
@leynos leynos deleted the codex/add-async-test-for-accept_loop-backoff branch August 12, 2025 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add async test for accept_loop backoff behaviour

1 participant