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-899: add labels to all objects #1585

Merged
merged 18 commits into from
Jul 23, 2024
Merged

K8SPSMDB-899: add labels to all objects #1585

merged 18 commits into from
Jul 23, 2024

Conversation

pooknull
Copy link
Contributor

@pooknull pooknull commented Jul 9, 2024

K8SPSMDB-899 Powered by Pull Request Badge

https://perconadev.atlassian.net/browse/K8SPSMDB-899

DESCRIPTION

Problem:
Some objects created by the operator don't have labels.

Solution:
Operator should add labels to all objects created by the operator.

Labels will be added to the following objects:

apiGroup kind name with default cr
cert-manager.io/v1 Issuer cluster1-psmdb-issuer
cert-manager.io/v1 Issuer cluster1-psmdb-ca-issuer
cert-manager.io/v1 Certificate cluster1-psmdb-ssl
cert-manager.io/v1 Certificate cluster1-psmdb-ssl-internal
cert-manager.io/v1 Certificate cluster1-ca-cert
policy/v1 PodDisruptionBudget cluster1-mongod-rs0
v1 Secret cluster1-pbm-config
v1 Secret internal-cluster1-users
v1 Secret cluster1-ssl
v1 Secret cluster1-ssl-internal
v1 Secret my-cluster-name-secrets
v1 ConfigMap cluster1-rs0-mongod
v1 ConfigMap cluster1-mongos

Also, this PR changes labels for scheduled backups (PerconaServerMongoDBBackup object):

BEFORE AFTER
"ancestor": "task-name" "percona.com/backup-ancestor": "task-name"
"cluster": "cluster1" "percona.com/cluster": "cluster1"
"type": "cron" "percona.com/backup-type": "cron"

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 Jul 9, 2024
@pull-request-size pull-request-size bot added size/XL 500-999 lines and removed size/L 100-499 lines labels Jul 15, 2024
@pooknull pooknull marked this pull request as ready for review July 17, 2024 16:30
inelpandzic
inelpandzic previously approved these changes Jul 18, 2024
pkg/apis/psmdb/v1/psmdb_types.go Outdated Show resolved Hide resolved
pkg/psmdb/backup/job.go Show resolved Hide resolved
@JNKPercona
Copy link
Collaborator

Test name Status
arbiter passed
balancer passed
custom-replset-name passed
custom-tls 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
ldap passed
ldap-tls 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
pvc-resize 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-tls passed
upgrade-sharded passed
users passed
version-service passed
We run 49 out of 49

commit: fdd2d1e
image: perconalab/percona-server-mongodb-operator:PR-1585-fdd2d1e6

@hors hors merged commit 9304c9b into main Jul 23, 2024
14 checks passed
@hors hors deleted the dev/K8SPSMDB-899 branch July 23, 2024 08:01
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