Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/grafana/k6
A modern load testing tool, using Go and JavaScript - https://k6.io
https://github.com/grafana/k6
es6 go golang hacktoberfest javascript load-generator load-testing performance
Last synced: 7 days ago
JSON representation
A modern load testing tool, using Go and JavaScript - https://k6.io
- Host: GitHub
- URL: https://github.com/grafana/k6
- Owner: grafana
- License: agpl-3.0
- Created: 2016-03-21T15:30:24.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2024-04-13T13:06:32.000Z (7 months ago)
- Last Synced: 2024-04-14T07:16:49.352Z (7 months ago)
- Topics: es6, go, golang, hacktoberfest, javascript, load-generator, load-testing, performance
- Language: Go
- Homepage:
- Size: 35.5 MB
- Stars: 23,258
- Watchers: 326
- Forks: 1,175
- Open Issues: 395
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE.md
- Code of conduct: CODE_OF_CONDUCT.md
- Codeowners: CODEOWNERS
- Security: SECURITY.md
- Support: SUPPORT.md
Awesome Lists containing this project
- awesome-go - grafana/k6 - https://k6.io|20,300| (Popular)
- awesome - grafana/k6 - A modern load testing tool, using Go and JavaScript - https://k6.io (Go)
- awesome-ops - grafana/k6 - 3.0|25536|2016-03-21|2024-09-30 | 一款现代化的负载测试工具,使用 Go 和 JavaScript 实现 | (测试压测)
- awesome-ccamel - grafana/k6 - A modern load testing tool, using Go and JavaScript - https://k6.io (Go)
- awesome - grafana/k6 - A modern load testing tool, using Go and JavaScript - https://k6.io (Go)
- awesome-repositories - grafana/k6 - A modern load testing tool, using Go and JavaScript - https://k6.io (Go)
- awesome-github-star - k6 - https://k6.io | grafana | 21602 | (Go)
- awesome-list - k6 - https://k6.io | grafana | 13464 | (Go)
- awesome-starred - grafana/k6 - A modern load testing tool, using Go and JavaScript - https://k6.io (javascript)
- awesome-platform-engineering - k6- performance/load testing tool
- awesome-go - k6 - A modern load testing tool, using Go and JavaScript. Stars:`25.8K`. (Software Packages / DevOps Tools)
- awesome-learning - Grafana K6
- my-awesome - grafana/k6 - generator,load-testing,performance pushed_at:2024-10 star:25.8k fork:1.3k A modern load testing tool, using Go and JavaScript - https://k6.io (Go)
- StarryDivineSky - grafana/k6
README
Like unit testing, for performance
Modern load testing for developers and testers in the DevOps era.
Download ·
Documentation ·
Community Forum ·
Public Roadmap
**k6** is a modern load-testing tool, built on [our years of experience](https://k6.io/about) in the performance and testing industries.
It's built to be powerful, extensible, and full-featured. The key design goal is to provide **the best developer experience**.Its core features are:
- **Configurable load generation.** Even lower-end machines can simulate lots of traffic.
- **Tests as code.** Reuse scripts, modularize logic, version control, and integrate tests with your CI.
- **A full-featured API.** The scripting API is packed with features that help you simulate real application traffic.
- **An embedded JavaScript engine.** The performance of Go, the scripting familiarity of JavaScript.
- **Multiple Protocol support**. HTTP, WebSockets, gRPC, Browser, and more.
- **Large extension ecosystem.** You can extend k6 to support your needs. And many people have already shared their extensions with the community!
- **Flexible metrics storage and visualization**. Summary statistics or granular metrics, exported to the service of your choice.
- **Native integration with Grafana cloud**. [SaaS solution](https://grafana.com/products/cloud/k6/) for test execution, metrics correlation, data analysis, and more.This is what load testing looks like in the 21st century.
## Example script
```js
import http from "k6/http";
import { check, sleep } from "k6";// Test configuration
export const options = {
thresholds: {
// Assert that 99% of requests finish within 3000ms.
http_req_duration: ["p(99) < 3000"],
},
// Ramp the number of virtual users up and down
stages: [
{ duration: "30s", target: 15 },
{ duration: "1m", target: 15 },
{ duration: "20s", target: 0 },
],
};// Simulated user behavior
export default function () {
let res = http.get("https://test-api.k6.io/public/crocodiles/1/");
// Validate response status
check(res, { "status was 200": (r) => r.status == 200 });
sleep(1);
}
```You can run scripts like this on the CLI, or in your CI, or across a Kubernetes cluster.
## Documentation
The docs cover all aspects of using k6. Some highlights include:
- [Get Started](https://grafana.com/docs/k6/latest/). Install, run a test, inspect results.
- [HTTP requests](https://grafana.com/docs/k6/latest/using-k6/http-requests/). Have your virtual users use HTTP methods.
Or, check the other [Protocols](https://grafana.com/docs/k6/latest/using-k6/protocols/).
- [Thresholds](https://grafana.com/docs/k6/latest/using-k6/thresholds/). Set goals for your test, and codify your SLOs.
- [Options](https://grafana.com/docs/k6/latest/using-k6/k6-options/). Configure your load, duration, TLS certificates, and much, much more.
- [Scenarios](https://grafana.com/docs/k6/latest/using-k6/scenarios/).
Choose how to model your workload: open models, closed models, constant RPS, fixed iterations, and more.
- [Results output](https://grafana.com/docs/k6/latest/results-output/). Study, filter, and export your test results.
- [JavaScript API](https://grafana.com/docs/k6/latest/javascript-api/). Reference and examples of all k6 modules.
- [Extensions](https://grafana.com/docs/k6/latest/extensions/). Extend k6 for new protocols and use cases.These links barely scratch the surface! If you're looking for conceptual information, you can read about [Test types](https://grafana.com/docs/k6/latest/testing-guides/test-types/), [Test strategies](https://grafana.com/docs/k6/latest/testing-guides/), or one of the many informative [Blog posts](https://k6.io/blog).
## Roadmap
Our team is dedicated to continuously improving and providing the best user experience possible. The [public roadmap](https://github.com/orgs/grafana/projects/443/views/1) covers user-oriented features, UX improvements and JavaScript support that our team will focus on. Remember that timeframes and priorities may shift, but we believe it's important to share our vision.
We hope it provides a clear overview of our plans for future development. We welcome feedback, corrections, and suggestions via GitHub to make it more comprehensive, accessible, and valuable for the community.
It's worth mentioning that we consider [upvotes (thumbs-up)](https://github.com/grafana/k6/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc) to be one of the essential metrics for determining community needs. If you want to show us the importance of a feature, please give it a thumbs-up.
## Contribute
If you want to contribute or help with the development of k6, start by reading [CONTRIBUTING.md](CONTRIBUTING.md). Before you start coding, it might be a good idea to first discuss your plans and implementation details with the k6 maintainers—especially when it comes to big changes and features. You can do this in the [GitHub issue](https://github.com/grafana/k6/issues) for the problem you're solving (create one if it doesn't exist).
> **Note:** To disclose security issues, refer to [SECURITY.md](SECURITY.md).
## Support
To get help, report bugs, suggest features, and discuss k6 with others, refer to [SUPPORT.md](SUPPORT.md).
## License
k6 is distributed under the [AGPL-3.0 license](https://github.com/grafana/k6/blob/master/LICENSE.md).