From c805b43b6a5e41e42de9a406d94fb4c94bc79256 Mon Sep 17 00:00:00 2001 From: "halim.kim" Date: Sun, 21 Jul 2024 19:45:10 +0900 Subject: [PATCH] BIGTOP-4165: Correct MySQL DDL to make add host step progress --- README.md | 2 +- .../src/main/resources/ddl/MySQL-DDL-CREATE.sql | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 528280ca..391f00a6 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ Bigtop-Manager is a platform for managing Bigtop components. Inspired by Apache ## Prerequisites JDK: Requires JDK 17 or 21 -Metadata DB: Mariadb or Mysql +Metadata DB: Mariadb or Mysql(8 or above) ### API-DOCS [swagger-ui](http://localhost:8080/swagger-ui/index.html) diff --git a/bigtop-manager-server/src/main/resources/ddl/MySQL-DDL-CREATE.sql b/bigtop-manager-server/src/main/resources/ddl/MySQL-DDL-CREATE.sql index 8acb0776..c7a5f5f5 100644 --- a/bigtop-manager-server/src/main/resources/ddl/MySQL-DDL-CREATE.sql +++ b/bigtop-manager-server/src/main/resources/ddl/MySQL-DDL-CREATE.sql @@ -82,11 +82,11 @@ CREATE TABLE `host` `hostname` VARCHAR(255) DEFAULT NULL, `ipv4` VARCHAR(32) DEFAULT NULL, `ipv6` VARCHAR(32) DEFAULT NULL, - `os_arch` VARCHAR(32) NOT NULL, - `os_name` VARCHAR(32) NOT NULL, - `processor_count` INT NOT NULL, - `physical_memory` BIGINT NOT NULL COMMENT 'Total Physical Memory(Bytes)', - `state` VARCHAR(32) NOT NULL, + `arch` VARCHAR(32) DEFAULT NULL, + `os` VARCHAR(32) DEFAULT NULL, + `processor_count` INT DEFAULT NULL, + `physical_memory` BIGINT DEFAULT NULL COMMENT 'Total Physical Memory(Bytes)', + `state` VARCHAR(32) DEFAULT NULL, `create_time` DATETIME DEFAULT NULL, `update_time` DATETIME DEFAULT NULL, PRIMARY KEY (`id`), @@ -98,9 +98,9 @@ CREATE TABLE `repo` ( `cluster_id` BIGINT(20) UNSIGNED NOT NULL, `os` VARCHAR(32) DEFAULT NULL, `arch` VARCHAR(32) DEFAULT NULL, - `base_url` VARCHAR(32) DEFAULT NULL, + `base_url` VARCHAR(64) DEFAULT NULL, `repo_id` VARCHAR(32) DEFAULT NULL, - `repo_name` VARCHAR(32) DEFAULT NULL, + `repo_name` VARCHAR(64) DEFAULT NULL, `create_time` DATETIME DEFAULT NULL, `update_time` DATETIME DEFAULT NULL, PRIMARY KEY (`id`), @@ -123,7 +123,7 @@ CREATE TABLE `job` `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `cluster_id` BIGINT(20) UNSIGNED DEFAULT NULL, `state` VARCHAR(32) NOT NULL, - `context` VARCHAR(32) NOT NULL, + `context` TEXT NOT NULL, `create_time` DATETIME DEFAULT NULL, `update_time` DATETIME DEFAULT NULL, PRIMARY KEY (`id`),