-
-
Notifications
You must be signed in to change notification settings - Fork 1
Update Cookbook docs: rename rustapi to rustapi-rs and add jobs learning path #86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…ance learning path - Updated `docs/cookbook/src/learning/README.md` to include `rustapi-jobs` in the Learning Path (Microservices & Enterprise). - Updated `docs/cookbook/src/recipes/file_uploads.md` to use `rustapi-rs` dependency and imports. - Updated `docs/cookbook/src/recipes/db_integration.md` to use `rustapi_rs` imports. - Updated `docs/cookbook/src/recipes/websockets.md` to use `rustapi_rs` imports. - Updated `docs/cookbook/src/concepts/handlers.md` to use `rustapi_rs` imports. - Ensured consistency of version `0.1.275` across updated files. Co-authored-by: Tuntii <121901995+Tuntii@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Updates the RustAPI Cookbook documentation to align crate naming (rustapi-rs / rustapi_rs) with the current codebase and expands the Learning Path to include background job processing guidance.
Changes:
- Renames Rust imports from
rustapi::...torustapi_rs::...in multiple cookbook pages. - Updates a Cargo.toml snippet to use
rustapi-rs(and addsrustapi-jobspointers in the Learning Path). - Extends the Learning Path with “Background Tasks/Jobs” and references to
rustapi-jobs.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/cookbook/src/recipes/websockets.md | Updates import to rustapi_rs::prelude::* for WebSockets recipe. |
| docs/cookbook/src/recipes/file_uploads.md | Renames dependency/import paths to rustapi-rs / rustapi_rs. |
| docs/cookbook/src/recipes/db_integration.md | Updates import to rustapi_rs::prelude::* for DB recipe. |
| docs/cookbook/src/learning/README.md | Adds background tasks/jobs guidance and rustapi-jobs links. |
| docs/cookbook/src/concepts/handlers.md | Updates handler concept example import to rustapi_rs::prelude::*. |
Comments suppressed due to low confidence (1)
docs/cookbook/src/recipes/file_uploads.md:66
DefaultBodyLimitis not defined in the RustAPI crates (it looks like an Axum type). In RustAPI, request size limits are configured viaRustApi::body_limit(...)(or by addingrustapi_core::middleware::BodyLimitLayer). Update this snippet to use the framework’s actual body limit API so the example compiles and matches runtime behavior.
use rustapi_rs::extract::DefaultBodyLimit;
let app = RustApi::new()
.route("/upload", post(upload_file))
// Limit request body to 10MB
.layer(DefaultBodyLimit::max(10 * 1024 * 1024));
| | 6 | `job-queue` | Background processing, Redis/Postgres backends | | ||
|
|
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
job-queue is introduced as a new example in the Microservices learning path, but it’s not referenced anywhere else in this doc (e.g., the “Examples by Category” or “Feature Matrix” sections). Either add it to those sections as well, or clarify that it’s a conceptual step (not necessarily an existing example project) to avoid confusing readers.
| | 6 | `job-queue` | Background processing, Redis/Postgres backends | | |
| | 6 | Background jobs (conceptual) | Background processing with `rustapi-jobs`, Redis/Postgres backends | | |
| > Note: The **Background jobs (conceptual)** step refers to using the `rustapi-jobs` crate rather than a standalone example project. |
| 3. **Building Blocks**: Try the [Creating Resources](../recipes/crud_resource.md) recipe. | ||
| 4. **Security**: Implement [JWT Authentication](../recipes/jwt_auth.md) and [CSRF Protection](../recipes/csrf_protection.md). | ||
| 5. **Advanced**: Explore [Performance Tuning](../recipes/high_performance.md) and [HTTP/3](../recipes/http3_quic.md). | ||
| 6. **Background Tasks**: Master [rustapi-jobs](../crates/rustapi_jobs.md) for async processing. |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new content mixes the terms “Background Tasks” and “Background Jobs” for the same concept. Pick one term and use it consistently across the learning path and the enterprise table to reduce ambiguity.
| 6. **Background Tasks**: Master [rustapi-jobs](../crates/rustapi_jobs.md) for async processing. | |
| 6. **Background Jobs**: Master [rustapi-jobs](../crates/rustapi_jobs.md) for async processing. |
| ```toml | ||
| [dependencies] | ||
| rustapi = { version = "0.1.275", features = ["multipart"] } | ||
| rustapi-rs = { version = "0.1.275", features = ["multipart"] } |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Cargo.toml snippet enables a multipart feature on rustapi-rs, but crates/rustapi-rs/Cargo.toml does not define a multipart feature. This dependency line will fail for users copying it. Remove the feature flag or replace it with the correct feature set (if any) needed for multipart support.
| rustapi-rs = { version = "0.1.275", features = ["multipart"] } | |
| rustapi-rs = "0.1.275" |
| use rustapi_rs::prelude::*; | ||
| use rustapi_rs::extract::Multipart; | ||
| use tokio::fs::File; |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rustapi_rs::extract::Multipart does not appear to exist in this codebase (there is no extract module exported by rustapi-rs). Multipart is already available from rustapi_rs::prelude::* (or via rustapi_rs::Multipart). Update the import to a valid path or drop it entirely to avoid a non-compiling example.
| use rustapi_ws::{WebSocket, WebSocketUpgrade, Message}; | ||
| use rustapi::prelude::*; | ||
| use rustapi_rs::prelude::*; | ||
| use std::sync::Arc; |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This example now imports rustapi_rs::prelude::*, but the dependency snippet only includes rustapi-ws (and not rustapi-rs). As written, users won’t be able to compile RustApi::new(), routing helpers like get, or the rustapi_rs import. Consider switching to the supported pattern: depend on rustapi-rs with features = ["ws"] and import WebSocket types via rustapi_rs::ws::{...} (or ensure both crates are listed explicitly).
| ```rust | ||
| use rustapi::prelude::*; | ||
| use rustapi_rs::prelude::*; | ||
|
|
||
| #[derive(Deserialize)] |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The dependencies list in this recipe does not include rustapi-rs, but the code sample imports rustapi_rs::prelude::* and uses RustApi/routing helpers. Add rustapi-rs = "0.1.275" (and any needed feature flags) to the Dependencies section so the example is copy/pasteable and compiles.
This PR updates the RustAPI Cookbook documentation to ensure consistency with the current codebase version (0.1.275) and package naming conventions.
Key changes:
rustapiinstead of the correctrustapi-rs(inCargo.tomldependencies) andrustapi_rs(in Rust imports). This affected recipes for file uploads, database integration, websockets, and handler concepts.docs/cookbook/src/learning/README.md, guiding users to therustapi-jobscrate for async processing in Microservices and Enterprise architectures.0.1.275.PR created automatically by Jules for task 12846515349818711293 started by @Tuntii