Go: file syncer service framework (#16579)

### Summary

./ragflow_main --syncer to start file syncer


config yaml file has following config
```
file_syncer:
  max_concurrent_syncs: 4 # concurrent file sync threads
  sync_interval: 3 # check interval

```

---------

Signed-off-by: Jin Hai <haijin.chn@gmail.com>
This commit is contained in:
Jin Hai
2026-07-03 11:14:02 +08:00
committed by GitHub
parent 62f94cd59b
commit 1aa8abe373
7 changed files with 262 additions and 14 deletions

View File

@@ -53,6 +53,7 @@ type Config struct {
DefaultSuperUser DefaultSuperUser `mapstructure:"default_super_user"`
Language string `mapstructure:"language"`
TaskExecutor TaskExecutorConfig `mapstructure:"task_executor"`
FileSyncer FileSyncerConfig `mapstructure:"file_syncer"`
}
// AdminConfig admin server configuration
@@ -76,6 +77,11 @@ type TaskExecutorConfig struct {
MessageQueueType string `mapstructure:"message_queue_type"`
}
type FileSyncerConfig struct {
MaxConcurrentSyncs int `mapstructure:"max_concurrent_syncs"`
SyncInterval int `mapstructure:"sync_interval"`
}
// UserDefaultLLMConfig user default LLM configuration
type UserDefaultLLMConfig struct {
DefaultModels DefaultModelsConfig `mapstructure:"default_models"`