Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

Go: fix migration (#17659)

Jin Hai34b99046a8d1
diff --git a/internal/entity/compilation_template.go b/internal/entity/compilation_template.go
index c788526e81..a4447d1b49 100644
--- a/internal/entity/compilation_template.go
+++ b/internal/entity/compilation_template.go
@@ -24,7 +24,7 @@ type CompilationTemplate struct {
Name string `gorm:"column:name;size:128;not null;index" json:"name"`
Description *string `gorm:"column:description;type:text" json:"description,omitempty"`
Kind string `gorm:"column:kind;size:64;not null;index" json:"kind"`
- Config JSONMap `gorm:"column:config;type:text;not null;default:'{}'" json:"config"`
+ Config JSONMap `gorm:"column:config;type:text;not null" json:"config"`
IsBuiltin bool `gorm:"column:is_builtin;not null;default:false;index" json:"is_builtin"`
Status *string `gorm:"column:status;size:1;default:1;index" json:"status,omitempty"`
BaseModel
diff --git a/internal/server/config/analytic_engine_config.go b/internal/server/config/analytic_engine_config.go
index 35bce352b3..1e72907b05 100644
--- a/internal/server/config/analytic_engine_config.go
+++ b/internal/server/config/analytic_engine_config.go
@@ -82,3 +82,7 @@ func (c *Config) parseClickhouseConfig(v *viper.Viper) error {
}
return nil
}
+
+func (c *Config) GetClickhouseConfig() ClickhouseConfig {
+ return c.analyticEngine.Clickhouse
+}
diff --git a/internal/server/config/open_telemetry_config.go b/internal/server/config/open_telemetry_config.go
index 14335566ad..4186227491 100644
--- a/internal/server/config/open_telemetry_config.go
+++ b/internal/server/config/open_telemetry_config.go
@@ -70,3 +70,7 @@ func (c *Config) ParseOpenTelemetryConfig(v *viper.Viper) error {
return nil
}
+
+func (c *Config) GetOpenTelemetryConfig() OpenTelemetryConfig {
+ return c.oTel
+}