Skip to content

Commit 73839b3

Browse files
authored
Merge pull request #5 from apecloud/support/update-databases-structures
chore: update pg and kafka structure
2 parents dafce71 + b9a125b commit 73839b3

30 files changed

+154
-152
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
title: Kafka
3+
description: Kafka
4+
keywords: [Kafka]
5+
sidebar_position: 1
6+
---
7+
8+
# Kafka
9+
10+
Apache Kafka is a distributed streaming platform designed to build real-time pipelines and can be used as a message broker or as a replacement for a log aggregation solution for big data applications.
11+
12+
- A broker is a Kafka server that stores data and handles requests from producers and consumers. Kafka clusters consist of multiple brokers, each identified by a unique ID. Brokers work together to distribute and replicate data across the cluster.
13+
- KRaft was introduced in Kafka 3.3.1 in October 2022 as an alternative to Zookeeper. A subset of brokers are designated as controllers, and these controllers provide the consensus services that used to be provided by Zookeeper.
14+
15+
## Supported Features
16+
17+
### Lifecycle Management
18+
19+
| Topology | Horizontal<br/>scaling | Vertical <br/>scaling | Expand<br/>volume | Restart | Stop/Start | Configure | Expose | Switchover |
20+
|----------|------------------------|-----------------------|-------------------|-----------|------------|-----------|--------|------------|
21+
| Combined/Separated | Yes | Yes | Yes | Yes | Yes | Yes | Yes | N/A |
22+
23+
- Combine Mode: KRaft (Controller) and Broker components are combined in the same pod.
24+
- Separated Mode: KRaft (Controller) and Broker components are deployed in different pods.
25+
26+
### Versions
27+
28+
| Versions |
29+
|----------|
30+
| 2.7 | 2.7.0|
31+
| 3.3 | 3.3.2|
32+
33+
## Reference
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Create a cluster for Kafka
2+
title: Provision
33
description: Guide for cluster creation for kafka
44
keywords: [kafka, cluster, management]
5-
sidebar_position: 1
5+
sidebar_position: 2
66
sidebar_label: Create
77
---
88

@@ -37,7 +37,7 @@ This document shows how to create a Kafka cluster.
3737
```bash
3838
kbcli addon list
3939
>
40-
NAME TYPE STATUS EXTRAS AUTO-INSTALL
40+
NAME TYPE STATUS EXTRAS AUTO-INSTALL
4141
...
4242
kafka Helm Enabled true
4343
...
@@ -119,7 +119,7 @@ This document shows how to create a Kafka cluster.
119119
resources:
120120
requests:
121121
storage: 1Gi
122-
- name: kafka-exporter
122+
- name: kafka-exporter
123123
replicas: 1
124124
resources:
125125
limits:

docs/en/preview/kubeblocks-for-kafka/cluster-management/scale.mdx renamed to docs/en/preview/kubeblocks-for-kafka/03-scale.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: Scale for a Kafka cluster
2+
title: Scale
33
description: How to scale a Kafka cluster, horizontal scaling, vertical scaling
44
keywords: [kafka, horizontal scaling, vertical scaling]
55
sidebar_position: 3
@@ -64,7 +64,7 @@ mycluster demo kafka kafka-3.3.2 Delete
6464
namespace: demo
6565
spec:
6666
clusterRef: mycluster
67-
type: VerticalScaling
67+
type: VerticalScaling
6868
verticalScaling:
6969
- componentName: broker
7070
requests:
@@ -175,7 +175,7 @@ mycluster demo kafka kafka-3.3.2 Delete
175175
1. Configure the parameters `--components`, `--memory`, and `--cpu` and run the command.
176176

177177
```bash
178-
kbcli cluster vscale mycluster -n demo --components="broker" --memory="4Gi" --cpu="2"
178+
kbcli cluster vscale mycluster -n demo --components="broker" --memory="4Gi" --cpu="2"
179179
```
180180

181181
- `--components` value can be `broker` or `controller`.
@@ -358,7 +358,7 @@ From v0.9.0, besides replicas, KubeBlocks also supports scaling in and out insta
358358
...
359359
spec:
360360
clusterDefinitionRef: kafka
361-
clusterVersionRef: kafka-3.3.2
361+
clusterVersionRef: kafka-3.3.2
362362
componentSpecs:
363363
- name: broker
364364
componentDefRef: broker
@@ -438,7 +438,7 @@ In the example below, a snapshot exception occurs.
438438

439439
```bash
440440
Status:
441-
conditions:
441+
conditions:
442442
- lastTransitionTime: "2023-02-08T04:20:26Z"
443443
message: VolumeSnapshot/mycluster-kafka-scaling-dbqgp: Failed to set default snapshot
444444
class with error cannot find default snapshot class
@@ -472,7 +472,7 @@ This exception occurs because the `VolumeSnapshotClass` is not configured. This
472472

