Documentation ¶
Index ¶
- func CreateAppBasicRes() context.BasicRes
- func CreateBasicRes(cfg config.ConfigReader, logger log.Logger, db *gorm.DB) context.BasicRes
- func DirectRun(cmd *cobra.Command, args []string, pluginTask plugin.PluginTask, ...)
- func GetMigrator() plugin.Migrator
- func InitMigrator(basicRes context.BasicRes) (plugin.Migrator, errors.Error)
- func LoadGoPlugins(basicRes context.BasicRes) errors.Error
- func LoadPlugins(basicRes context.BasicRes) errors.Error
- func LoadRemotePlugins(basicRes context.BasicRes) errors.Error
- func NewGormDb(configReader config.ConfigReader, logger log.Logger) (*gorm.DB, errors.Error)
- func NewGormDbEx(configReader config.ConfigReader, logger log.Logger, ...) (*gorm.DB, errors.Error)
- func RunCmd(cmd *cobra.Command)
- func RunPipeline(basicRes context.BasicRes, pipelineId uint64, ...) errors.Error
- func RunPluginSubTasks(ctx gocontext.Context, basicRes context.BasicRes, task *models.Task, ...) errors.Error
- func RunPluginTask(ctx gocontext.Context, basicRes context.BasicRes, task *models.Task, ...) errors.Error
- func RunTask(ctx gocontext.Context, basicRes context.BasicRes, ...) (err errors.Error)
- func UpdateProgressDetail(basicRes context.BasicRes, taskId uint64, ...)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateAppBasicRes ¶
CreateAppBasicRes returns a application level BasicRes instance based on .env/environment variables it is useful because multiple places need BasicRes including `main.go` `directrun` and `worker` keep in mind this function can be called only once
func CreateBasicRes ¶
CreateBasicRes returns a BasicRes based on what was given
func DirectRun ¶
func DirectRun(cmd *cobra.Command, args []string, pluginTask plugin.PluginTask, options map[string]interface{})
DirectRun direct run plugin from command line. cmd: type is cobra.Command args: command line arguments pluginTask: specific built-in plugin, for example: feishu, jira... options: plugin config
func GetMigrator ¶
GetMigrator returns the shared Migrator singleton
func InitMigrator ¶
InitMigrator a Migrator singleton
func LoadPlugins ¶
LoadPlugins load plugins from local directory
func NewGormDbEx ¶
func NewGormDbEx(configReader config.ConfigReader, logger log.Logger, sessionConfig *dal.SessionConfig) (*gorm.DB, errors.Error)
NewGormDbEx acts like NewGormDb but accept extra sessionConfig
func RunPipeline ¶
func RunPipeline( basicRes context.BasicRes, pipelineId uint64, runTasks func([]uint64) errors.Error, ) errors.Error
RunPipeline FIXME ...
func RunPluginSubTasks ¶
func RunPluginSubTasks( ctx gocontext.Context, basicRes context.BasicRes, task *models.Task, pluginTask plugin.PluginTask, progress chan plugin.RunningProgress, ) errors.Error
RunPluginSubTasks FIXME ...
func RunPluginTask ¶
func RunPluginTask( ctx gocontext.Context, basicRes context.BasicRes, task *models.Task, progress chan plugin.RunningProgress, ) errors.Error
RunPluginTask FIXME ...
func RunTask ¶
func RunTask( ctx gocontext.Context, basicRes context.BasicRes, progress chan plugin.RunningProgress, taskId uint64, ) (err errors.Error)
RunTask FIXME ...
func UpdateProgressDetail ¶
func UpdateProgressDetail(basicRes context.BasicRes, taskId uint64, progressDetail *models.TaskProgressDetail, p *plugin.RunningProgress)
UpdateProgressDetail FIXME ...
Types ¶
This section is empty.