AydarZaynutdinov commented on a change in pull request #16121:
URL: https://github.com/apache/beam/pull/16121#discussion_r762998810
##########
File path: playground/backend/internal/code_processing/code_processing.go
##########
@@ -54,12 +60,14 @@ func Process(ctx context.Context, cacheService cache.Cache,
lc *fs_tool.LifeCycl
errorChannel := make(chan error, 1)
successChannel := make(chan bool, 1)
cancelChannel := make(chan bool, 1)
+ stopReadLogsChannel := make(chan bool, 1)
+ finishReadLogsChannel := make(chan bool, 1)
go cancelCheck(ctxWithTimeout, pipelineId, cancelChannel, cacheService)
executorBuilder, err :=
builder.SetupExecutorBuilder(lc.GetAbsoluteSourceFilePath(),
lc.GetAbsoluteBaseFolderPath(), lc.GetAbsoluteExecutableFilePath(), sdkEnv)
if err != nil {
- processSetupError(err, pipelineId, cacheService, ctxWithTimeout)
+ _ = processSetupError(err, pipelineId, cacheService,
ctxWithTimeout)
Review comment:
`processSetupError()` could return an error only if some error happens
during write status to cache:
```
func processSetupError(...) error {
logger.Errorf(...)
if err = utils.SetToCache(...); err != nil {
return err
}
return nil
}
```
All error processing is happening in the `utils.SetToCache` methods. So we
do not need this error and we could use `_` here.
Moreover on the next line (71) this method `retrun`s.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]