-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
115 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,8 @@ | |
*.so | ||
*.dylib | ||
bin/* | ||
dashboard/containers/** | ||
dashboard/bin/* | ||
**/main | ||
**/*.out | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,31 +15,29 @@ The main executable is a [custom controller] that manages resources of kind | |
[LoadTest]. This controller must be deployed to the cluster before load tests | ||
can be run on it. The controller is implemented with [kubebuilder]. | ||
|
||
There is also a set of tools used to prepare prebuilt images and run batches of | ||
tests. These tools are used to generate the dashboard linked from the [gRPC | ||
performance benchmarking] page. For more information, see | ||
[tools](tools/README.md). | ||
There is also a set of [tools](tools/README.md) used to generate load test | ||
configurations, prepare prebuilt images and run batches of tests. These tools | ||
are used to run batches of tests for continuous integration. | ||
|
||
[Examples](config/samples/README.md) of load test configurations in the | ||
supported languages are also provided. | ||
|
||
[custom controller]: cmd/controller/main.go | ||
[grpc performance benchmarking]: https://grpc.io/docs/guides/benchmarking/ | ||
[kubebuilder]: https://kubebuilder.io | ||
[loadtest]: config/crd/bases/e2etest.grpc.io_loadtests.yaml | ||
|
||
## Contributing | ||
## Dashboard | ||
|
||
Welcome! Please read [how to contribute](CONTRIBUTING.md) before proceeding. | ||
The data generated in continuous integration are saved to [BigQuery], and | ||
displayed on a public dashboard linked from the [gRPC performance benchmarking] | ||
page. | ||
|
||
This project includes third party dependencies as git submodules. Be sure to | ||
initialize and update them when setting up a development environment: | ||
For more information, and to build your own dashboard, see | ||
[dashboard](dashboard/README.md). | ||
|
||
```shell | ||
# Init/update during the clone | ||
git clone --recursive https://github.com/grpc/test-infra.git # HTTPS | ||
git clone --recursive [email protected]:grpc/test-infra.git # SSH | ||
[bigquery]: https://cloud.google.com/bigquery | ||
[grpc performance benchmarking]: https://grpc.io/docs/guides/benchmarking/ | ||
|
||
# (or) Init/update after the clone | ||
git submodule update --init | ||
``` | ||
## Contributing | ||
|
||
Welcome! Please read [how to contribute](CONTRIBUTING.md) before proceeding. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
# Dashboard | ||
|
||
This folder contains the components necessary to build and deploy a dashboard to | ||
visualize gRPC OSS benchmarking results. | ||
|
||
gRPC OSS benchmarks save results to [BigQuery]. The dashboard consists of two | ||
components: | ||
|
||
1. A [Postgres replicator], to transfer the results to a Postgres database. | ||
1. A Grafana dashboard, to displays the results from the Postgres database. | ||
|
||
These components can be built and deployed manually using the | ||
[Makefile](Makefile) (see [manual build](#manual-build)). | ||
|
||
Notice that the dashboard build is independent from the top-level build. | ||
|
||
## Configuration | ||
|
||
The configuration of the Postgres replicator is defined in a YAML file. The | ||
default configuration is defined here, in template form: | ||
|
||
- [config/postgres_replicator/default/config.yaml][postgres replicator config] | ||
|
||
For more information, see [Postgres replicator]. | ||
|
||
The configuration of the Grafana dashboard is defined in a set of dashboards | ||
specified in JSON files. The default configuration is defined here: | ||
|
||
- [config/grafana/dashboards/default/][grafana dashboard config] | ||
|
||
The continuous integration dashboard linked from the [gRPC performance | ||
benchmarking] page uses the default configuration. The variables | ||
`REPLICATOR_CONFIG_TEMPLATE` and `DASHBOARDS_CONFIG_DIR` can be set to build | ||
dashboards with different configurations. | ||
|
||
[bigquery]: https://cloud.google.com/bigquery | ||
[grafana dashboard config]: config/grafana/dashboards/default/ | ||
[grpc performance benchmarking]: https://grpc.io/docs/guides/benchmarking/ | ||
[postgres replicator]: cmd/postgres_replicator/README.md | ||
[postgres replicator config]: config/postgres_replicator/default/config.yaml | ||
|
||
## Manual build | ||
|
||
Several environment variables must be set before building and deploying. The | ||
table below shows the names and values of the variables in our main dashboard: | ||
|
||
| Variable | Value | | ||
| --------------------------- | --------------------------------------------- | | ||
| `BQ_PROJECT_ID` | `grpc-testing` | | ||
| `CLOUD_SQL_INSTANCE` | `grpc-testing:us-central1:grafana-datasource` | | ||
| `GCP_DATA_TRANSFER_SERVICE` | `postgres-replicator` | | ||
| `GCP_GRAFANA_SERVICE` | `grafana` | | ||
| `GCP_PROJECT_ID` | `grpc-testing` | | ||
| `GRAFANA_ADMIN_PASS` | \*\*\* | | ||
| `PG_DATABASE` | `datasource` | | ||
| `PG_PASS` | \*\*\* | | ||
| `PG_USER` | `grafana-user` | | ||
|
||
Docker files that can be used to build and deploy the Postgres replicator and | ||
Grafana dashboard are then created with the following commands: | ||
|
||
```shell | ||
make configure-replicator | ||
make configure-dashboard | ||
``` | ||
|
||
## Cloud build | ||
|
||
The continuous integration dashboard is built and deployed with [Cloud Build], | ||
using the configuration specified in [cloudbuild.yaml](cloudbuild.yaml). | ||
|
||
The use of Cloud Build allows the dashboard to be redeployed automatically on | ||
configuration changes. In addition, it allows passwords such as `PG_PASS` and | ||
`GRAFANA_ADMIN_PASS` to be stored as secrets in the cloud project. | ||
|
||
[cloud build]: https://cloud.google.com/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters