Skip to content

Commit 6a71384

Browse files
committed
add super linter
Signed-off-by: Gregor Zeitlinger <[email protected]>
1 parent 8cbecd9 commit 6a71384

File tree

23 files changed

+78
-104
lines changed

23 files changed

+78
-104
lines changed

CONTRIBUTING.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
Prometheus uses GitHub to manage reviews of pull requests.
44

5-
* If you have a trivial fix or improvement, go ahead and create a pull request,
5+
- If you have a trivial fix or improvement, go ahead and create a pull request,
66
addressing (with `@...`) the maintainer of this repository (see
77
[MAINTAINERS.md](MAINTAINERS.md)) in the description of the pull request.
88

9-
* If you plan to do something more involved, first discuss your ideas
9+
- If you plan to do something more involved, first discuss your ideas
1010
on our [mailing list](https://groups.google.com/forum/?fromgroups#!forum/prometheus-developers).
1111
This will avoid unnecessary work and surely give you and us a good deal
1212
of inspiration.
@@ -21,7 +21,7 @@ Run `./mvnw spotless:apply` to format the code (only changed files) before commi
2121

2222
If you're getting errors when running tests:
2323

24-
- Make sure that the IDE uses only the "Maven Shade" dependency of "prometheus-metrics-exposition-formats" and the "prometheus-metrics-tracer*" dependencies.
24+
- Make sure that the IDE uses only the "Maven Shade" dependency of "prometheus-metrics-exposition-formats" and the "prometheus-metrics-tracer\*" dependencies.
2525

2626
### Avoid failures while running tests
2727

MAINTAINERS.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
* Fabian Stäber <[email protected]> @fstab
2-
* Doug Hoard <[email protected]> @dhoard
3-
* Tom Wilkie <[email protected]> @tomwilkie
4-
* Gregor Zeitlinger <[email protected]> @zeitlinger
1+
- Fabian Stäber <[email protected]> @fstab
2+
- Doug Hoard <[email protected]> @dhoard
3+
- Tom Wilkie <[email protected]> @tomwilkie
4+
- Gregor Zeitlinger <[email protected]> @zeitlinger

RELEASING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
## Create a Release
22

3-
1. Go to https://github.com/prometheus/client_java/releases/new
3+
1. Go to <https://github.com/prometheus/client_java/releases/new>
44
2. Click on "Choose a tag", enter the tag name (e.g. `v0.1.0`), and click "Create a new tag".
55
3. Click on "Generate release notes" to auto-generate the release notes based on the commits since the last release.
66
4. Click on "Publish release".

benchmarks/README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
Benchmarks
2-
----------
1+
## Benchmarks
32

43
## How to Run
54

@@ -17,8 +16,8 @@ java -jar ./benchmarks/target/benchmarks.jar CounterBenchmark
1716

1817
See Javadoc of the benchmark classes:
1918

20-
* [CounterBenchmark](https://github.com/prometheus/client_java/blob/1.0.x/benchmarks/src/main/java/io/prometheus/metrics/benchmarks/CounterBenchmark.java)
21-
* [HistogramBenchmark](https://github.com/prometheus/client_java/blob/1.0.x/benchmarks/src/main/java/io/prometheus/metrics/benchmarks/HistogramBenchmark.java)
19+
- [CounterBenchmark](https://github.com/prometheus/client_java/blob/1.0.x/benchmarks/src/main/java/io/prometheus/metrics/benchmarks/CounterBenchmark.java)
20+
- [HistogramBenchmark](https://github.com/prometheus/client_java/blob/1.0.x/benchmarks/src/main/java/io/prometheus/metrics/benchmarks/HistogramBenchmark.java)
2221

2322
## What Prometheus Java client optimizes for
2423

examples/example-exemplars-tail-sampling/README.md

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
Exemplars with OpenTelemetry's Tail Sampling
2-
--------------------------------------------
1+
## Exemplars with OpenTelemetry's Tail Sampling
32

43
## Background: What are Exemplars?
54

@@ -66,13 +65,13 @@ This should generate two Java services `.../example-greeting-service/target/exam
6665

6766
The `docker-compose` file will run the example with the following containers:
6867

69-
* `hello-world-app`: Java service described above, with the OpenTelemetry Java instrumentation agent attached for distrubted tracing.
70-
* `greeting-service`: Java service described above, with the OpenTelemetry Java instrumentation agent attached for distrubted tracing.
71-
* `collector`: OpenTelemetry collector for receiving the distributed traces, performing _tail sampling_, and forwarding them to `tempo`.
72-
* `prometheus`: Prometheus server scraping metrics from `hello-world-app`, `greeting-service`, and `tempo`.
73-
* `tempo`: Trace database.
74-
* `grafana`: Has `prometheus` and `tempo` configured as data sources, and is configured with an example dashboard with Exemplars enabled.
75-
* `k6`: The [k6](https://k6.io/) load test tool for generating 50 requests / second on the Java services.
68+
- `hello-world-app`: Java service described above, with the OpenTelemetry Java instrumentation agent attached for distrubted tracing.
69+
- `greeting-service`: Java service described above, with the OpenTelemetry Java instrumentation agent attached for distrubted tracing.
70+
- `collector`: OpenTelemetry collector for receiving the distributed traces, performing _tail sampling_, and forwarding them to `tempo`.
71+
- `prometheus`: Prometheus server scraping metrics from `hello-world-app`, `greeting-service`, and `tempo`.
72+
- `tempo`: Trace database.
73+
- `grafana`: Has `prometheus` and `tempo` configured as data sources, and is configured with an example dashboard with Exemplars enabled.
74+
- `k6`: The [k6](https://k6.io/) load test tool for generating 50 requests / second on the Java services.
7675

7776
With the Java services described above available in the `target/` directories, you can run the example with:
7877

@@ -109,13 +108,9 @@ processors:
109108
{
110109
name: keep-exemplars,
111110
type: string_attribute,
112-
string_attribute: { key: "exemplar", values: [ "true" ] }
113-
},
114-
{
115-
name: keep-10-percent,
116-
type: probabilistic,
117-
probabilistic: { sampling_percentage: 10 }
111+
string_attribute: { key: "exemplar", values: ["true"] },
118112
},
113+
{ name: keep-10-percent, type: probabilistic, probabilistic: { sampling_percentage: 10 } },
119114
]
120115
```
121116

examples/example-exemplars-tail-sampling/config/grafana-dashboards.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: 1
22

33
providers:
4-
- name: 'Example Dashboard'
4+
- name: "Example Dashboard"
55
type: file
66
options:
77
path: /etc/grafana/example-dashboard.json

examples/example-exemplars-tail-sampling/config/grafana-datasources.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
apiVersion: 1
22

33
datasources:
4-
54
- name: Prometheus
65
type: prometheus
76
uid: prometheus
Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
1-
import http from 'k6/http';
1+
import http from "k6/http";
22

33
export const options = {
4-
scenarios: {
5-
constant_request_rate: {
6-
executor: 'constant-arrival-rate',
7-
rate: 50,
8-
timeUnit: '1s',
9-
duration: '2h',
10-
preAllocatedVUs: 10,
11-
maxVUs: 100,
12-
},
4+
scenarios: {
5+
constant_request_rate: {
6+
executor: "constant-arrival-rate",
7+
rate: 50,
8+
timeUnit: "1s",
9+
duration: "2h",
10+
preAllocatedVUs: 10,
11+
maxVUs: 100,
1312
},
13+
},
1414
};
1515

1616
export default function () {
17-
http.get('http://localhost:8080');
17+
http.get("http://localhost:8080");
1818
}

examples/example-exemplars-tail-sampling/config/otelcol-config.yaml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,9 @@ processors:
1313
{
1414
name: keep-exemplars,
1515
type: string_attribute,
16-
string_attribute: { key: "exemplar", values: [ "true" ] }
17-
},
18-
{
19-
name: keep-10-percent,
20-
type: probabilistic,
21-
probabilistic: { sampling_percentage: 10 }
16+
string_attribute: { key: "exemplar", values: ["true"] },
2217
},
18+
{ name: keep-10-percent, type: probabilistic, probabilistic: { sampling_percentage: 10 } },
2319
]
2420

2521
exporters:

examples/example-exporter-httpserver/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,6 @@ uptime_seconds_total 301.0
2828

2929
The exporter supports a `debug` URL parameter to quickly view other formats in your Web browser:
3030

31-
* [http://localhost:9400/metrics?debug=text](http://localhost:9400/metrics?debug=text): Prometheus text format, same as without the `debug` option.
32-
* [http://localhost:9400/metrics?debug=openmetrics](http://localhost:9400/metrics?debug=openmetrics): OpenMetrics text format.
33-
* [http://localhost:9400/metrics?debug=prometheus-protobuf](http://localhost:9400/metrics?debug=prometheus-protobuf): Text representation of the Prometheus protobuf format.
31+
- [http://localhost:9400/metrics?debug=text](http://localhost:9400/metrics?debug=text): Prometheus text format, same as without the `debug` option.
32+
- [http://localhost:9400/metrics?debug=openmetrics](http://localhost:9400/metrics?debug=openmetrics): OpenMetrics text format.
33+
- [http://localhost:9400/metrics?debug=prometheus-protobuf](http://localhost:9400/metrics?debug=prometheus-protobuf): Text representation of the Prometheus protobuf format.

0 commit comments

Comments
 (0)