Skip to content

Commit

Permalink
Merge tag 'refs/tags/v1.8.1'
Browse files Browse the repository at this point in the history
v1.8.1

# -----BEGIN PGP SIGNATURE-----
#
# iQIzBAABCgAdFiEEoFiTUofnXYMugU5GxkayPJ4yRfEFAmZM6WQACgkQxkayPJ4y
# RfGU6BAAt97gDcHJGmT++D6skGio/bjZ3yhstBuZU1+MH8qxadqAjMmJLI/+8lrD
# EAihzbd9Ir20k7WYET8JOVLpxJjju+cViw7BlVGoqKBMstik+C9rI2qIyJ9gQHQi
# UMScG0TnCmgohu1GuOFXZQ6gCJhF/By1KvUahPzSLNPe1JVu049gaxFGwAsFyoPE
# mvQJI12VB4EwCYfqUcczHYMED4yqlyWXjYCOBcQWIwnhbe6jERBbbEExPhqFqkRm
# Op3UOTTqe4soBUHgz2iCiia2a2kinCUA03nB79wl63NUWs6EhHYlBDWv6bVZBIQr
# xJQyA95u2jp1sm4j0+DEryZ1B71LtD55hqpa+tkK4TFkuGn278tu4mYJnEvRD1gG
# wNvO+9bNqMLjZKIkBwkGBjOw+Fj8L53Tnw/nJhTIT9Ortp51qIfQZe38HDOsWmFS
# dqZiUlJZOKZTFEn28iXhujrmcIuouG23YAlg0C6SHMXxNn7e04RL9UMUQJLugupW
# GWIkHpHIBik4iDefe0UUYSivR316muan4aufBlUxfCpEpVcWjg9cW9xr7/OhR8yG
# 1z3odXVn8y+YzXcwDAT+fctnlRxpwKScoaE1PKEdZJ+N3IsYtrmWQtTfvGpfGHRZ
# s9WahHSrmEx+AcjLVWWRU70dHKC4jLr7OPVqLvbo9ZUt196d6yQ=
# =jCnY
# -----END PGP SIGNATURE-----
# gpg: directory '/home/runner/.gnupg' created
# gpg: keybox '/home/runner/.gnupg/pubring.kbx' created
# gpg: Signature made Tue May 21 18:35:16 2024 UTC
# gpg:                using RSA key A058935287E75D832E814E46C646B23C9E3245F1
# gpg: Can't check signature: No public key
  • Loading branch information
github-actions[bot] committed May 23, 2024
2 parents 33d4e3f + 400c397 commit 9bec0a1
Show file tree
Hide file tree
Showing 9 changed files with 35 additions and 10 deletions.
10 changes: 10 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,16 @@ jobs:
- run: docker run --privileged linuxkit/binfmt:af88a591f9cc896a52ce596b9cf7ca26a061ef97
- run: promu crossbuild -v --parallelism $CIRCLE_NODE_TOTAL --parallelism-thread $CIRCLE_NODE_INDEX
- run: promu --config .promu-cgo.yml crossbuild -v --parallelism $CIRCLE_NODE_TOTAL --parallelism-thread $CIRCLE_NODE_INDEX
# sign the darwin build so it doesn't get SIGKILLed on start, see: https://github.com/prometheus/node_exporter/issues/2539
- run:
command: |
if [[ -f "$(pwd)/.build/darwin-arm64/node_exporter" ]]; then
promu codesign "$(pwd)/.build/darwin-arm64/node_exporter"
fi
if [[ -f "$(pwd)/.build/darwin-amd64/node_exporter" ]]; then
promu codesign "$(pwd)/.build/darwin-amd64/node_exporter"
fi
- persist_to_workspace:
root: .
paths:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/container_description.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks.
steps:
- name: git checkout
uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
- name: Set docker hub repo name
run: echo "DOCKER_REPO_NAME=$(make docker-repo-name)" >> $GITHUB_ENV
- name: Push README to Dockerhub
Expand All @@ -37,7 +37,7 @@ jobs:
if: github.repository_owner == 'prometheus' || github.repository_owner == 'prometheus-community' # Don't run this workflow on forks.
steps:
- name: git checkout
uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
- name: Set quay.io org name
run: echo "DOCKER_REPO=$(echo quay.io/${GITHUB_REPOSITORY_OWNER} | tr -d '-')" >> $GITHUB_ENV
- name: Set quay.io repo name
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,6 @@ jobs:
run: sudo apt-get update && sudo apt-get -y install libsnmp-dev
if: github.repository == 'prometheus/snmp_exporter'
- name: Lint
uses: golangci/golangci-lint-action@3cfe3a4abbb849e10058ce4af15d205b6da42804 # v4.0.0
uses: golangci/golangci-lint-action@9d1e0624a798bb64f6c3cea93db47765312263dc # v5.1.0
with:
version: v1.56.2
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
* [ENHANCEMENT]
* [BUGFIX]