473473
```bash
474474
kubectl delete backup -l app.kubernetes.io/instance=mycluster -n demo
475-
475+
476476
kubectl delete volumesnapshot -l app.kubernetes.io/instance=mycluster -n demo
477477
478478
```
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Stop/Start a Kafka cluster
2+
title: Stop/Start
33
description: How to start/stop a Kafka cluster
44
keywords: [kafka, stop a kafka cluster, start a kafka cluster]
5-
sidebar_position: 5
5+
sidebar_position: 4
66
sidebar_label: Stop/Start
77
---
88

@@ -57,7 +57,7 @@ You can stop/start a cluster to save computing resources. When a cluster is stop
5757
componentSpecs:
5858
- name: kafka
5959
componentDefRef: kafka
60-
disableExporter: true
60+
disableExporter: true
6161
replicas: 0 # Change this value
6262
...
6363
```
@@ -97,7 +97,7 @@ You can stop/start a cluster to save computing resources. When a cluster is stop
9797
</Tabs>
9898
9999
## Start a cluster
100-
100+
101101
1. Configure the name of your cluster and run the command below to start this cluster.
102102
103103
<Tabs>
@@ -116,7 +116,7 @@ You can stop/start a cluster to save computing resources. When a cluster is stop
116116
spec:
117117
clusterName: mycluster
118118
type: Start
119-
EOF
119+
EOF
120120
```
121121
122122
</TabItem>
@@ -138,7 +138,7 @@ You can stop/start a cluster to save computing resources. When a cluster is stop
138138
componentSpecs:
139139
- name: kafka
140140
componentDefRef: kafka
141-
disableExporter: true
141+
disableExporter: true
142142
replicas: 1 # Change this value
143143
...
144144
```
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Restart Kafka cluster
2+
title: Restart
33
description: How to restart a Kafka cluster
44
keywords: [kafka, restart]
5-
sidebar_position: 4
5+
sidebar_position: 5
66
sidebar_label: Restart
77
---
88

@@ -36,7 +36,7 @@ The pod role may change after the cluster restarts.
3636
namespace: demo
3737
spec:
3838
clusterName: mycluster
39-
type: Restart
39+
type: Restart
4040
restart:
4141
- componentName: broker
4242
EOF
@@ -63,7 +63,7 @@ The pod role may change after the cluster restarts.
6363
<TabItem value="kbcli" label="kbcli">
6464
6565
1. Restart a cluster.
66-
66+
6767
Configure the values of `components` and `ttlSecondsAfterSucceed` and run the command below to restart a specified cluster.
6868
6969
```bash
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Expand volume
33
description: How to expand the volume of a kafka cluster
44
keywords: [kafka, expand volume, volume expansion]
5-
sidebar_position: 4
5+
sidebar_position: 6
66
sidebar_label: Expand volume
77
---
88

@@ -107,12 +107,12 @@ mycluster demo kafka kafka-3.3.2 Delete
107107
kind: Cluster
108108
metadata:
109109
name: mycluster
110-
namespace: demo
110+
namespace: demo
111111
spec:
112112
clusterDefinitionRef: kafka
113113
clusterVersionRef: kafka-3.3.2
114114
componentSpecs:
115-
- name: kafka
115+
- name: kafka
116116
componentDefRef: kafka
117117
volumeClaimTemplates:
118118
- name: data
@@ -148,7 +148,7 @@ mycluster demo kafka kafka-3.3.2 Delete
148148
1. Configure the resources according to your needs and run the command to expand the volume.
149149
150150
```bash
151-
kbcli cluster volume-expand mycluster -n demo --storage=30Gi --components=kafka --volume-claim-templates=data
151+
kbcli cluster volume-expand mycluster -n demo --storage=30Gi --components=kafka --volume-claim-templates=data
152152
```
153153
154154
- `--components` describes the component name for volume expansion.

