-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better stats #70
Better stats #70
Conversation
2bd7c0b
to
906eeed
Compare
Codecov Report
@@ Coverage Diff @@
## main #70 +/- ##
==========================================
+ Coverage 66.99% 67.11% +0.12%
==========================================
Files 6 6
Lines 815 815
==========================================
+ Hits 546 547 +1
- Misses 165 166 +1
+ Partials 104 102 -2
Continue to review full report at Codecov.
|
@@ -758,23 +751,27 @@ func createArchive(ctx context.Context, db *sqlx.DB, config *Config, s3Client s3 | |||
return nil | |||
} | |||
|
|||
func createArchives(ctx context.Context, db *sqlx.DB, config *Config, s3Client s3iface.S3API, org Org, archives []*Archive) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this method can't actually error
if err != nil { | ||
log.WithError(err).WithField("archive_type", MessageType).Error("error archiving org messages") | ||
} | ||
totalMsgsArchived += countRecords(created) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
because dailies and monthlies are combined here, this double counts records archived
assert.Equal(t, int64(23), created[62].Size) | ||
assert.Equal(t, "f0d79988b7772c003d04a28bd7417a62", created[62].Hash) | ||
|
||
// no rollup for october since that had one invalid daily archive |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
despite what this comment claims, the test data doesn't have any failing messages
Return the number of archives that we fail to create, don't over report records archived