Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Original file line number Diff line number Diff line change
Expand Up @@ -31,57 +31,49 @@ The configuration structure has changed between chart versions:
Always refer to the latest [values.yaml](https://github.com/GreptimeTeam/helm-charts/blob/main/charts/greptimedb-cluster/values.yaml) in the Helm chart repository for the most up-to-date configuration structure.
:::

When defining the frontend groups, you must specify the name field for each frontend instance. Below is an example configuration that creates read and write frontend replicas:
When configuring frontend groups, ensure that each group includes a `name` field. The following `values.yaml` example demonstrates how to define separate frontend groups for read and write operations:

```yaml
apiVersion: greptime.io/v1alpha1
kind: GreptimeDBCluster
metadata:
name: greptimedb
namespace: default
spec:
initializer:
image: greptime/greptimedb-initializer:latest
base:
main:
image: greptime/greptimedb:latest
frontendGroups:
- name: read
replicas: 2
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
- name: write
replicas: 1
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
meta:
replicas: 1
backendStorage:
etcd:
endpoints:
- "etcd.etcd-cluster.svc.cluster.local:2379"
datanode:
replicas: 1
frontendGroups:
- name: read
replicas: 1
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
template:
main:
resources:
limits:
cpu: 2000m
memory: 2048Mi
- name: write
replicas: 1

meta:
replicas: 1
backendStorage:
etcd:
endpoints:
- "etcd.etcd-cluster.svc.cluster.local:2379"

datanode:
replicas: 1
```

You can use the following command to apply the configuration:
```
helm upgrade --install ${release-name} ${chart-name} --namespace ${namespace} -f values.yaml
```

## Validity

When setting the frontend groups, the name must be set.

```yaml
# This is an illegal configuration !!!
apiVersion: greptime.io/v1alpha1
kind: GreptimeDBCluster
metadata:
name: greptimedb
spec:
frontendGroups:
frontendGroups:
# - name: read #<=========The name must be set=============>
- replicas: 1
- replicas: 1
```

## Verify the Installation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,41 +31,39 @@ chart 版本之间的配置结构已发生变化:
请参考 chart 仓库中配置 [values.yaml](https://github.com/GreptimeTeam/helm-charts/blob/main/charts/greptimedb-cluster/values.yaml) 以获取最新的结构。
:::

定义 frontend 组时,必须为每个 frontend 实例指定名称字段。以下是创建读写 frontend 实例的示例配置
在配置 frontend 组时,确保每个组都包含 `name` 字段。以下 `values.yaml` 示例展示了如何为读写操作分别定义不同的 frontend

```yaml
apiVersion: greptime.io/v1alpha1
kind: GreptimeDBCluster
metadata:
name: greptimedb
namespace: default
spec:
initializer:
image: greptime/greptimedb-initializer:latest
base:
main:
image: greptime/greptimedb:latest
frontendGroups:
- name: read
replicas: 2
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
- name: write
replicas: 1
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
meta:
replicas: 1
backendStorage:
etcd:
endpoints:
- "etcd.etcd-cluster.svc.cluster.local:2379"
datanode:
replicas: 1
frontendGroups:
- name: read
replicas: 1
config: |
default_timezone = "UTC"
[http]
timeout = "60s"
template:
main:
resources:
limits:
cpu: 2000m
memory: 2048Mi
- name: write
replicas: 1

meta:
replicas: 1
backendStorage:
etcd:
endpoints:
- "etcd.etcd-cluster.svc.cluster.local:2379"

datanode:
replicas: 1
```

你可以使用以下命令应用上述配置:
```
helm upgrade --install ${release-name} ${chart-name} --namespace ${namespace} -f values.yaml
```

## 合规配置
Expand All @@ -74,14 +72,9 @@ spec:

```yaml
# 非法配置 !!!
apiVersion: greptime.io/v1alpha1
kind: GreptimeDBCluster
metadata:
name: greptimedb
spec:
frontendGroups:
# - name: read #<=========The name must be set=============>
- replicas: 1
frontendGroups:
# - name: read #<=========The name must be set=============>
- replicas: 1
```

## 校验安装
Expand Down