Skip to content

Commit

Permalink
Merge pull request #93 from honeycombio/better-math
Browse files Browse the repository at this point in the history
Up the numbers. new scenario should last about every 6 hourish
  • Loading branch information
McSick authored Sep 9, 2024
2 parents 21613a9 + 117a7e8 commit ae64b77
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/checkoutservice/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ func mockDatabaseCall(ctx context.Context, maxTime int, name, query string) {
}

func loadDiscountFromDatabase(ctx context.Context, cachesize int) string {
numCalls := math.Max(1, math.Pow(float64(cachesize)/6000, 4)/350)
numCalls := math.Max(1, math.Pow(float64(cachesize)/6000, 4)/3000)
for i := float64(0); i < numCalls; i++ {
mockDatabaseCall(ctx, 250, "SELECT checkout.discounts", "SELECT * FROM discounts WHERE user = ?")
}
Expand Down

0 comments on commit ae64b77

Please sign in to comment.