docs/en/preview/kubeblocks-for-kafka/configuration/configuration.mdx renamed to docs/en/preview/kubeblocks-for-kafka/07-reconfigure.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
---
2-
title: Configure cluster parameters
2+
title: Reconfigure
33
description: Configure cluster parameters
44
keywords: [kafka, parameter, configuration, reconfiguration]
5-
sidebar_position: 1
5+
sidebar_position: 7
66
---
77

88
import Tabs from '@theme/Tabs';
99
import TabItem from '@theme/TabItem';
1010

11-
# Configure cluster parameters
11+
# Reconfigure cluster parameters
1212

1313
The KubeBlocks configuration function provides a set of consistent default configuration generation strategies for all the databases running on KubeBlocks and also provides a unified parameter configuration interface to facilitate managing parameter configuration, searching the parameter user guide, and validating parameter effectiveness.
1414

@@ -158,7 +158,7 @@ You can also view the details of this configuration file and parameters.
158158
```
159159

160160
* View the user guide of a specified parameter.
161-
161+
162162
```bash
163163
kbcli cluster explain-config mycluster -n demo --param=log.cleanup.policy
164164
```
@@ -177,9 +177,9 @@ You can also view the details of this configuration file and parameters.
177177
Scope: Global
178178
Dynamic: false
179179
Type: string
180-
Description: The default cleanup policy for segments beyond the retention window. A comma separated list of valid policies.
180+
Description: The default cleanup policy for segments beyond the retention window. A comma separated list of valid policies.
181181
```
182-
182+
183183
</details>
184184

185185
* Allowed Values: It defines the valid value range of this parameter.
@@ -314,7 +314,7 @@ After the configuration is completed, you can search the configuration history a
314314
View the parameter configuration history.
315315

316316
```bash
317-
kbcli cluster describe-config mycluster -n demo
317+
kbcli cluster describe-config mycluster -n demo
318318
```
319319

320320
From the above results, there are three parameter modifications.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Connect to a Kafka cluster
2+
title: Connect
33
description: Guide for cluster creation for kafka
44
keywords: [kafka, cluster, connect, network]
5-
sidebar_position: 2
5+
sidebar_position: 8
66
sidebar_label: Connect
77
---
88

@@ -28,7 +28,7 @@ Within the same Kubernetes cluster, you can directly access the Kafka cluster wi
2828

2929
```bash
3030
kubectl get svc -n demo
31-
>
31+
>
3232
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
3333
kubernetes ClusterIP 10.43.0.1 <none> 443/TCP 9d
3434
mycluster-kafka-cluster-broker-headless ClusterIP None <none> 9092/TCP,9093/TCP,9094/TCP,5556/TCP 7d16h
@@ -61,7 +61,7 @@ Within the same Kubernetes cluster, you can directly access the Kafka cluster wi
6161
4. Create producer.
6262

6363
```bash
64-
kafka-console-producer.sh --topic quickstart-events --bootstrap-server xxx-broker:9092
64+
kafka-console-producer.sh --topic quickstart-events --bootstrap-server xxx-broker:9092
6565
```
6666

6767
5. Enter:"Hello, KubeBlocks" and press Enter.
@@ -120,7 +120,7 @@ If you use AWS EKS, you may want to access to the Kafka cluster from EC2 instanc
120120
memory: 1Gi
121121
serviceAccountName: kb-sa-kafka
122122
services:
123-
- annotations:
123+
- annotations:
124124
service.beta.kubernetes.io/aws-load-balancer-type: nlb
125125
service.beta.kubernetes.io/aws-load-balancer-internal: "true"
126126
name: vpc
@@ -206,7 +206,7 @@ The current version only supports Kafka broker with a single replica (combined:
206206
memory: 1Gi
207207
serviceAccountName: kb-sa-kafka
208208
services:
209-
- annotations:
209+
- annotations:
210210
service.beta.kubernetes.io/aws-load-balancer-type: nlb
211211
service.beta.kubernetes.io/aws-load-balancer-internal: "false"
212212
name: vpc
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Resource description
33
description: Kafka resource description
44
keywords: [kafka, java heap, hardware resource]
5-
sidebar_position: 3
5+
sidebar_position: 9
66
sidebar_label: Resource description
77
---
88

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
2-
title: Delete a kafka Cluster
2+
title: Delete
33
description: How to delete a kafka Cluster
44
keywords: [kafka, delete a cluster, delete protection]
5-
sidebar_position: 7
5+
sidebar_position: 10
66
sidebar_label: Delete protection
77
---
88

0 commit comments

Comments
 (0)