diff --git a/db/model/application.go b/db/model/application.go index ef39ddf8d..34bd40f12 100644 --- a/db/model/application.go +++ b/db/model/application.go @@ -74,7 +74,7 @@ type ConfigGroupItem struct { AppID string `gorm:"column:app_id" json:"-"` ConfigGroupName string `gorm:"column:config_group_name" json:"-"` ItemKey string `gorm:"column:item_key" json:"item_key"` - ItemValue string `gorm:"column:item_value" json:"item_value"` + ItemValue string `gorm:"column:item_value;type:longtext" json:"item_value"` } // TableName return tableName "application" diff --git a/db/mysql/mysql.go b/db/mysql/mysql.go index 24d48b6ff..8a6485d38 100644 --- a/db/mysql/mysql.go +++ b/db/mysql/mysql.go @@ -247,4 +247,7 @@ func (m *Manager) patchTable() { if err := m.db.Exec("alter table tenant_services_probe modify column cmd longtext;").Error; err != nil { logrus.Errorf("alter table tenant_services_probe error: %s", err.Error()) } + if err := m.db.Exec("alter table app_config_group_item modify column item_value longtext;").Error; err != nil { + logrus.Errorf("alter table app_config_group_item error: %s", err.Error()) + } }