Setting podManagementPolicy in Juju k8s StatefulSet

Bug #1834481 reported by Dominik Fleischmann
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
High
Yang Kelvin Liu

Bug Description

By default when deploying a Juju k8s charm with storage a StatefulSet is created where the Pods will be created if there are several units.

In a default StatefulSet the podManagementPolicy is set to OrderedReady so each pod will be created after the previous one is ready.

In Juju on the other hand this value has been changed to Parallel so all Pods are initiated at the same time.

This is causing us issues in some applications like a Mariadb Cluster where the Primary Node has to be created before the Secondary ones.

Adding an option, to make this value configurable in the Charms would solve these issues.

Tags: osm
Revision history for this message
Richard Harding (rharding) wrote :

Tossing over to Christian to take a look at what we might need to do here. Thanks for the bug report.

Changed in juju:
status: New → Triaged
importance: Undecided → High
assignee: nobody → Christian Muirhead (2-xtian)
Adam Israel (aisrael)
tags: added: osm
Ian Booth (wallyworld)
Changed in juju:
assignee: Christian Muirhead (2-xtian) → Yang Kelvin Liu (kelvin.liu)
milestone: none → 2.7-beta1
Revision history for this message
Yang Kelvin Liu (kelvin.liu) wrote :

https://github.com/juju/juju/pull/10642 will be released in 2.7 to introduce this feature.

Changed in juju:
status: Triaged → In Progress
Revision history for this message
Ian Booth (wallyworld) wrote :

You can update charms to use the new pod spec v2 and set the scale policy. There will be a discourse post soon to explain the details of how pod spec v2 works. The relevant change here is a new "scale policy" attribute under service.

# podspec.yaml
version: 2
service:
  scalePolicy: serial

The value can be "parallel" (default) or "serial"

Changed in juju:
status: In Progress → Fix Committed
Changed in juju:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.