Skip to content

Commit

Permalink
Merge branch 'master' into szuro-patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
szuro authored Apr 12, 2024
2 parents 59ab3d1 + cee0123 commit 64bd72a
Show file tree
Hide file tree
Showing 136 changed files with 46,368 additions and 7,770 deletions.
20 changes: 13 additions & 7 deletions .drone/drone.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,17 @@ local run(name, commands) = {
};

[
pipeline('build', [
run('lint-fmt', [
'make install-ci-deps',
'make lint-fmt',
'make lint-mixins',
]),
]),
pipeline(
'build', [
run('lint-fmt', [
'make install-ci-deps',
'make lint-fmt',
'make lint-mixins',
]),
run('tests', [
'make install-ci-deps',
'make tests',
]),
]
),
]
7 changes: 6 additions & 1 deletion .drone/drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,17 @@ steps:
- make lint-mixins
image: golang:1.18
name: lint-fmt
- commands:
- make install-ci-deps
- make tests
image: golang:1.18
name: tests
trigger:
event:
include:
- pull_request
---
kind: signature
hmac: 78a1dae3b7fa280bb32281b3ddbdbc7d1a9a7ab54681a00ed536876e2bdca55d
hmac: 569cd1940689a70b907683e347d832a4a2809c1dbf23035ab036acf88b72a57a

...
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ lint-mixins:
done; \
exit $$RESULT

tests:
pushd . && cd ./common-lib && make vendor && make tests

drone:
drone jsonnet --stream --source .drone/drone.jsonnet --target .drone/drone.yml --format yaml
drone lint .drone/drone.yml
Expand Down
2 changes: 2 additions & 0 deletions apache-cassandra-mixin/.lint
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ exclusions:
- panel: "Keyspaces count"
- panel: "Repair jobs started"
- panel: "Repair jobs completed"
panel-datasource-rule:
reason: "Loki datasource variable is being named as loki_datasource now while linter expects 'datasource'"
template-datasource-rule:
reason: "Based on new convention we are using variable names prometheus_datasource and loki_datasource where as linter expects 'datasource'"
template-instance-rule:
Expand Down
6 changes: 3 additions & 3 deletions apache-cassandra-mixin/alerts/alerts.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
{
alert: 'HintsStoredOnNode',
expr: |||
cassandra_storage_totalhints_count > %(alertsWarningHintsStored1m)s
increase(cassandra_storage_totalhints_count[5m]) > %(alertsWarningHintsStored1m)s
||| % $._config,
'for': '1m',
labels: {
Expand Down Expand Up @@ -115,7 +115,7 @@
{
alert: 'HighCpuUsage',
expr: |||
jvm_process_cpu_load * 100 > %(alertsCriticalHighCpuUsage5m)s
jvm_process_cpu_load{job=~"integrations/apache-cassandra"} * 100 > %(alertsCriticalHighCpuUsage5m)s
||| % $._config,
'for': '5m',
labels: {
Expand All @@ -133,7 +133,7 @@
{
alert: 'HighMemoryUsage',
expr: |||
sum(jvm_memory_usage_used_bytes{area="Heap"}) / sum(jvm_physical_memory_size) * 100 > %(alertsCriticalHighMemoryUsage5m)s
sum(jvm_memory_usage_used_bytes{job=~"integrations/apache-cassandra", area="Heap"}) / sum(jvm_physical_memory_size{job=~"integrations/apache-cassandra"}) * 100 > %(alertsCriticalHighMemoryUsage5m)s
||| % $._config,
'for': '5m',
labels: {
Expand Down
4 changes: 4 additions & 0 deletions apache-couchdb-mixin/config.libsonnet
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
{
_config+:: {
enableMultiCluster: false,
couchDBSelector: if self.enableMultiCluster then 'job=~"$job", cluster=~"$cluster"' else 'job=~"$job"',
multiClusterSelector: 'job=~"$job"',

dashboardTags: ['apache-couchdb-mixin'],
dashboardPeriod: 'now-1h',
dashboardTimezone: 'default',
Expand Down
Loading

0 comments on commit 64bd72a

Please sign in to comment.