Skip to content

Commit

Permalink
feat: Add out-of-band node metrics (#299)
Browse files Browse the repository at this point in the history
# Description

This PR adds the following features:

- [x] Add system metrics
- [x] Add process metrics
- [x] Add network metrics
- [x] Add load average metric
- [x] Add database size metric
- [x] Add OS and kernel log entry
- [x] Add Prometheus exporter with endpoint for scraping
- [x] Move integration test utils into a separate module
- [x] Break Homestar process kills into *nix and windows functions
- [x] Switch from `serial` to `file_serial` in integration tests
- [x] Add `taplo` to pre-commit config and nix flake 

## Link to issue

Implements #184

## Type of change

- [x] New feature (non-breaking change that adds functionality)
- [x] Refactor

## Test plan (required)

We have an integration test in `homestar-runtime/tests/metrics.rs`.

---------

Co-authored-by: Zeeshan Lakhani <zeeshan.lakhani@gmail.com>
  • Loading branch information
bgins and zeeshanlakhani authored Sep 14, 2023
1 parent 93a11c4 commit 1fad8c4
Show file tree
Hide file tree
Showing 19 changed files with 853 additions and 292 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ private
homestar-guest-wasm/out
homestar-wasm/out
**/fixtures/test_*
.zed
result-alejandra


# ipfs
.ipfs
Expand Down
24 changes: 12 additions & 12 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,27 +35,27 @@ repos:
args: ["--document-private-items"]
types: [rust]
pass_filenames: false

- repo: https://github.com/kamadorueda/alejandra
rev: bb7f2ad3f176aa8e9e2944a10061f7989c8fef17 # frozen: 1.3.0
hooks:
- id: alejandra
name: alejandra
description: Format nix files.
entry: alejandra
files: \.nix$
language: system
- id: taplo
name: taplo
description: Format toml files.
language: system
entry: taplo
args: ["fmt"]
types:
- toml

- repo: https://github.com/DevinR528/cargo-sort
rev: v1.0.9
hooks:
- id: cargo-sort
args: ["-w"]

- repo: https://github.com/ComPWA/mirrors-taplo
rev: v0.8.1
hooks:
- id: taplo
args: ["fmt"]
types:
- toml

- repo: https://github.com/compilerla/conventional-pre-commit
rev: v2.1.1
hooks:
Expand Down
Loading

0 comments on commit 1fad8c4

Please sign in to comment.