{"id":19536913,"url":"https://github.com/alexgalhardo/learning-message-queue-and-pub-sub","last_synced_at":"2026-05-05T14:33:03.663Z","repository":{"id":245495379,"uuid":"818070177","full_name":"AlexGalhardo/learning-message-queue-and-pub-sub","owner":"AlexGalhardo","description":"Simple project I created with references and examples to learn about message queues and publisher/subscriber pattern with different technologies.","archived":false,"fork":false,"pushed_at":"2024-08-17T12:04:39.000Z","size":102,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-15T15:11:49.792Z","etag":null,"topics":["aws-dynamodb","aws-s3","aws-sns","aws-sqs","bullmq","docker","docker-compose","localstack","pubsub","rabbitmq","redis","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/AlexGalhardo.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":"2024-06-21T03:25:23.000Z","updated_at":"2024-08-17T12:19:47.000Z","dependencies_parsed_at":"2024-06-29T14:25:07.182Z","dependency_job_id":"c1590759-5320-4ee4-885d-d29e26cd2a7c","html_url":"https://github.com/AlexGalhardo/learning-message-queue-and-pub-sub","commit_stats":null,"previous_names":["alexgalhardo/learning-message-queue-and-pub-sub"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/AlexGalhardo/learning-message-queue-and-pub-sub","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AlexGalhardo%2Flearning-message-queue-and-pub-sub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AlexGalhardo%2Flearning-message-queue-and-pub-sub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AlexGalhardo%2Flearning-message-queue-and-pub-sub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AlexGalhardo%2Flearning-message-queue-and-pub-sub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AlexGalhardo","download_url":"https://codeload.github.com/AlexGalhardo/learning-message-queue-and-pub-sub/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AlexGalhardo%2Flearning-message-queue-and-pub-sub/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32653552,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-05T11:29:49.557Z","status":"ssl_error","status_checked_at":"2026-05-05T11:29:48.587Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["aws-dynamodb","aws-s3","aws-sns","aws-sqs","bullmq","docker","docker-compose","localstack","pubsub","rabbitmq","redis","typescript"],"created_at":"2024-11-11T02:24:50.805Z","updated_at":"2026-05-05T14:33:03.646Z","avatar_url":"https://github.com/AlexGalhardo.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\t\u003ch1 align=\"center\"\u003eLearning Message Queues \u0026 Pub Sub\u003c/h1\u003e\n\u003c/div\u003e\n\n## Introduction\n\n- Simple project I created with references and examples to learn about message queues and publisher/subscriber pattern with different technologies.\n\n## To Do\n\n- [x] [RabbitMQ](https://www.rabbitmq.com/) Message Queue Example\n- [x] [RabbitMQ](https://www.rabbitmq.com/) PubSub Example\n- [x] [Apache Kafka](https://kafka.apache.org/) Message Queue Example\n- [x] [Apache Kafka](https://kafka.apache.org/) PubSub Example\n- [x] [Observer Pattern](https://refactoring.guru/design-patterns/observer) (GoF) Example\n- [x] [BullMQ](https://bullmq.io/) Message Queue Example\n- [x] [AWS SQS](https://aws.amazon.com/sqs/) Example using LocalStack\n- [x] [AWS SNS](https://aws.amazon.com/sns/) Example using LocalStack\n- [x] [AWS S3](https://aws.amazon.com/pm/serv-s3/) Example using LocalStack\n- [x] [AWS Dynamodb](https://aws.amazon.com/pm/dynamodb/) Example using LocalStack\n\n## Prerequisites\n- Install Bun: \u003chttps://bun.sh/docs/installation\u003e\n- Install LocalStack: \u003chttps://docs.localstack.cloud/getting-started/installation/\u003e\n- Install Docker \u0026 Docker-Compose: \u003chttps://docs.docker.com/engine/install/\u003e\n\na. Install dependencies \u0026 up docker-compose\n```bash\nsudo chmod +x setup.sh \u0026\u0026 ./setup.sh\n```\n\nb. To see RabbitMQ Management UI, go to: \u003chttp://localhost:15672\u003e\n   - Username: `guest`\n   - Password: `guest`\n\nc. To see LocalStack UI, go to: \u003chttps://app.localstack.cloud/inst/default/status\u003e\n\n## Observer Pattern Example\n\n- Credits: \u003chttps://youtu.be/ioYkXh8NhKc\u003e\n\n1. Run script\n```bash\nbun run observer-pattern\n```\n\n## RabbitMQ Message Queue Example\n\n1. Run producer (send message)\n```bash\nbun run rabbitmq-queue-producer\n```\n\n2. Run consumer (consume message)\n```bash\nbun run rabbitmq-queue-consumer\n```\n\n## RabbitMQ PubSub Example\n\n1. Run subscriber to stay listening... (receive notifications in subscriber)\n```bash\nbun run rabbitmq-pubsub-subscriber\n```\n\n2. Run publish (publish message to subscribers consume)\n```bash\nbun run rabbitmq-pubsub-publisher\n```\n\n## Apache Kafka Message Queue Example\n\n1. Run producer (send messages)\n```bash\nbun run apache-kafka-queue-producer\n```\n\n2. Run consumer (consume messages)\n```bash\nbun run apache-kafka-queue-consumer\n```\n\n## Apache Kafka PubSub Example\n\n1. Run publisher (send messages to topic x)\n```bash\nbun run apache-kafka-pubsub-publisher\n```\n\n2. Run subscriber (subscribers consume messages from topic x)\n```bash\nbun run apache-kafka-pubsub-subscriber\n```\n\n## BullMQ Message Queue Example\n\n1. Run job\n```bash\nbun run bullmq-mq-job\n```\n\n2. Run worker\n```bash\nbun run bullmq-mq-worker\n```\n\n## AWS SQS Example\n\n### CLI\n- Prerequisites\n   - Install AWS CLI: \u003chttps://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html\u003e\n   - Verify your AWS Credentials:\n\t```bash\n\taws --version\n\texport AWS_ACCESS_KEY_ID=\"test\"\n\texport AWS_SECRET_ACCESS_KEY=\"test\"\n\texport AWS_DEFAULT_REGION=\"us-east-1\"\n\taws configure --profile localstack\n\taws configure list\n\t```\n\n1. Creating QUEUE\n```bash\naws sqs create-queue --endpoint-url http://localhost:4566 --queue-name cli-test-queue --profile localstack\n```\n\n2. Listing QUEUEs\n```bash\naws sqs list-queues --endpoint-url http://localhost:4566 --profile localstack\n```\n\n3. Sending Messages\n```bash\naws sqs send-message --endpoint-url http://localhost:4566 --queue-url http://localhost:4566/000000000000/cli-test-queue --message-body \"Testing Message\" --message-attributes file://./src/aws-sqs/message.json --profile localstack\n```\n\n4. Receiving Messages\n```bash\naws sqs receive-message --endpoint-url http://localhost:4566 --queue-url http://localhost:4566/000000000000/cli-test-queue --attribute-names All --message-attribute-names All  --profile localstack\n```\n\n### Code\n1. Run example\n```bash\nbun run aws-sqs-example\n```\n\n## AWS SNS Example\n\n1. Run example\n```bash\nbun run aws-sns-example\n```\n\n## AWS S3 Example\n\n1. Run example\n```bash\nbun run aws-s3-example\n```\n\n## AWS Dynamodb Example\n\n1. Run example\n```bash\nbun run aws-dynamodb-example\n```\n\n## Images Example\n\n![rabbit-mq-management](https://github.com/AlexGalhardo/learning-message-queue-and-pub-sub/assets/19540357/cb4c3f92-c541-406b-905d-9590c0b50153)\n\n![localstack-instances](https://github.com/AlexGalhardo/learning-message-queue-and-pub-sub/assets/19540357/f0ca9af2-dd4e-4faa-be0b-0bc4c47d00df)\n\n![aws-dynamodb-example](https://github.com/AlexGalhardo/learning-message-queue-and-pub-sub/assets/19540357/e0251c63-9d3b-4499-bb47-499172487a7d)\n\n## License\n\n[MIT](http://opensource.org/licenses/MIT)\n\nCopyright (c) June 2024-present, [Alex Galhardo](https://github.com/AlexGalhardo)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexgalhardo%2Flearning-message-queue-and-pub-sub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexgalhardo%2Flearning-message-queue-and-pub-sub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexgalhardo%2Flearning-message-queue-and-pub-sub/lists"}