{"id":15523396,"url":"https://github.com/bluemoon/tide-diesel","last_synced_at":"2025-09-02T00:36:31.864Z","repository":{"id":43873116,"uuid":"456565225","full_name":"bluemoon/tide-diesel","owner":"bluemoon","description":"Tide middleware for Diesel pooled connections \u0026 transactions","archived":false,"fork":false,"pushed_at":"2022-02-15T01:08:29.000Z","size":7,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-23T05:13:34.342Z","etag":null,"topics":["diesel","rust","tide"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bluemoon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-02-07T15:32:27.000Z","updated_at":"2022-02-07T19:14:51.000Z","dependencies_parsed_at":"2022-09-02T06:54:42.948Z","dependency_job_id":null,"html_url":"https://github.com/bluemoon/tide-diesel","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bluemoon%2Ftide-diesel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bluemoon%2Ftide-diesel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bluemoon%2Ftide-diesel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bluemoon%2Ftide-diesel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bluemoon","download_url":"https://codeload.github.com/bluemoon/tide-diesel/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250372941,"owners_count":21419723,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["diesel","rust","tide"],"created_at":"2024-10-02T10:45:04.308Z","updated_at":"2025-04-23T05:13:41.584Z","avatar_url":"https://github.com/bluemoon.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tide-diesel\n\n[Tide][] middleware for [Diesel][] pooled connections \u0026amp; transactions.\n\n----\n\nA [Tide][] middleware which holds a pool of Diesel database connections, and automatically hands\neach [tide::Request][] a connection, which may transparently be either a database transaction,\nor a direct pooled database connection.\n\nWhen using this, use the `DieselRequestExt` extenstion trait to get the connection.\n\n## Examples\n\n### Basic\n```rust\n#[async_std::main]\nasync fn main() -\u003e anyhow::Result\u003c()\u003e {\n    use tide_diesel::DieselRequestExt;\n\n    let mut app = tide::new();\n    app.with(DieselMiddleware::new(\"postgres://localhost/a_database\").await?);\n\n    app.at(\"/\").post(|req: tide::Request\u003c()\u003e| async move {\n        let mut pg_conn = req.pg_conn().await;\n\n        Ok(\"\")\n    });\n    Ok(())\n}\n```\n\n\n## License\n\nLicensed under the [BlueOak Model License 1.0.0](LICENSE.md) — _[Contributions via DCO 1.1](contributing.md#developers-certificate-of-origin)_\n\n[tide::Request]: https://docs.rs/tide/0.15.0/tide/struct.Request.html\n[Diesel]: https://github.com/diesel-rs/diesel\n[Tide]: https://github.com/http-rs/tide\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbluemoon%2Ftide-diesel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbluemoon%2Ftide-diesel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbluemoon%2Ftide-diesel/lists"}