Improve Helm Chart to Support Fresh PersistentVolumeClaims During Failover Restorations
@artntek is already working on this.
Since Apr 28, 2025.
Assessment
This issue has not been assessed yet.
Description
I am encountering a challenge with the dataone-indexer Helm chart when trying to restore a system from backups during failover situations. Specifically, I want to start with fresh PersistentVolumeClaims (PVCs) while preserving the existing PVCs, simply by naming new ones. This is currently difficult due to the way PVC names are tied to StatefulSets.
Context:
-
In the
dataone-indexer.solrStatefulSet:- Each Pod derives its hostname from the StatefulSet name and the Pod ordinal index.
- This naming convention extends to PVC names, making it cumbersome to start with fresh PVCs without impacting the StatefulSet.
-
Kubernetes provides two potential options to alter naming:
- Option 1: Change the ordinal index (see StatefulSet Ordinal Index).
- Option 2: Use
fullnameOverrideornameOverridefor the Solr chart.
While Option 2 is supported in the Bitnami Solr chart, implementing it introduces additional complexity:
- The Solr hostname in the
dataone-indexerchart must be overridden accordingly usingidxworker.solrHostNameandsolr.nameOverride. - Upon restoration, I currently use PVCs with a timestamp in their name (e.g.,
solr-20250409). This means the Solr pod names also change to<release>-solr-20250409-<N>. While this works, it is not ideal.
Proposal:
To streamline this process and address the issue:
- Improve the Helm chart to allow flexible PVC naming when starting from fresh PVCs.
- Enhance the
idxworker.solr.hostnamehelper function to dynamically adapt to the overridden Solr chart name, ensuring compatibility withnameOverrideorfullnameOverride.
This improvement would simplify failover restorations, eliminate tedious manual configuration, and provide a more seamless experience.
Additional Notes:
- A similar issue exists with RabbitMQ, where PVC and pod naming conventions make failover restoration challenging. Addressing this across the board would be highly beneficial.
- The following is the current way to override the names and thus change the PVC names. Ideally, it would nice to just provide
solr.nameOverrideand have theidxworker.solr.hostnamehelper function to the right thing with it.# dataone-indexer - Dataone Indexer chart values dataone-indexer: # @param metacat.dataone-indexer.image - Dataone Indexer image solr: ## @param nameOverride String to partially override common.names.fullname template (will maintain the release name) ## nameOverride: "solr-20250409" idxworker: ## @param idxworker.solrHostname hostname of the solr service to use ## Leave unset (solrHostname: "") to automatically populate when using solr bitnami subchart ## solrHostname: "ess-dive-solr-20250409-headless" - There may be other ideas to start from a fresh PVC. This is just the one I have tried.
- Dominant language
- Java
- Stars
- 0
- Forks
- 2
- Avg merge
- 6d 6h
- Merged PRs (30d)
- 3
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from DataONEorg/dataone-indexer
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
DataONEorg/dataone-indexer#390 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
DataONEorg/dataone-indexer#378 ·
-
K8s
Difficulty 4/5 3-5 days Newbie friendliness 38/100
DataONEorg/dataone-indexer#377 ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
DataONEorg/dataone-indexer#362 · 8 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
DataONEorg/dataone-indexer#357 ·
All issues in DataONEorg/dataone-indexer
Similar issues
-
enhancement good first issue storege-module
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
sdlc-pro/spring-lens#647 ·
Maintainers usually reply within 1 day
-
lang-java needs-triage package:jni package:jni_flutter package:jnigen
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
valkey-io/valkey-glide#7975 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
constellation-app/constellation#2613 ·
Maintainers usually reply within 2 days