machine424
92544c00bf
discovery: kubernetes: Avoid creating unnecessary Kubernetes indexers in RoleEndpointSlice
...
This was due to a missing "return", see https://github.com/prometheus/prometheus/pull/13554#discussion_r1490965817
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
9 months ago
Darshan Chaudhary
0e8a2e44a4
Azure SD: check for nil before accessing and dereferencing ( #13578 )
...
Signed-off-by: darshanime <deathbullet@gmail.com>
9 months ago
Bryan Boreham
857138d3ce
review feedback
...
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
10 months ago
Bryan Boreham
b17f88b7fb
consul sd tests: don't call FailNow from a background goroutine
...
This is not allowed by the Go test framework.
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
10 months ago
Bryan Boreham
46008fdecd
lint
...
Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
10 months ago
Ayoub Mrini
581d8d86b4
Pod status changes not discovered by Kube Endpoints SD ( #13337 )
...
* fix(discovery/kubernetes/endpoints): react to changes on Pods because some modifications can occur on them without triggering an update on the related Endpoints (The Pod phase changing from Pending to Running e.g.).
---------
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
Co-authored-by: Guillermo Sanchez Gavier <gsanchez@newrelic.com>
10 months ago
Paweł Szulik
7f24efccdb
Refactor discovery tests to use testify.
...
Signed-off-by: Paweł Szulik <paul.szulik@gmail.com>
10 months ago
Augustin Husson
9a9e73b34a
update all go dependencies ( #13438 )
...
Signed-off-by: Augustin Husson <husson.augustin@gmail.com>
10 months ago
Paulin Todev
53589fde4f
Change metric label for Puppetdb from 'http' to 'puppetdb'
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
10 months ago
Paulin Todev
78411d5e8b
SD Managers taking over responsibility for registration of debug metrics ( #13375 )
...
SD Managers take over responsibility for SD metrics registration
---------
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
Signed-off-by: Björn Rabenstein <github@rabenste.in>
Co-authored-by: Björn Rabenstein <github@rabenste.in>
10 months ago
machine424
2d01e56695
chore(kubernetes): check preconditions earlier and avoid unnecessary checks or iterations
...
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
10 months ago
machine424
afc05129f1
fix(discovery): allow requireUpdate util to timeout in discovery/file/file_test.go.
...
The loop ran indefinitely if the condition isn't met.
Before, each iteration created a new timer channel which was always outpaced by
the other timer channel with smaller duration.
minor detail: There was a memory leak: resources of the ~10 previous timers were
constantly kept. With the fix, we may keep the resources of one timer around for defaultWait
but this isn't worth the changes to make it right.
Signed-off-by: machine424 <ayoubmrini424@gmail.com>
11 months ago
daniel-resdiary
d79ad810aa
Get VM Scale Set NIC ( #13283 )
...
Calling `*armnetwork.InterfacesClient.Get()` doesn't work for Scale Set
VM NIC, because these use a different Resource ID format.
Use `*armnetwork.InterfacesClient.GetVirtualMachineScaleSetNetworkInterface()`
instead. This needs both the scale set name and the instance ID, so
add an `InstanceID` field to the `virtualMachine` struct. `InstanceID`
is empty for a VM that isn't a ScaleSetVM.
Signed-off-by: Daniel Nicholls <daniel.nicholls@resdiary.com>
11 months ago
Matthieu MOREL
952cb41373
build(deps): bump github.com/Azure/azure-sdk-for-go/sdk/resourcemanager
...
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
11 months ago
Daniel Nicholls
0704c72548
Dedup code handling getting network interface
...
Signed-off-by: Daniel Nicholls <daniel.nicholls@resdiary.com>
12 months ago
daniel-resdiary
103133124a
Get VM Scale Set NIC ( #13283 )
...
Calling `*armnetwork.InterfacesClient.Get()` doesn't work for Scale Set
VM NIC, because these use a different Resource ID format.
Use `*armnetwork.InterfacesClient.GetVirtualMachineScaleSetNetworkInterface()`
instead. This needs both the scale set name and the instance ID, so
add an `InstanceID` field to the `virtualMachine` struct. `InstanceID`
is empty for a VM that isn't a ScaleSetVM.
Signed-off-by: Daniel Nicholls <daniel.nicholls@resdiary.com>
12 months ago
Marcin Skalski
e27232614a
code review
...
Signed-off-by: Marcin Skalski <skalskimarcin33@gmail.com>
12 months ago
Marcin Skalski
0af810aa71
fix go lint
...
Signed-off-by: Marcin Skalski <skalskimarcin33@gmail.com>
12 months ago
Marcin Skalski
d12ccf9fa2
kuma_sd: Extend Kuma SD configuration to allow users to specify ClientId
...
Signed-off-by: Marcin Skalski <skalskimarcin33@gmail.com>
12 months ago
Paulin Todev
d2e997030e
Fix linter issues
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
12 months ago
Paulin Todev
27bb57a37b
Define metric label values in one place
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
12 months ago
Paulin Todev
108a749a45
Set up labels for counters in advance
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
12 months ago
Paulin Todev
6a5306a53c
Use const labels for Discovery Manager metrics.
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
12 months ago
Paulin Todev
6de80d7fb0
Allow non-default registry to be used for metrics of SD components
...
Signed-off-by: Paulin Todev <paulin.todev@gmail.com>
12 months ago
Gavin Lam
d5924f305b
Fix missing public IP addresses in Azure service discovery ( #13241 )
...
Fixes #5588 , #9293
Signed-off-by: Gavin Lam <gavin.oss@tutamail.com>
12 months ago
Matthieu MOREL
9c4782f1cc
golangci-lint: enable testifylint linter ( #13254 )
...
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
12 months ago
Daniel Jolly
9ebea5e1ca
Removed extra whitespace
...
Signed-off-by: Daniel Jolly <code@danieljolly.com>
12 months ago
Oleksandr Redko
2a75604f8e
Enable default revive rules ( #13068 )
...
Signed-off-by: Oleksandr Redko <Oleksandr_Redko@epam.com>
12 months ago
Daniel Jolly
2c420b518e
Add support for NS records in DNS discovery
...
Signed-off-by: Daniel Jolly <code@danieljolly.com>
12 months ago
Charles Korn
2329fba0e5
Fix linting issues in comments ( #13178 )
...
Signed-off-by: Charles Korn <charles.korn@grafana.com>
1 year ago
Etourneau Gwenn
b37258c99b
Added Caching of network interface for Azure ( #12622 )
...
* Added Caching of network interface for Azure
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Rename Counter for Azure cache
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Format with goimports
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Updated duration comparaison
Enabled cache by default with 5x the default refresh time
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Change random function
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Remove refresh interval
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Remove from config as well
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
* Reformat config_test
Removed uneeded error
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
---------
Signed-off-by: Etourneau Gwenn <getourneau@yugabyte.com>
1 year ago
Julien Pivotto
222d46d243
Linode: Add GPU label
...
Signed-off-by: Julien Pivotto <roidelapluie@o11y.eu>
1 year ago
Matthieu MOREL
fe057fc60d
use Go standard errors package
...
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
1 year ago
Oleksandr Redko
fa90ca46e5
ci(lint): enable godot; append dot at the end of comments
...
Signed-off-by: Oleksandr Redko <Oleksandr_Redko@epam.com>
1 year ago
Matthieu MOREL
68e6b4dd34
ci(lint): enable errorlint on discovery ( #12918 )
...
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
1 year ago
Oleksandr Redko
8e5f0387a2
ci(lint): enable nolintlint and remove redundant comments ( #12926 )
...
Signed-off-by: Oleksandr Redko <Oleksandr_Redko@epam.com>
1 year ago
Levi Harrison
4284e6f2f7
Merge pull request #11860 from mmorel-35/azure-sdk-for-go
...
Signed-off-by: Levi Harrison <git@leviharrison.dev>
1 year ago
Matthieu MOREL
bbdc7d5902
Update Azure SDK For Go
...
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
1 year ago
Jayapriya Pai
57988fda75
LIGHTSAIL SD: Validate HTTP config
...
Related-to #12810
Signed-off-by: Jayapriya Pai <janantha@redhat.com>
1 year ago
Jayapriya Pai
344f9d8d15
PUPPETDB SD: Validate HTTP config
...
Related-to #12810
Signed-off-by: Jayapriya Pai <janantha@redhat.com>
1 year ago
Jayapriya Pai
34c8dcc73f
UYUNI SD: Validate HTTP config
...
Related-to #12810
Signed-off-by: Jayapriya Pai <janantha@redhat.com>
1 year ago
Jayapriya Pai
e44d5dfb3a
AZURE SD: Validate HTTP config
...
Related-to #12810
Signed-off-by: Jayapriya Pai <janantha@redhat.com>
1 year ago
Jayapriya Pai
7f085aeb6a
EC2 SD: Validate HTTP config
...
Related-to #12810
Signed-off-by: Jayapriya Pai <janantha@redhat.com>
1 year ago
Julien Pivotto
8498b96a2b
HTTP SD: Validate HTTP config
...
Fixes #12762
Signed-off-by: Julien Pivotto <roidelapluie@o11y.eu>
1 year ago
Julien Pivotto
009017a3fb
Revert "Remove deleted target from discovery manager"
...
Signed-off-by: Julien Pivotto <roidelapluie@o11y.eu>
1 year ago
Marc Tuduri
98383fdc63
sd: change hetzner role type and constants to be exportable
...
Signed-off-by: Marc Tuduri <marctc@protonmail.com>
1 year ago
Julian Tölle
7aa7965716
build(deps): bump github.com/hetznercloud/hcloud-go to v2.0.0
...
Version 2 introduced a breaking change in the `id` field of all
resources. They were changed from `int` to `int64` to make sure that all
future numerical IDs are supported on all architectures.
You can learn more about this
[here](https://docs.hetzner.cloud/#deprecation-notices-%E2%9A%A0%EF%B8%8F )
Signed-off-by: Julian Tölle <julian.toelle@hetzner-cloud.de>
1 year ago
Daniel Swarbrick
de89a8c827
Linode SD: cast InstanceSpec values to int64 to avoid overflows
...
InstanceSpec struct members are untyped integers, so they can overflow
on 32-bit arch when bit-shifted left.
Signed-off-by: Daniel Swarbrick <daniel.swarbrick@gmail.com>
1 year ago
Mikhail Fesenko
02e11cc2a7
Fix from discussion
...
Signed-off-by: Mikhail Fesenko <proggga@gmail.com>
1 year ago
Mikhail Fesenko
17cdfdd79f
maraphon.go: Simplified conditions in method
...
Signed-off-by: Mikhail Fesenko <proggga@gmail.com>
1 year ago