Skip to content

Conversation

@Tuntii
Copy link
Owner

@Tuntii Tuntii commented Jan 22, 2026

This pull request introduces several new features and improvements to the RustAPI project, primarily focusing on deployment tooling, HTTP/3 support, and enhanced error handling. The most significant changes include the addition of deployment commands for popular cloud platforms, support for HTTP/3 (QUIC) in the core library, and improvements to API validation error conversion.

Deployment tooling

  • Added new CLI commands and argument parsing for deployment (DeployArgs) and API client generation (ClientArgs) in crates/cargo-rustapi/src/cli.rs, and implemented the deploy command with support for Docker, Fly.io, Railway, and Shuttle.rs, including configuration file generation and usage instructions. [1] [2] [3] [4] [5] [6]
  • Updated dependencies in crates/cargo-rustapi/Cargo.toml to include serde_yaml for YAML support and reqwest for remote spec fetching, and added feature flags for optional remote spec support. [1] [2]

HTTP/3 (QUIC) support

  • Added HTTP/3-related dependencies (quinn, h3, h3-quinn, rustls, rustls-pemfile, rcgen) to both the workspace and core crate, and introduced feature flags to enable HTTP/3 and development mode. [1] [2] [3]
  • Implemented new methods in RustApi for running HTTP/3 servers, including support for self-signed certificates for development and dual-stack (HTTP/1.1 + HTTP/3) operation, with documentation and usage examples. [1] [2]

Core library improvements

  • Refactored response construction to consistently use the unified Body type in the core library, improving maintainability and future extensibility. [1] [2] [3] [4]
  • Added a new method to run the server with a graceful shutdown signal, improving control over server lifecycle.

Error handling

  • Added a conversion from rustapi_validate::v2::ValidationErrors to ApiError, allowing for better error reporting and compatibility with the latest validation library updates.

Miscellaneous

  • Updated contact email in README.md to a new address.

Introduces internationalization for validation error messages using rust-i18n, adds English and Turkish locale files, and refactors validation rules to use message keys for localization. Removes dependency on the validator crate, updates derive macro to support validation groups, and enhances documentation and test coverage. Also improves middleware, extractor, and router documentation with usage examples.
Refactored TestUser to use validate_with_group and validate_async_with_group methods in v2 tests. Updated test credit card numbers in rich_rules.rs to use a valid Visa test card and a clearly invalid number. Adjusted custom validation message syntax for credit card and IPv4 fields.
Introduces a unified `Body` type in rustapi-core to support both full and streaming HTTP responses, updating all relevant response construction to use this abstraction. Adds support for `custom_async` validation rules in rustapi-macros and rustapi-validate, including parsing, macro generation, and a test for async custom validation. Updates server to support graceful shutdown and streaming bodies for SSE and stream endpoints.
Introduces HTTP/3 server implementation using Quinn and h3, with configuration and self-signed certificate support for development. Adds new features 'http3' and 'http3-dev', updates dependencies, and extends RustApi with methods to run HTTP/3 and dual-stack servers. Includes a test for graceful shutdown and refactors streaming response body handling.
Introduces a new hateoas module in rustapi-core for HAL-style hypermedia links, resource wrappers, and pagination. Exports HATEOAS types in the core lib. Refactors and extends ReDoc HTML generation in rustapi-openapi, adding configuration options and simplifying theme handling. Updates public API to expose ReDoc helpers and configuration types.
Introduces new CLI commands for generating API clients from OpenAPI specs (supporting Rust, TypeScript, and Python) and for deploying to Docker, Fly.io, Railway, and Shuttle.rs. Adds `CustomMetricsBuilder` for custom Prometheus metrics in `rustapi-core`. Updates dependencies and features in Cargo.toml to support remote spec loading and new functionality.
Copilot AI review requested due to automatic review settings January 22, 2026 22:35

This comment was marked as spam.

Tuntii added 15 commits January 23, 2026 01:58
Introduces support for custom OpenAPI schema types for path parameters via the new `#[rustapi::param]` macro and `.param()` method on Route. Updates core, macros, and documentation to reflect this feature. Adds documentation and recipes for HTTP/3 (QUIC) support and deployment tooling, including new CLI commands for client generation and deployment configs.
Replaced usage of `Full<Bytes>` with `ResponseBody` in response construction and type signatures across rustapi-core, rustapi-toon, and rustapi-ws. This change unifies response body handling and prepares the codebase for more flexible response implementations.
Replaces direct usage of http_body_util::Full and Bytes with crate-specific ResponseBody::from in response construction across rustapi-core, rustapi-toon, and rustapi-view. Also adds explicit 'Transfer-Encoding: chunked' header for streaming responses. This improves consistency and abstraction in response handling.
Standardized usage of crate::response::Body::Full in compression middleware for consistency. Removed unused imports and cleaned up import statements across multiple modules to improve code clarity and maintainability.
Updated validation group matching logic to ensure Default group rules only apply to all contexts, while specific groups do not apply to Default context. Adjusted related tests for correct symmetry and rule application. Also removed unused imports from several modules for code cleanliness.
Updated all middleware layers and tests to wrap response bodies with ResponseBody::Full instead of using http_body_util::Full directly. This change improves consistency and prepares the codebase for unified response body handling across the project.
Updated middleware and cache layers to wrap response bodies using the custom Body::Full and ResponseBody::Full enums instead of using http_body_util::Full directly. This change improves consistency in response handling and prepares for future extensibility. Also removed an unused import in response.rs tests.
Updated test cases across middleware modules to use rustapi_core::ResponseBody instead of http_body_util::Full for response bodies. Also removed unnecessary mut from stack variable declarations in jwt tests for clarity and consistency.
Introduced a new 'coverage' job in the GitHub Actions workflow to generate and upload code coverage reports using cargo-tarpaulin. Also removed check.log and check_ws.log files.
Moved example documentation below trait definitions for FromRequestParts, FromRequest, and MiddlewareLayer to improve clarity. Simplified string replacement in client generation, fixed page calculation in hateoas, improved schema type handling in app, and updated connection join logic in server. These changes enhance code readability and correctness.
@Tuntii Tuntii linked an issue Jan 23, 2026 that may be closed by this pull request
3 tasks
Copy link
Owner Author

@Tuntii Tuntii left a comment

Choose a reason for hiding this comment

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

LGMT! :3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] UUID path param defined as integer in OpenAPI output

2 participants