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

feat: add recreate-stateful-strategy, orphan, background, foreground(default) #1286

Merged

Conversation

husnialhamdani
Copy link
Contributor

@husnialhamdani husnialhamdani commented Mar 18, 2025

This PR will expand the capability of current "redis.opstreelabs.in/recreate-statefulset", to make the users have more control to deal with recreating process of the StatefulSet,

For example: Recreating the Statefulset (with foreground delete) on, will make the Pod of Sentinel entirely terminated,
with the setting of orphan --> "redis.opstreelabs.in/recreate-statefulset-strategy: orphan" will keep the Pod up and running and will make the administrator have more control on it (for example: to avoid downtime).

Description

Fixes #ISSUE

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist

  • Tests have been added/modified and all tests pass.
  • Functionality/bugs have been confirmed to be unchanged or fixed.
  • I have performed a self-review of my own code.
  • Documentation has been updated or added where necessary.

Additional Context

@husnialhamdani husnialhamdani changed the title feat: add recreate-stateful-strategy, orphan, background, foreground(… feat: add recreate-stateful-strategy, orphan, background, foreground Mar 18, 2025
@husnialhamdani husnialhamdani force-pushed the recreate-statefulset-strategy branch from 3a6248a to 3797e48 Compare March 18, 2025 21:23
@husnialhamdani husnialhamdani changed the title feat: add recreate-stateful-strategy, orphan, background, foreground feat: add recreate-stateful-strategy, orphan, background, foreground(default) Mar 18, 2025
@husnialhamdani husnialhamdani force-pushed the recreate-statefulset-strategy branch from cd1cd73 to 1362126 Compare March 19, 2025 10:37
Copy link

codecov bot commented Mar 19, 2025

Codecov Report

Attention: Patch coverage is 16.00000% with 21 lines in your changes missing coverage. Please review.

Please upload report for BASE (main@4af5f1d). Learn more about missing BASE report.

Files with missing lines Patch % Lines
pkg/k8sutils/statefulset.go 19.04% 17 Missing ⚠️
pkg/k8sutils/redis-cluster.go 0.00% 1 Missing ⚠️
pkg/k8sutils/redis-replication.go 0.00% 1 Missing ⚠️
pkg/k8sutils/redis-sentinel.go 0.00% 1 Missing ⚠️
pkg/k8sutils/redis-standalone.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1286   +/-   ##
=======================================
  Coverage        ?   34.48%           
=======================================
  Files           ?       56           
  Lines           ?     6043           
  Branches        ?        0           
=======================================
  Hits            ?     2084           
  Misses          ?     3777           
  Partials        ?      182           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@drivebyer drivebyer force-pushed the recreate-statefulset-strategy branch from 7b9dc25 to 7469004 Compare March 21, 2025 06:35
Signed-off-by: yangw <[email protected]>
@drivebyer
Copy link
Collaborator

I add the docs and abstract common function for the PR

@drivebyer drivebyer merged commit 0977eca into OT-CONTAINER-KIT:main Mar 21, 2025
19 checks passed
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.

2 participants