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

StatefulSet 1.9 updates. #6550

Merged
merged 4 commits into from
Dec 11, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions docs/concepts/workloads/controllers/statefulset.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@ title: StatefulSets
---

{% capture overview %}
**StatefulSet is the workload API object used to manage stateful applications.
StatefulSets are beta in 1.8.**

StatefulSet is the workload API object used to manage stateful applications.

**Note:** StatefulSets are stable (GA) in 1.9.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: 1.9 and above?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On second thought, seems fine even as is. Thinking from a perspective of a 1.9+ user, it should still be clear.

{: .note}

{% glossary_definition term_id="statefulset" length="all" %}
{% endcapture %}
Expand Down Expand Up @@ -66,7 +69,7 @@ spec:
selector:
app: nginx
---
apiVersion: apps/v1beta2
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: web
Expand Down Expand Up @@ -152,6 +155,12 @@ PersistentVolume Claims. Note that, the PersistentVolumes associated with the
Pods' PersistentVolume Claims are not deleted when the Pods, or StatefulSet are deleted.
This must be done manually.

### Pod Name Label

When the StatefulSet controller creates a Pod, it adds a label, `statefulset.kubernetes.io/pod-name`,
that is set to the name of the Pod. This label allows you to attach a Service to a specific Pod in
the StatefulSet.

## Deployment and Scaling Guarantees

* For a StatefulSet with N replicas, when Pods are being deployed, they are created sequentially, in order from {0..N-1}.
Expand Down
2 changes: 1 addition & 1 deletion docs/tasks/run-application/mysql-statefulset.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: mysql
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: apps/v1beta2
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: cassandra
Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/stateful-application/web.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ spec:
selector:
app: nginx
---
apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: web
Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/stateful-application/webp.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ spec:
selector:
app: nginx
---
apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: web
Expand Down
2 changes: 1 addition & 1 deletion docs/tutorials/stateful-application/zookeeper.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ spec:
app: zk
maxUnavailable: 1
---
apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: zk
Expand Down