{"id":20038978,"url":"https://github.com/defra/cdp-perf-test-suite-template","last_synced_at":"2026-06-10T15:31:53.932Z","repository":{"id":233856648,"uuid":"787906843","full_name":"DEFRA/cdp-perf-test-suite-template","owner":"DEFRA","description":"Git repository for cdp-perf-test-suite-template","archived":false,"fork":false,"pushed_at":"2025-07-08T15:26:38.000Z","size":23,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-07-08T16:24:57.823Z","etag":null,"topics":["cdp","performance","repository","template","test-suite"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DEFRA.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-04-17T12:10:51.000Z","updated_at":"2025-07-08T15:26:40.000Z","dependencies_parsed_at":"2024-06-03T14:32:20.704Z","dependency_job_id":"aa850dc5-3461-4932-b561-fb2839623ddd","html_url":"https://github.com/DEFRA/cdp-perf-test-suite-template","commit_stats":null,"previous_names":["defra/cdp-perf-test-suite-template"],"tags_count":2,"template":true,"template_full_name":null,"purl":"pkg:github/DEFRA/cdp-perf-test-suite-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DEFRA%2Fcdp-perf-test-suite-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DEFRA%2Fcdp-perf-test-suite-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DEFRA%2Fcdp-perf-test-suite-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DEFRA%2Fcdp-perf-test-suite-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DEFRA","download_url":"https://codeload.github.com/DEFRA/cdp-perf-test-suite-template/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DEFRA%2Fcdp-perf-test-suite-template/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34159249,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-10T02:00:07.152Z","response_time":89,"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":["cdp","performance","repository","template","test-suite"],"created_at":"2024-11-13T10:34:36.079Z","updated_at":"2026-06-10T15:31:53.923Z","avatar_url":"https://github.com/DEFRA.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cdp-perf-test-suite-template\n\nA JMeter based test runner for the CDP Platform.\n\n- [Licence](#licence)\n  - [About the licence](#about-the-licence)\n\n## Build\n\nTest suites are built automatically by the [.github/workflows/publish.yml](.github/workflows/publish.yml) action whenever a change are committed to the `main` branch.\nA successful build results in a Docker container that is capable of running your tests on the CDP Platform and publishing the results to the CDP Portal.\n\n## Run\n\nThe performance test suites are designed to be run from the CDP Portal.\nThe CDP Platform runs test suites in much the same way it runs any other service, it takes a docker image and runs it as an ECS task, automatically provisioning infrastructure as required.\n\n## Local Testing with Docker Compose\n\nYou can run the entire performance test stack locally using Docker Compose, including LocalStack, Redis, and the target service. This is useful for development, integration testing, or verifying your test scripts **before committing to `main`**, which will trigger GitHub Actions to build and publish the Docker image.\n\n### Build the Docker image\n\n```bash\ndocker compose build --no-cache development\n```\n\nThis ensures any changes to `entrypoint.sh` or other scripts are picked up properly.\n\n---\n\n### Start the full test stack\n\n```bash\ndocker compose up --build\n```\n\nThis brings up:\n\n* `development`: the container that runs your performance tests\n* `localstack`: simulates AWS S3, SNS, SQS, etc.\n* `redis`: backing service for cache\n* `service`: the application under test\n\nOnce all services are healthy, your performance tests will automatically start.\n\n---\n\n### Replace `service-name` in Compose File\n\nIn the `docker-compose.yml`, make sure to replace:\n\n```yaml\nimage: defradigital/service-name:${SERVICE_VERSION:-latest}\n```\n\nwith the actual name of your service’s image.\n\nThis is the service under test, which must expose a `/health` endpoint and listen on port `3000`.\n\n---\n\n### Notes\n\n* S3 bucket is expected to be `s3://test-results`, automatically created inside LocalStack.\n* Logs and reports are written to `./reports` on your host.\n* `entrypoint.sh` should contain the logic to wait for dependencies and kick off the test run.\n* The `depends_on` healthchecks ensure services like `localstack` and `service` are ready before tests start.\n* If you make changes to test scripts or entrypoints, rerun with:\n\n```bash\ndocker compose up --build\n```\n\n## Local Testing with LocalStack\n\n### Build a new Docker image\n```\ndocker build . -t my-performance-tests\n```\n### Create a Localstack bucket\n```\naws --endpoint-url=localhost:4566 s3 mb s3://my-bucket\n```\n\n### Run performance tests\n\n```\ndocker run \\\n-e S3_ENDPOINT='http://host.docker.internal:4566' \\\n-e RESULTS_OUTPUT_S3_PATH='s3://my-bucket' \\\n-e AWS_ACCESS_KEY_ID='test' \\\n-e AWS_SECRET_ACCESS_KEY='test' \\\n-e AWS_SECRET_KEY='test' \\\n-e AWS_REGION='eu-west-2' \\\nmy-performance-tests\n```\n\ndocker run -e S3_ENDPOINT='http://host.docker.internal:4566' -e RESULTS_OUTPUT_S3_PATH='s3://cdp-infra-dev-test-results/cdp-portal-perf-tests/95a01432-8f47-40d2-8233-76514da2236a' -e AWS_ACCESS_KEY_ID='test' -e AWS_SECRET_ACCESS_KEY='test' -e AWS_SECRET_KEY='test' -e AWS_REGION='eu-west-2' -e ENVIRONMENT='perf-test' my-performance-tests\n\n\n## Licence\n\nTHIS INFORMATION IS LICENSED UNDER THE CONDITIONS OF THE OPEN GOVERNMENT LICENCE found at:\n\n\u003chttp://www.nationalarchives.gov.uk/doc/open-government-licence/version/3\u003e\n\nThe following attribution statement MUST be cited in your products and applications when using this information.\n\n\u003e Contains public sector information licensed under the Open Government licence v3\n\n### About the licence\n\nThe Open Government Licence (OGL) was developed by the Controller of Her Majesty's Stationery Office (HMSO) to enable\ninformation providers in the public sector to license the use and re-use of their information under a common open\nlicence.\n\nIt is designed to encourage use and re-use of information freely and flexibly, with only a few conditions.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdefra%2Fcdp-perf-test-suite-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdefra%2Fcdp-perf-test-suite-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdefra%2Fcdp-perf-test-suite-template/lists"}