github.com/1aal/kubeblocks@v0.0.0-20231107070852-e1c03e598921/docs/release_notes/v0.1.0/template.md (about) 1 # KubeBlocks $kubeblocks_version ($today) 2 3 We're happy to announce the release of KubeBlocks $kubeblocks_version! 🚀 🎉 🎈 4 5 We would like to extend our appreciation to all contributors who helped make this release happen. 6 7 **Breaking changes** 8 * Reconstructed existing "dbaas.kubeblocks.io" API group to new "apps.kubeblocks.io" API group, affected following APIs: 9 - ClusterDefinition 10 - ClusterVersion 11 - Cluster 12 - ConfigConstraint 13 - OpsRequest 14 * Refactored ConfigTemplate related API, affected following APIs: 15 - ClusterDefinition 16 - ClusterVersion 17 18 * Existing APIs will no longer be functional, please make sure you have removed the deprecated APIs and transformed CRDs before upgrade. Please refer to the upgrade notes under this release notes. 19 20 **Highlights** 21 * Automatic pod container environment variables updates: 22 * [NEW] KB_POD_FQDN - KubeBlocks Cluster component workload associated headless service name, N/A if workloadType=Stateless. 23 * [NEW] KB_POD_IP - Pod IP address 24 * [NEW] KB_POD_IPS - Pod IP addresses 25 * [NEW] KB_HOST_IP - Host IP address 26 * [DEPRECATED] KB_PODIPS - Pod IP addresses 27 * [DEPRECATED] KB_PODIP - Pod IP address 28 * [DEPRECATED] KB_HOSTIP - Host IP address 29 * KB_POD_NAME - Pod Name 30 * KB_NAMESPACE - Namespace 31 * KB_SA_NAME - Service Account Name 32 * KB_NODENAME - Node Name 33 * KB_CLUSTER_NAME - KubeBlocks Cluster API object name 34 * KB_COMP_NAME - Running pod's KubeBlocks Cluster API object's `.spec.components.name` 35 * KB_CLUSTER_COMP_NAME - Running pod's KubeBlocks Cluster API object's `<.metadata.name>-<.spec.components.name>`, same name is used for Deployment or StatefulSet workload name, and Service object name 36 * New KubeBlocks addon extensions management (an addon components are part of KubeBlocks control plane extensions). Highlights include: 37 * New addons.extensions.kubeblocks.io API that provide running cluster installable check and auto-installation settings. 38 * Following addons are provided: 39 * Prometheus and Alertmanager 40 * AlertManager Webhook Adaptor 41 * Grafana 42 * KubeBlocks CSI driver 43 * S3 CSI driver 44 * Snapshot Controller 45 * KubeBlocks private network Load Balancer 46 * ApeCloud MySQL ClusterDefinition API 47 * Community PostgreSQL ClusterDefinition API 48 * Community Redis ClusterDefinition API 49 * Cluster availability demo application named NyanCat 50 * ClusterDefinition API `spec.connectionCredential` add following built-in variables: 51 * A random UUID v4 generator `$(UUID)` 52 * A random UUID v4 generator with BASE64 encoded `$(UUID_B64)` 53 * A random UUID v4 generator in UUID string then BASE64 encoded `$(UUID_STR_B64)` 54 * A random UUID v4 generator in HEX representation `$(UUID_HEX)` 55 * Service FQDN `$(SVC_FQDN)` placeholder, value pattern - $(CLUSTER_NAME)-$(1ST_COMP_NAME).$(NAMESPACE).svc, where 1ST_COMP_NAME is the 1st component that provide `ClusterDefinition.spec.componentDefs[].service` attribute 56 * Service ports `$(SVC_PORT_<NAME>)` placeholder 57 * example usage: 58 59 ```yaml 60 # ClusterDefinition API 61 kind: ClusterDefinition 62 metadata: 63 name: my-clusterdefinition 64 spec: 65 connectionCredential: 66 username: "admin" 67 "admin-password": "$(RANDOM_PASSWD)" 68 endpoint: "http://$(SVC_FQDN):$(SVC_PORT_http)" 69 70 componentsDefs: 71 - name: my-comp-type 72 service: 73 ports: 74 - name: http 75 port: 8123 76 77 # Cluster API 78 kind: Cluster 79 metadata: 80 name: my-cluster 81 namespace: my-ns 82 spec: 83 clusterDefinitionRef: my-clusterdefinition 84 componentSpecs: 85 - name: my-comp 86 type: my-comp-type 87 88 # output: 89 kind: Secret 90 metadata: 91 name: my-cluster-conn-credential 92 namespace: my-ns 93 labels: 94 "app.kubernetes.io/instance": my-cluster 95 stringData: 96 username: "admin" 97 admin-password: "<some random 8 characters password>" 98 endpoint: "http://my-cluster-my-comp.my-ns.svc:8123" 99 ``` 100 101 **Known issues and limitations** 102 * Limitations of cluster's horizontal scale operation: 103 * Only support VolumeSnapshot API to make a clone of Cluster's PV for syncing data when horizontal scaling. 104 * Only 1st pod container and 1st volume mount associated PV will be processed for VolumeSnapshot, do assure that data volume is placed in 1st pod container's 1st volume mount. 105 * Unused PVCs will be deleted in 30 minutes after scale in. 106 107 If you're new to KubeBlocks, visit the [getting started](https://github.com/apecloud/kubeblocks/blob/v$kubeblocks_version/docs/user_docs/quick_start_guide.md) page and get a quick start with KubeBlocks. 108 109 $warnings 110 111 See [this](#upgrading-to-kubeblocks-$kubeblocks_version) section to upgrade KubeBlocks to version $kubeblocks_version. 112 113 ## Acknowledgements 114 115 Thanks to everyone who made this release possible! 116 117 $kubeblocks_contributors 118 119 ## What's Changed 120 $kubeblocks_changes 121 122 ## Upgrading to KubeBlocks $kubeblocks_version 123 124 To upgrade to this release of KubeBlocks, follow the steps here to ensure a smooth upgrade. 125 126 Release Notes for `v0.3.0`: 127 - Rename CRD name `backupjobs.dataprotection.kubeblocks.io` to `backups.dataprotection.kubeblocks.io` 128 - upgrade KubeBlocks with the following command: 129 ``` 130 helm upgrade --install kubeblocks kubeblocks/kubeblocks --version 0.3.0 131 ``` 132 - after you upgrade KubeBlocks, check CRD `backupjobs.dataprotection.kubeblocks.io` and delete it 133 ``` 134 kubectl delete crd backupjobs.dataprotection.kubeblocks.io 135 ``` 136 - Rename CRD name `appversions.dbaas.kubeblocks.io` to `clusterversions.dbaas.kubeblocks.io` 137 - before you upgrade KubeBlocks, please backup your Cluster CR yaml first. 138 ``` 139 kubectl get cluster -oyaml > clusters.yaml 140 ``` 141 then replace all spec.appVersionRef to spec.clusterVersionRef in the clusters.yaml. 142 143 Then, handle OpsRequest CR the same way. 144 - after you upgrade KubeBlocks, you can delete the CRD `appversions.dbaas.kubeblocks.io` 145 ``` 146 kubectl delete crd appversions.dbaas.kubeblocks.io 147 ``` 148 the last step, use the above backup of Clusters and OpsRequests to apply them. 149 ``` 150 kubectl apply -f clusters.yaml 151 ``` 152 - Rename group name `dbaas.kubeblocks.io` to `apps.kubeblocks.io` 153 - upgrade kubeblocks to create new CRDs, after that, you can delete the CRDs with group name`dbaas.kubeblocks.io` 154 155 ## Breaking Changes 156 157 $kubeblocks_breaking_changes 158 * Refactored the use of labels. Existing clusters or config need to manually update their labels to ensure proper functionality. The following are specific changes: 159 - Pods of `statefulset` and `deployment` 160 - Replace label name from `app.kubernetes.io/component-name` to `apps.kubeblocks.io/component-name` 161 - Replace label name from `app.kubeblocks.io/workload-type` to `apps.kubeblocks.io/workload-type` 162 - Add label `app.kubernetes.io/version` with value `Cluster.Spec.ClusterVersionRef` 163 - Add label `app.kubernetes.io/component` with value `Cluster.Spec.ComponentSpecs.ComponentDefRef` 164 - CR `backuppolicytemplate` 165 - Replace label name from `app.kubernetes.io/created-by` to `app.kubernetes.io/managed-by` 166 - Configmap hosted by KubeBlocks and named with `*-env` suffix 167 - Replace label name from `app.kubernetes.io/config-type` to `apps.kubeblocks.io/config-type` 168 * With KubeBlocks Helm chart replaced its optional components install using sub-charts dependencies with Addons extensions API, previous version upgrade to this version will uninstall the optional components completely.