Skip to content

Commit

Permalink
[ENH] Add error trace in log service for GetAllCollectionInfoToCompact (
Browse files Browse the repository at this point in the history
#2548)

## Description of changes

*Summarize the changes made by this PR.*
 - Improvements & Bug fixes
	 - Traces the error msg in honeycomb/jaeger

## Test plan
*How are these changes tested?*
- [x] Tests pass locally with `pytest` for python, `yarn test` for js, `cargo test` for rust

## Documentation Changes
None
  • Loading branch information
sanketkedia committed Jul 19, 2024
1 parent e15bd13 commit 28b3739
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions go/pkg/log/repository/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,11 @@ func (r *LogRepository) GetAllCollectionInfoToCompact(ctx context.Context, minCo
if collectionToCompact == nil {
collectionToCompact = []log.GetAllCollectionsToCompactRow{}
}
if err != nil {
trace_log.Error("Error in getting collections to compact from record_log table", zap.Error(err))
} else {
trace_log.Info("Got collections to compact from record_log table", zap.Int("collectionCount", len(collectionToCompact)))
}
return
}
func (r *LogRepository) UpdateCollectionCompactionOffsetPosition(ctx context.Context, collectionId string, offsetPosition int64) (err error) {
Expand Down

0 comments on commit 28b3739

Please sign in to comment.