Skip to content

Conversation

@kobzonega
Copy link
Contributor

@kobzonega kobzonega commented May 10, 2024

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

Problem of unavailability some hosts at the time of cluster creation. Storage/Database object moved to "Ready" status only when all NodeSet provisioned and Ready. We should be able not to wait for all hosts to start and only check the creation and preparing of all necessary objects.

Issue Number: YDBOPS-9612

What is the new behavior?

  • Status.state DatabasePreparing and StoragePreparing to determine handleResourceSync step first running
  • Status.state DatabaseProvisioned and StorageProvisioned to determine waitForStatefulSetToScale or waitForNodeSetsToProvisioned step first running
  • New conditions for Storage and Database objects:
    • PreparedCondition to determine that all child resources created
    • ProvisionedCondition to determine that all pods are created and have status.phase=="Running"
    • ReadyCondition to determine that all conditions are True and last Reconcile successfully moved to Ready status
    • PausedCondition to determine that all conditions are True and last Reconcile successfully moved to Paused status
  • Set "Unknown" status for condition and change value of .status.state on step first run
  • Set "False" status for condition if non-Kubernetes error inside current Reconcile run
  • Set "True" status for condition if non-True status was set previously

Other information

  • Move handler for .spec.operatorSync to handleResourcesSync step
  • Use setInitialStatus with call Update to API instead of SetStatusOnFirstReconcile
  • Move handler for .spec.pause handlePauseResume to the last step position on Reconcile Sync

@kobzonega kobzonega changed the base branch from master to YDBOPS-9613 May 11, 2024 12:08
@kobzonega kobzonega force-pushed the YDBOPS-9612 branch 3 times, most recently from de40eb6 to 008427c Compare May 11, 2024 14:34
@kobzonega kobzonega changed the title Ydbops 9612 YDBOPS-9612 conditions for Storage and Database objects May 11, 2024
@artgromov artgromov added the ok-to-test Testing pipelines will run label May 13, 2024
Base automatically changed from YDBOPS-9613 to master May 13, 2024 14:39
@github-actions github-actions bot removed the ok-to-test Testing pipelines will run label May 13, 2024
@kobzonega kobzonega marked this pull request as ready for review May 13, 2024 14:41
@kobzonega kobzonega merged commit 1a0ee3f into master May 13, 2024
@kobzonega kobzonega deleted the YDBOPS-9612 branch May 13, 2024 17:09
kobzonega added a commit to kobzonega/ydb-kubernetes-operator that referenced this pull request Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants