Skip to content
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

K8SPSMDB-1051: Bump PBM version to 2.4.0 #1485

Merged
merged 10 commits into from
Mar 21, 2024
Merged

K8SPSMDB-1051: Bump PBM version to 2.4.0 #1485

merged 10 commits into from
Mar 21, 2024

Conversation

egegunes
Copy link
Contributor

@egegunes egegunes commented Mar 18, 2024

K8SPSMDB-1051 Powered by Pull Request Badge

CHANGE DESCRIPTION

Problem:
Short explanation of the problem.

Cause:
Short explanation of the root cause of the issue if applicable.

Solution:
Short explanation of the solution we are providing with this PR.

CHECKLIST

Jira

  • Is the Jira ticket created and referenced properly?
  • Does the Jira ticket have the proper statuses for documentation (Needs Doc) and QA (Needs QA)?
  • Does the Jira ticket link to the proper milestone (Fix Version field)?

Tests

  • Is an E2E test/test case added for the new feature/change?
  • Are unit tests added where appropriate?
  • Are OpenShift compare files changed for E2E tests (compare/*-oc.yml)?

Config/Logging/Testability

  • Are all needed new/changed options added to default YAML files?
  • Did we add proper logging messages for operator actions?
  • Did we ensure compatibility with the previous version or cluster upgrade process?
  • Does the change support oldest and newest supported MongoDB version?
  • Does the change support oldest and newest supported Kubernetes version?

@pull-request-size pull-request-size bot added the size/L 100-499 lines label Mar 18, 2024
@pull-request-size pull-request-size bot added size/XL 500-999 lines and removed size/L 100-499 lines labels Mar 19, 2024
e2e-tests/functions Outdated Show resolved Hide resolved
e2e-tests/pitr-physical/run Outdated Show resolved Hide resolved
e2e-tests/pitr-physical/run Outdated Show resolved Hide resolved
e2e-tests/pitr-physical/run Outdated Show resolved Hide resolved
hors and others added 2 commits March 20, 2024 11:52
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
hors and others added 2 commits March 20, 2024 11:52
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@@ -335,6 +335,7 @@ wait_restore() {
| grep -v 'Getting pods from source' \
| tail -100

kubectl_bin get psmdb-restore restore-${backup_name} -o yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin get psmdb-restore restore-${backup_name} -o yaml
kubectl_bin get psmdb-restore restore-${backup_name} -o yaml

@egegunes egegunes marked this pull request as ready for review March 21, 2024 10:35
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +105 to +108
kubectl_bin get ns |
egrep -v "^kube-|^default|Terminating|psmdb-operator|openshift|gke-mcs|^NAME" |
awk '{print$1}' |
xargs kubectl delete ns &
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin get ns |
egrep -v "^kube-|^default|Terminating|psmdb-operator|openshift|gke-mcs|^NAME" |
awk '{print$1}' |
xargs kubectl delete ns &
kubectl_bin get ns \
| egrep -v "^kube-|^default|Terminating|psmdb-operator|openshift|gke-mcs|^NAME" \
| awk '{print$1}' \
| xargs kubectl delete ns &

Comment on lines +154 to +159
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) \
| grep -v 'level=info' \
| grep -v 'level=debug' \
| grep -v 'Getting tasks for pod' \
| grep -v 'Getting pods from source' \
| tail -100

Comment on lines +179 to +184
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) \
| grep -v 'level=info' \
| grep -v 'level=debug' \
| grep -v 'Getting tasks for pod' \
| grep -v 'Getting pods from source' \
| tail -100

Comment on lines +203 to +204
kubectl_bin logs $agent_pod -c backup-agent |
tail -100
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin logs $agent_pod -c backup-agent |
tail -100
kubectl_bin logs $agent_pod -c backup-agent \
| tail -100

Comment on lines +226 to +231
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) |
grep -v 'level=info' |
grep -v 'level=debug' |
grep -v 'Getting tasks for pod' |
grep -v 'Getting pods from source' |
tail -100
kubectl_bin logs ${OPERATOR_NS:+-n $OPERATOR_NS} $(get_operator_pod) \
| grep -v 'level=info' \
| grep -v 'level=debug' \
| grep -v 'Getting tasks for pod' \
| grep -v 'Getting pods from source' \
| tail -100

Comment on lines +959 to +961
kubectl_bin get service/$service -o json |
jq '.status.loadBalancer.ingress[].hostname' |
sed -e 's/^"//; s/"$//;'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin get service/$service -o json |
jq '.status.loadBalancer.ingress[].hostname' |
sed -e 's/^"//; s/"$//;'
kubectl_bin get service/$service -o json \
| jq '.status.loadBalancer.ingress[].hostname' \
| sed -e 's/^"//; s/"$//;'

Comment on lines +969 to +971
kubectl_bin get service/$service -o json |
jq '.status.loadBalancer.ingress[].ip' |
sed -e 's/^"//; s/"$//;'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
kubectl_bin get service/$service -o json |
jq '.status.loadBalancer.ingress[].ip' |
sed -e 's/^"//; s/"$//;'
kubectl_bin get service/$service -o json \
| jq '.status.loadBalancer.ingress[].ip' \
| sed -e 's/^"//; s/"$//;'

Comment on lines +989 to +991
curl -s -k "https://${user_pass}@$endpoint/graph/api/datasources/proxy/1/api/v1/query_range?query=min%28$metric%7Bnode_name%3D%7E%22$instance%22%7d%20or%20$metric%7Bnode_name%3D%7E%22$instance%22%7D%29&start=$start&end=$end&step=60" |
jq '.data.result[0].values[][1]' |
grep '^"[0-9]'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
curl -s -k "https://${user_pass}@$endpoint/graph/api/datasources/proxy/1/api/v1/query_range?query=min%28$metric%7Bnode_name%3D%7E%22$instance%22%7d%20or%20$metric%7Bnode_name%3D%7E%22$instance%22%7D%29&start=$start&end=$end&step=60" |
jq '.data.result[0].values[][1]' |
grep '^"[0-9]'
curl -s -k "https://${user_pass}@$endpoint/graph/api/datasources/proxy/1/api/v1/query_range?query=min%28$metric%7Bnode_name%3D%7E%22$instance%22%7d%20or%20$metric%7Bnode_name%3D%7E%22$instance%22%7D%29&start=$start&end=$end&step=60" \
| jq '.data.result[0].values[][1]' \
| grep '^"[0-9]'

Comment on lines +1039 to +1040
response=$(curl -s -k -XPOST -d @payload.json "https://${user_pass}@$endpoint/v0/qan/GetReport" |
jq '.rows[].fingerprint')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
response=$(curl -s -k -XPOST -d @payload.json "https://${user_pass}@$endpoint/v0/qan/GetReport" |
jq '.rows[].fingerprint')
response=$(curl -s -k -XPOST -d @payload.json "https://${user_pass}@$endpoint/v0/qan/GetReport" \
| jq '.rows[].fingerprint')

Comment on lines +1049 to +1054
cat "$1" |
yq eval '(.spec | select(.image == null)).image = "'"$IMAGE_MONGOD"'"' |
yq eval '(.spec | select(has("pmm"))).pmm.image = "'"$IMAGE_PMM_CLIENT"'"' |
yq eval '(.spec | select(has("initImage"))).initImage = "'"$IMAGE"'"' |
yq eval '(.spec | select(has("backup"))).backup.image = "'"$IMAGE_BACKUP"'"' |
yq eval '.spec.upgradeOptions.apply="Never"'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[shfmt] reported by reviewdog 🐶

Suggested change
cat "$1" |
yq eval '(.spec | select(.image == null)).image = "'"$IMAGE_MONGOD"'"' |
yq eval '(.spec | select(has("pmm"))).pmm.image = "'"$IMAGE_PMM_CLIENT"'"' |
yq eval '(.spec | select(has("initImage"))).initImage = "'"$IMAGE"'"' |
yq eval '(.spec | select(has("backup"))).backup.image = "'"$IMAGE_BACKUP"'"' |
yq eval '.spec.upgradeOptions.apply="Never"'
cat "$1" \
| yq eval '(.spec | select(.image == null)).image = "'"$IMAGE_MONGOD"'"' \
| yq eval '(.spec | select(has("pmm"))).pmm.image = "'"$IMAGE_PMM_CLIENT"'"' \
| yq eval '(.spec | select(has("initImage"))).initImage = "'"$IMAGE"'"' \
| yq eval '(.spec | select(has("backup"))).backup.image = "'"$IMAGE_BACKUP"'"' \
| yq eval '.spec.upgradeOptions.apply="Never"'

@JNKPercona
Copy link
Collaborator

Test name Status
arbiter passed
balancer passed
custom-replset-name passed
cross-site-sharded passed
data-at-rest-encryption passed
data-sharded passed
demand-backup passed
demand-backup-eks-credentials passed
demand-backup-physical passed
demand-backup-physical-sharded passed
demand-backup-sharded passed
expose-sharded passed
ignore-labels-annotations passed
init-deploy passed
finalizer passed
limits passed
liveness passed
mongod-major-upgrade passed
mongod-major-upgrade-sharded passed
monitoring-2-0 passed
multi-cluster-service passed
non-voting passed
one-pod passed
operator-self-healing-chaos passed
pitr passed
pitr-sharded passed
pitr-physical passed
recover-no-primary passed
rs-shard-migration passed
scaling passed
scheduled-backup passed
security-context passed
self-healing-chaos passed
service-per-pod passed
serviceless-external-nodes passed
smart-update passed
split-horizon passed
storage passed
tls-issue-cert-manager passed
upgrade passed
upgrade-consistency passed
upgrade-consistency-sharded passed
upgrade-sharded passed
users passed
version-service passed
We run 45 out of 45

commit: 901b753
image: perconalab/percona-server-mongodb-operator:PR-1485-901b753d

@hors hors merged commit 4e7f15d into main Mar 21, 2024
16 checks passed
@hors hors deleted the K8SPSMDB-1051 branch March 21, 2024 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/XL 500-999 lines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants