-
Notifications
You must be signed in to change notification settings - Fork 438
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: chainsaw improvements #2642
Conversation
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
0975583
to
3da4895
Compare
d9d0c5b
to
1cfc4b2
Compare
Things like this could probably be eliminated too # Name of the daemonset to check
DAEMONSET_NAME="prometheus-kubernetessd-collector"
# Get the desired and ready pod counts for the daemonset
read DESIRED READY <<< $(kubectl get daemonset -n $NAMESPACE $DAEMONSET_NAME -o custom-columns=:status.desiredNumberScheduled,:status.numberReady --no-headers)
# Check if the desired count matches the ready count
if [ "$DESIRED" -eq "$READY" ]; then
echo "Desired count ($DESIRED) matches the ready count ($READY) for $DAEMONSET_NAME."
else
echo "Desired count ($DESIRED) does not match the ready count ($READY) for $DAEMONSET_NAME."
exit 1
fi |
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
1cfc4b2
to
1f14875
Compare
Did i break a unit test ? 🤔 |
No, I'm fixing it here: #2643. It does seem to break much more frequently here than in any other PR, which made it easier to hunt down. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, this looks much better than before.
Honestly your tests are of good quality, I often see a lot of hacks to workaround kuttl limitations but not in your tests ! 💪 |
Like this one Kuttl-In-Kuttl 😂 🙈 |
Have you looked at the target allocator tests with jobs running curl in a loop to check if metrics are available? 🙈 |
Not yet ! But metrics is an area we want to address, this is often not well end to end tested and chainsaw could easily be adapted to assert on metrics we believe. |
I will address this one next https://github.com/open-telemetry/opentelemetry-operator/blob/main/tests/e2e-targetallocator/targetallocator-kubernetessd/check-daemonset.sh We really can do better than that ! (not in this PR, i'll do another one) |
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Co-authored-by: Mikołaj Świątek <mail+sumo@mikolajswiatek.com>
Chainsaw improvements (based on comments in #2630)
kubectl
commands