Skip to content

Reduce file size hotspots by splitting into submodules #428

@coderabbitai

Description

@coderabbitai

Context

Related to PR #424 which demonstrates the pattern for modularisation by refactoring the connection module.

Request from: @leynos
Source: #424

Objective

Reduce file size hotspots by splitting large files (all >400 LOC) into feature-focused submodules and, where possible, moving #[cfg(test)] blocks into sibling *_tests.rs files.

Files to refactor

The following files should be split into feature-focused submodules:

  • src/connection.rs:1
  • src/extractor.rs:1
  • src/app/builder.rs:1
  • src/client/builder.rs:1
  • src/app/frame_handling.rs:1
  • src/codec/recovery.rs:1
  • src/server/config/tests.rs:1

Approach

Follow the pattern established in PR #424:

  • Extract logically cohesive components into dedicated submodules
  • Maintain public API compatibility
  • Move test code into separate *_tests.rs files where appropriate
  • Ensure all tests continue to pass after refactoring

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions