{"id":21204846,"url":"https://github.com/andyron/readmybatis","last_synced_at":"2025-07-21T16:32:45.482Z","repository":{"id":80187283,"uuid":"515232889","full_name":"andyRon/ReadMyBatis","owner":"andyRon","description":null,"archived":false,"fork":false,"pushed_at":"2024-04-28T10:04:01.000Z","size":6095,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-14T22:47:03.609Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/andyRon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-07-18T15:07:24.000Z","updated_at":"2024-04-28T10:04:11.000Z","dependencies_parsed_at":"2024-11-20T20:41:15.568Z","dependency_job_id":"578cdb0f-51eb-4347-b2ed-08f0f6c46d9a","html_url":"https://github.com/andyRon/ReadMyBatis","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/andyRon/ReadMyBatis","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andyRon%2FReadMyBatis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andyRon%2FReadMyBatis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andyRon%2FReadMyBatis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andyRon%2FReadMyBatis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andyRon","download_url":"https://codeload.github.com/andyRon/ReadMyBatis/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andyRon%2FReadMyBatis/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266334252,"owners_count":23912930,"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","status":"online","status_checked_at":"2025-07-21T11:47:31.412Z","response_time":64,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"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":"2024-11-20T20:41:11.809Z","updated_at":"2025-07-21T16:32:45.455Z","avatar_url":"https://github.com/andyRon.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ReadMyBatis\n\n\n\nJDBC \n\n```java\n```\n\n\n\n\n\n\n\nMybatis3 小结\n\n```java\n\nDataSourceFactory\n\tUnpooledDataSourceFactory❤️\n  \tPooledDataSourceFactory\n  JndiDataSourceFactory\n```\n\n\n\n\n\n\n\n### 源码看#{}和${}的区别\n\nhttps://blog.csdn.net/Zhs901026/article/details/103911937\n\n\n\n- `#{param}`不仅仅涉及参数替换，还涉及参数类型的处理，这是`${}`不能代替的，也就是说使用`${}`来替换#{}本身就不符合mybatis的使用原则，所以两者并没有安全性比较的意义！\n- `#{param}`只能用于statementType=“PREPARED\"情况，因为#{param}在mybatis内部肯定会被替换成”?\"的，这就要求必须使用`PreparedStatement`来处理，这是mybatis内部原理实现的，并不是很多博文所说的#{param}会加上\"引号\"云云…如果#{param}代表的是数字，mybatis断然不会给该数字加\"引号\"的。所以说#{}能有效预防sql注入是因为底层使用了PreparedStatement，而不是其他任何原因。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandyron%2Freadmybatis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandyron%2Freadmybatis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandyron%2Freadmybatis/lists"}