Giter Site home page Giter Site logo

k6-tutorial's Introduction

k6-tutorial

This Project is a tutorial for k6.

How to test?

This project contains two types of testing method.

  • local
  • kubernetes

Local

In this case, you need to set up InfluxDB and Grafana locally before running the test. After setting them up, you can initiate the test.

cd ./_bin/
./run-local-test-out-influxdb_v1.sh

Kubernetes

In this case, InfluxDB and Grafana must be set up on an external host before testing. The k6 job running on the Kubernetes cluster can then connect to the InfluxDB instance to store the test results.

cd ./_bin/
./run-k8s-test.sh

or

kubectl apply -f ./_helm/kube_apply.yaml

those two script gives same result.

Real-time metrics (Outputs)

You can monitor test clients using influxdb and grafana integration.

How to init

cd ./outputs/influxdb-grafana
docker-compose up -d

Configure the grafana dashboard using k6 template. See k6 template for grafana

Sample Test Target

Run sample target spring-petclinic service. Spring petclinic is sample project maintained by spring. This project contains target service in sampleTestTarget/spring-petclinic as a git submodule. You can run mysql and postgre for this service using docker-compose easily.

After that, you can build java application using maven or gradle. Once you build the java application, you can either run it directly on the host or run it with Docker.

k6-tutorial's People

Contributors

asprin107 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.