{"id":29179950,"url":"https://github.com/emrygun/pgmq4j","last_synced_at":"2026-04-28T15:35:56.031Z","repository":{"id":246103258,"uuid":"813834210","full_name":"emrygun/pgmq4j","owner":"emrygun","description":"Java library for pgmq, lightweight message queue built on top of PostgreSQL by @tembo-io","archived":false,"fork":false,"pushed_at":"2024-06-30T15:37:21.000Z","size":105,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-01T19:08:21.285Z","etag":null,"topics":["java","postgresql","tembo"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/emrygun.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,"zenodo":null}},"created_at":"2024-06-11T20:46:05.000Z","updated_at":"2024-06-30T15:37:24.000Z","dependencies_parsed_at":"2025-07-01T19:17:48.367Z","dependency_job_id":null,"html_url":"https://github.com/emrygun/pgmq4j","commit_stats":null,"previous_names":["emrygun/pgmq4j"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/emrygun/pgmq4j","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emrygun%2Fpgmq4j","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emrygun%2Fpgmq4j/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emrygun%2Fpgmq4j/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emrygun%2Fpgmq4j/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emrygun","download_url":"https://codeload.github.com/emrygun/pgmq4j/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emrygun%2Fpgmq4j/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32387910,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-28T14:34:11.604Z","status":"ssl_error","status_checked_at":"2026-04-28T14:32:37.009Z","response_time":56,"last_error":"SSL_read: 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":["java","postgresql","tembo"],"created_at":"2025-07-01T19:07:38.461Z","updated_at":"2026-04-28T15:35:51.022Z","avatar_url":"https://github.com/emrygun.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pgmq4j the \"pgmq Java Client Library\"\n\nThis library provides a Java interface for interacting with [PGMQ](https://github.com/tembo-io/pgmq), a message queue system built on top of PostgreSQL. \n\npgmq-client accomplishes most of primitive features of pgmq, including:\n- Creating or deleting queues\n- Sending messages\n- Reading and batch reading in normal or long polling mode\n- Archiving messages\n- Deleting and popping messages\n\n... and so on\n\n\n## Example Usages\n\nHere are some examples of how to use the library.\n\n### Create a queue:\n```java\nPGMQueueFactory pgmqFactory = new PGMQueueFactory(jsonSerializer, connectionProvider);\nPGMQueue pgmq = pgmqFactory.create();\npgmq.create(\"my_queue\");\n```\n\n### Send and read a message:\n```java\n// Send and read a message test\nTestMessage testMessage = new TestMessage(\"test\", Instant.now().getEpochSecond());\npgmq.send(\"my_queue\", testMessage);\n\nOptional\u003cTestMessage\u003e message = pgmq.read(\"my_queue\")\n    .as(TestMessage.class)\n    .visibilityTime(30)\n    .oneValue();\n```\n\n### Send and read multiple messages:\n```java\n// Send multiple messages and read values\nList\u003cTestMessage\u003e messages = Stream.generate(() -\u003e new TestMessage(\"test\", Instant.now().getEpochSecond()))\n    .limit(10)\n    .toList();\npgmq.sendBatch(queueName, messages);\n\npgmq.read(\"my_queue\")\n    .as(TestMessage.class)\n    .visibilityTime(30)\n    .polling()\n    .values(10)\n    .forEach(m -\u003e\n    LOG.info(\"Message: {}, enqueuedAt: {}, readCount: {}, vt: {}\",\n            m.getMessage(),\n            m.getEnqueuedAt(),\n            m.getReadCount(),\n            m.getVisibilityTime())\n    );\n```\n\n## Project Stage\nProject is still on development stage, and not ready for production use.\nStill requires more tests, improvements and adaptations for the Java world.\n\n\n## Contributing\n\nContributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.\n\nFeel free to open issues if you find any, I appreciate any help in making the project better.\n\n## License\n\nThis project is licensed under the terms of the MIT license. See the [LICENSE](LICENSE) file for details.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femrygun%2Fpgmq4j","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femrygun%2Fpgmq4j","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femrygun%2Fpgmq4j/lists"}