{"id":16800013,"url":"https://github.com/dajudge/buql","last_synced_at":"2025-10-09T12:41:19.889Z","repository":{"id":137027635,"uuid":"204985661","full_name":"dajudge/BuQL","owner":"dajudge","description":"A Bulk Query Library","archived":false,"fork":false,"pushed_at":"2019-10-30T21:20:33.000Z","size":336,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-17T05:17:03.922Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","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/dajudge.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-08-28T17:21:42.000Z","updated_at":"2019-10-30T21:20:35.000Z","dependencies_parsed_at":"2023-03-13T10:58:39.635Z","dependency_job_id":null,"html_url":"https://github.com/dajudge/BuQL","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dajudge/BuQL","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dajudge%2FBuQL","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dajudge%2FBuQL/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dajudge%2FBuQL/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dajudge%2FBuQL/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dajudge","download_url":"https://codeload.github.com/dajudge/BuQL/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dajudge%2FBuQL/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279001435,"owners_count":26083078,"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-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","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-10-13T09:30:29.922Z","updated_at":"2025-10-09T12:41:19.849Z","avatar_url":"https://github.com/dajudge.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BuQL - A Bulk Query Library \nModern streaming applications often process thousands of messages per second. Classical RDMBS implementations\ncan easily become a bottleneck in your architecture when DB access is performed on a per-message basis.\n\nBuQL uses a specialized SQL generation engine that can retrieve a large number of result sets in a streamlined\nfashion to greatly reduce the communication overhead found in systems that hit the database once (or even \nmultiple times!) for each processed message.\n\n## Compatibility\nBuQL has automated tests verifying proper functionality with the following databases:\n* H2\n* PostgreSQL (with PostGIS extension)\n* MariaDB\n\n## Running a bulk query with BuQL (concept)\nIn order to simplify data retrieval, BuQL uses reflection to simplify implementation of the data access logic\nyou want to execute. All you need to do is provide some Java Beans for passing in query parameters / getting\nout results and an interface you use to describe the queries you want to execute. \n\nExample:\n```java\n// Provide a result object\npublic class Person {\n    private Long id;\n    private String firstName;\n    private String lastName;\n    private String street;\n    private String zip;\n    private String country;\n   \n    [... getters / setters ...]\n}\n\n// Define the repository interface\n@Table(\"person\")\npublic interface PersonRepository {\n    // This is a traditional one-by-one data access method (still\n    // supported in BuQL)\n    Person findById(Long ids);\n    \n    // This is a bulk data access method. The Strings in the Map types \n    // correlate the returned results to the query objects you passed in.\n    Map\u003cString, Person\u003e getById(Map\u003cString, Long\u003e ids);\n    \n    // Queries can also be more complex objects. Even sophisticated\n    // hierarchical predicates can be formulated.\n    Map\u003cString, List\u003cPerson\u003e\u003e findByFilter(Map\u003cString, ComplexPersonFilter\u003e ids);\n}\n\n// In your business logic:\nPersonRepository repo = buql.up(PersonRepository.class);\nMap\u003cString Long\u003e ids = new HashMap\u003c\u003e();\nids.put(\"ID0\", 42);\nids.put(\"ID1\", 7);\nids.put(\"ID2\", 10);\nMap\u003cString, Person\u003e result = repo.getById(ids);\nSystem.out.println(\"Hello, 42. Your name is: \" + result.get(\"ID0\").getFirstName());\n``` ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdajudge%2Fbuql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdajudge%2Fbuql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdajudge%2Fbuql/lists"}