Skip to content

Commit

Permalink
rename func
Browse files Browse the repository at this point in the history
  • Loading branch information
matt2e committed Oct 22, 2024
1 parent 6193ee6 commit ad97a1d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions internal/buildengine/engine.go
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ func New(ctx context.Context, client DeployClient, projectRoot string, moduleDir

updateTerminalWithEngineEvents(ctx, e.EngineUpdates)

go e.watchForAutoRebuilds(ctx)
go e.watchForPluginEvents(ctx)
go e.watchForEventsToPublish(ctx)

configs, err := watch.DiscoverModules(ctx, moduleDirs)
Expand Down Expand Up @@ -1039,12 +1039,11 @@ func (e *Engine) newModuleMeta(ctx context.Context, config moduleconfig.Unvalida
}, nil
}

// listenForBuildUpdates listens for adhoc build updates and reports them to the listener.
// watchForPluginEvents listens for build updates from language plugins and reports them to the listener.
// These happen when a plugin for a module detects a change and automatically rebuilds.
func (e *Engine) watchForAutoRebuilds(originalCtx context.Context) {
func (e *Engine) watchForPluginEvents(originalCtx context.Context) {
for {
select {

case event := <-e.pluginEvents:
logger := log.FromContext(originalCtx).Module(event.ModuleName()).Scope("build")
ctx := log.ContextWithLogger(originalCtx, logger)
Expand Down

0 comments on commit ad97a1d

Please sign in to comment.