Skip to content

Commit

Permalink
Merge pull request #110 from Maple-pro/dev
Browse files Browse the repository at this point in the history
fix(video): delete connection close
  • Loading branch information
liaosunny123 authored Aug 22, 2023
2 parents 166a7bb + 26d2b41 commit cd94f1d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/services/publish/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func main() {

var srv PublishServiceImpl
var probe healthImpl.ProbeImpl
defer CloseMQConn()
//defer CloseMQConn()
publish.RegisterPublishServiceServer(s, srv)
health.RegisterHealthServer(s, &probe)
if err := consul.RegisterConsul(config.PublishRpcServerName, config.PublishRpcServerPort); err != nil {
Expand Down
8 changes: 8 additions & 0 deletions src/services/videoprocessor/summary.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ func SummaryConsume(channel *amqp.Channel) {
}).Errorf("Failed to get summary of an audio from ChatGPT")
logging.SetSpanError(span, err)
summary = ""

errorHandler(d, true, logger, &span)
span.End()
continue
}

select {
Expand All @@ -124,6 +128,10 @@ func SummaryConsume(channel *amqp.Channel) {
}).Errorf("Failed to get keywords of an audio from ChatGPT")
logging.SetSpanError(span, err)
keywords = ""

errorHandler(d, true, logger, &span)
span.End()
continue
}

// Update summary information to database
Expand Down

0 comments on commit cd94f1d

Please sign in to comment.