## 1.8.1 / 2024-05-16

* [BUGFIX] Fix CPU seconds on Solaris #2963
* [BUGFIX] Sign Darwin/MacOS binaries #3008
* [BUGFIX] Fix pressure collector nil reference #3016

## 1.8.0 / 2024-04-24

* [CHANGE] exec_bsd: Fix labels for `vm.stats.sys.v_syscall` sysctl #2895
Expand Down
2 changes: 1 addition & 1 deletion Makefile.common
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ ifneq ($(shell command -v gotestsum 2> /dev/null),)
endif
endif

PROMU_VERSION ?= 0.15.0
PROMU_VERSION ?= 0.17.0
PROMU_URL := https://github.com/prometheus/promu/releases/download/v$(PROMU_VERSION)/promu-$(PROMU_VERSION).$(GO_BUILD_PLATFORM).tar.gz

SKIP_GOLANGCI_LINT :=
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.8.0
1.8.1
10 changes: 5 additions & 5 deletions collector/cpu_solaris.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,17 +60,17 @@ func (c *cpuCollector) Update(ch chan<- prometheus.Metric) error {
}

for k, v := range map[string]string{
"idle": "cpu_ticks_idle",
"kernel": "cpu_ticks_kernel",
"user": "cpu_ticks_user",
"wait": "cpu_ticks_wait",
"idle": "cpu_nsec_idle",
"kernel": "cpu_nsec_kernel",
"user": "cpu_nsec_user",
"wait": "cpu_nsec_wait",
} {
kstatValue, err := ksCPU.GetNamed(v)
if err != nil {
return err
}

ch <- c.cpu.mustNewConstMetric(float64(kstatValue.UintVal), strconv.Itoa(cpu), k)
ch <- c.cpu.mustNewConstMetric(float64(kstatValue.UintVal)/1e9, strconv.Itoa(cpu), k)
}
}
return nil
Expand Down
1 change: 1 addition & 0 deletions collector/fixtures/proc/pressure/cpu
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
some avg10=0.00 avg60=0.00 avg300=0.00 total=14036781
full avg10=0.00 avg60=0.00 avg300=0.00 total=0
8 changes: 8 additions & 0 deletions collector/pressure_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,14 @@ func (c *pressureStatsCollector) Update(ch chan<- prometheus.Metric) error {
}
return fmt.Errorf("failed to retrieve pressure stats: %w", err)
}
if vals.Some == nil {
level.Debug(c.logger).Log("msg", "pressure information returned no 'some' data")
return ErrNoData
}
if vals.Full == nil {
level.Debug(c.logger).Log("msg", "pressure information returned no 'full' data")
return ErrNoData
}
switch res {
case "cpu":
ch <- prometheus.MustNewConstMetric(c.cpu, prometheus.CounterValue, float64(vals.Some.Total)/1000.0/1000.0)
Expand Down

0 comments on commit 9bec0a1

Please sign in to comment.