{"id":13342895,"url":"https://github.com/mridehalgh/xk6-sqs","last_synced_at":"2025-03-12T02:32:46.114Z","repository":{"id":47441766,"uuid":"347434922","full_name":"mridehalgh/xk6-sqs","owner":"mridehalgh","description":"A k6 extension to produce to an SQS queue","archived":false,"fork":false,"pushed_at":"2024-06-10T09:29:06.000Z","size":442,"stargazers_count":6,"open_issues_count":3,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-07-30T21:05:35.090Z","etag":null,"topics":["k6","k6-extension","sqs","xk6"],"latest_commit_sha":null,"homepage":"","language":"Go","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/mridehalgh.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":"2021-03-13T17:30:03.000Z","updated_at":"2024-03-14T23:45:32.000Z","dependencies_parsed_at":"2024-06-19T15:01:54.794Z","dependency_job_id":"ec1e973c-1d92-4ec7-9b7f-14bbb385a877","html_url":"https://github.com/mridehalgh/xk6-sqs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mridehalgh%2Fxk6-sqs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mridehalgh%2Fxk6-sqs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mridehalgh%2Fxk6-sqs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mridehalgh%2Fxk6-sqs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mridehalgh","download_url":"https://codeload.github.com/mridehalgh/xk6-sqs/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221265583,"owners_count":16788059,"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","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":["k6","k6-extension","sqs","xk6"],"created_at":"2024-07-29T19:30:06.719Z","updated_at":"2024-10-24T02:30:39.452Z","avatar_url":"https://github.com/mridehalgh.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# xk6-sqs\n\nThis is a [k6](https://go.k6.io/k6) extension using the [xk6](https://github.com/grafana/xk6) system.\n\n| :exclamation: This is a proof of concept, isn't supported by the k6 team or by the maintainer, and may break in the future. USE AT YOUR OWN RISK! |\n|------|\n\n## Build\n\nTo build a `k6` binary with this extension, first ensure you have the prerequisites:\n\n- [Go toolchain](https://go101.org/article/go-toolchain.html)\n- Git\n\nThen, install [xk6](https://github.com/grafana/xk6) and build your custom k6 binary with the SQS extension:\n\n1. Install `xk6`:\n\n  ```shell\n  $ go install go.k6.io/xk6/cmd/xk6@latest\n  ```\n\n2. Build the binary:\n\n  ```shell\n  $ xk6 build --with github.com/mridehalgh/xk6-sqs@latest\n  ```\n\n## AWS credentials\n\nThis plugin uses the AWS SDK Go v2 default credential chain. It looks for credentials in the following order:\n\n1. Environment variables.\n   1. Static Credentials (`AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, `AWS_SESSION_TOKEN`)\n   2. Web Identity Token (`AWS_WEB_IDENTITY_TOKEN_FILE`)\n1. Shared configuration files.\n   1. SDK defaults to `credentials` file under `.aws` folder that is placed in the home folder on your computer.\n   1. SDK defaults to `config` file under `.aws` folder that is placed in the home folder on your computer.\n1. If your application uses an ECS task definition or RunTask API operation, IAM role for tasks.\n1. If your application is running on an Amazon EC2 instance, IAM role for Amazon EC2.\n\nSource: https://aws.github.io/aws-sdk-go-v2/docs/configuring-sdk/#specifying-credentials\n\n## Example\n\n```javascript\nimport sqs from 'k6/x/sqs';\n\nconst client = sqs.newClient()\n\n\nexport default function () {\n    const params = {\n        DelaySeconds: 0,\n        MessageAttributes: {\n            \"Title\": {\n                DataType: \"String\",\n                StringValue: \"The Whistler\"\n            },\n            \"Author\": {\n                DataType: \"String\",\n                StringValue: \"John Grisham\"\n            },\n            \"WeeksOn\": {\n                DataType: \"Number\",\n                StringValue: \"6\"\n            }\n        },\n        MessageBody: \"Information about current NY Times fiction bestseller for week of 12/11/2016.\",\n        // MessageDeduplicationId: \"TheWhistler\",  // Required for FIFO queues\n        // MessageGroupId: \"Group1\",  // Required for FIFO queues\n        QueueUrl: \"QUEUE_URL\"\n    };\n\n    sqs.send(client,params)\n}\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmridehalgh%2Fxk6-sqs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmridehalgh%2Fxk6-sqs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmridehalgh%2Fxk6-sqs/lists"}