{"id":42682605,"url":"https://github.com/renthraysk/xtorm","last_synced_at":"2026-01-29T11:55:08.651Z","repository":{"id":57551597,"uuid":"258256898","full_name":"renthraysk/xtorm","owner":"renthraysk","description":"Go database API for MySQL's X Protocol.","archived":false,"fork":false,"pushed_at":"2024-03-19T14:01:17.000Z","size":144,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-03-19T15:28:19.170Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","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/renthraysk.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":"2020-04-23T15:59:52.000Z","updated_at":"2024-03-19T15:28:19.171Z","dependencies_parsed_at":"2022-09-26T18:41:31.321Z","dependency_job_id":null,"html_url":"https://github.com/renthraysk/xtorm","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/renthraysk/xtorm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renthraysk%2Fxtorm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renthraysk%2Fxtorm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renthraysk%2Fxtorm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renthraysk%2Fxtorm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/renthraysk","download_url":"https://codeload.github.com/renthraysk/xtorm/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/renthraysk%2Fxtorm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28876862,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-29T10:31:27.438Z","status":"ssl_error","status_checked_at":"2026-01-29T10:31:01.017Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2026-01-29T11:55:08.225Z","updated_at":"2026-01-29T11:55:08.620Z","avatar_url":"https://github.com/renthraysk.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Xtorm\n\n## About\n\nThis is a database API specifically for MySQL's (8.0.15+) X Protocol API. \nIt radically differs from most database APIs as it does not execute a statement at a time, but rather a complete transaction/unit of work. \n\nThis means\n* Reduced network roundtrips, only a single net.Conn Write() per unit of work\n* Transaction duration times minimised\n* No client connection state, as no tracking of\n\t* open transactions\n\t* prepared statements\n\n    Reduces complexity when using a pool of connections.\n\n* Simplified error handling, only have to check the transaction commit succeed. \n* Preparing statements and executing within the same unit of work.\n\n## Error Handling\n\nMySQL error handling is managed by MySQL expectation blocks. By opening a expectation block with the expectation of no errors, MySQL will fail all remaining statements in the block as soon as an error has occurred.\n\nSo the expected typical structure of a unit of work\n\n1. Open expectation block\n2. Prepare statements\n3. Begin transaction\n4. Insertions, updates, deletions, prepared statement executions, parameterised statement executions\n5. Commit transaction\n6. Close expectation block\n\nIf an error occurs in steps 1-4 then the commit will be skipped returning an error \"Expectation failed: no_error\". If the commit fails, then that will return an error. \n\n\n## TODO\n\n- [ ] SELECTs. No SELECT support atm.\n- [ ] Save IDs from LAST_INSERT_ID() into variables so can insert rows into multiple tables in one UoW. No protobuf method using mysql's xprotocol for SET instructions so this would have to be regular SQL \u0026 StmtExecute. Expr Variables are currently not supported in MySQL 8.0.27. \"ERROR 5153 (HY000): Mysqlx::Expr::Expr::VARIABLE is not supported yet\"\n- [ ] More/better pool implementations.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frenthraysk%2Fxtorm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frenthraysk%2Fxtorm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frenthraysk%2Fxtorm/lists"}