celeborn/docs/developers
Sanskar Modi b3f86f9acc [CELEBORN-1297][FOLLOWUP] Fix DB config service SQL file
### What changes were proposed in this pull request?

Fix the unique key to reflect correct columns names.

### Why are the changes needed?

Running current DB scripts give below error because `user` column was renamed to `name` (https://github.com/apache/celeborn/pull/2340) but the unique key was not updated correctly.

```
mysql> CREATE TABLE IF NOT EXISTS celeborn_cluster_tenant_config
    -> (
    ->     id           int          NOT NULL AUTO_INCREMENT,
    ->     cluster_id   int          NOT NULL,
    ->     tenant_id    varchar(255) NOT NULL,
    ->     level        varchar(255) NOT NULL COMMENT 'config level, valid level is TENANT,USER',
    ->     name         varchar(255) DEFAULT NULL COMMENT 'tenant sub user',
    ->     config_key   varchar(255) NOT NULL,
    ->     config_value varchar(255) NOT NULL,
    ->     type         varchar(255) DEFAULT NULL COMMENT 'conf categories, such as quota',
    ->     gmt_create   timestamp NOT NULL,
    ->     gmt_modify   timestamp NOT NULL,
    ->     PRIMARY KEY (id),
    ->     UNIQUE KEY `index_unique_tenant_config_key` (`cluster_id`, `tenant_id`, `user`, `config_key`)
    -> );
ERROR 1072 (42000): Key column 'user' doesn't exist in table
```

### Does this PR introduce _any_ user-facing change?

NA

### How was this patch tested?

Tested in local DB
```
mysql> CREATE TABLE IF NOT EXISTS celeborn_cluster_tenant_config
    -> (
    ->     id           int          NOT NULL AUTO_INCREMENT,
    ->     cluster_id   int          NOT NULL,
    ->     tenant_id    varchar(255) NOT NULL,
    ->     level        varchar(255) NOT NULL COMMENT 'config level, valid level is TENANT,USER',
    ->     name         varchar(255) DEFAULT NULL COMMENT 'tenant sub user',
    ->     config_key   varchar(255) NOT NULL,
    ->     config_value varchar(255) NOT NULL,
    ->     type         varchar(255) DEFAULT NULL COMMENT 'conf categories, such as quota',
    ->     gmt_create   timestamp NOT NULL,
    ->     gmt_modify   timestamp NOT NULL,
    ->     PRIMARY KEY (id),
    ->     UNIQUE KEY `index_unique_tenant_config_key` (`cluster_id`, `tenant_id`, `name`, `config_key`)
    -> );
Query OK, 0 rows affected (0.01 sec)
```

Closes #2740 from s0nskar/fix-db-script.

Authored-by: Sanskar Modi <sanskarmodi97@gmail.com>
Signed-off-by: Shuang <lvshuang.xjs@alibaba-inc.com>
2024-09-18 07:46:13 +08:00
..
client.md [CELEBORN-853][DOC] Document on LifecycleManager 2023-07-31 17:36:42 +08:00
configuration.md [CELEBORN-1297][FOLLOWUP] Fix DB config service SQL file 2024-09-18 07:46:13 +08:00
faulttolerant.md [CELEBORN-860][DOC] Document on ShuffleClient 2023-07-31 20:07:20 +08:00
glutensupport.md [CELEBORN-1486] Introduce ClickHouse Backend in Gluten Support document 2024-07-01 16:38:49 +08:00
helm-charts.md [CELEBORN-1425][HELM] Add helm chart unit tests to ensure manifests are rendered as expected 2024-05-15 19:17:30 +08:00
integrate.md [CELEBORN-1341][FOLLOWUP] Improve Celeborn document 2024-03-22 16:34:25 +08:00
jvmprofiler.md [CELEBORN-1299] Introduce JVM profiling in Celeborn Worker using async-profiler 2024-03-25 14:05:50 +08:00
lifecyclemanager.md [MINOR] Fix some typos 2023-10-12 20:34:07 +08:00
master.md [CELEBORN-853][DOC] Document on LifecycleManager 2023-07-31 17:36:42 +08:00
overview.md [INFRA] Remove incubator/incubating for graduation 2024-03-27 13:54:47 +08:00
sbt.md [CELEBORN-1543] Support Flink 1.20 2024-08-09 17:05:58 +08:00
shuffleclient.md [CELEBORN-1341][FOLLOWUP] Improve Celeborn document 2024-03-22 16:34:25 +08:00
slotsallocation.md [MINOR] Fix style and Gluten link in Developers Doc 2024-03-11 12:07:01 +08:00
storage.md [CELEBORN-1341] Improve Celeborn document 2024-03-20 15:02:05 +08:00
trafficcontrol.md [MINOR] Fix incorrect default resume ratio in trafficcontrol doc 2023-09-21 11:18:48 +08:00
worker.md [CELEBORN-877][DOC] Document on SBT 2023-08-11 12:17:55 +08:00
workerexclusion.md [CELEBORN-869][DOC] Document on Integrating Celeborn 2023-08-02 17:22:41 +08:00