Skip to content
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

Use thread-safe FastDateFormat in TsUtils.scala #676

Merged
merged 1 commit into from
Feb 2, 2024

Conversation

divyamanohar-stripe
Copy link
Collaborator

@divyamanohar-stripe divyamanohar-stripe commented Feb 1, 2024

Summary

Use FastDateFormat instead of SimpleDateFormat in TsUtils.scala

Why / Goal

We recently introduced some parallelizations that included this logging in SawtoothOnlineAggregator.scala. Since SimpleDateFormat is not thread-safe, we ran into some race conditions with these logs. In order to resolve this, we can instead use the thread-safe FastDateFormat

Test Plan

  • Covered by existing CI
  • Tested in our QA environment

Reviewers

Copy link
Contributor

@nikhilsimha nikhilsimha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fantastic

Copy link
Collaborator

@piyushn-stripe piyushn-stripe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing!

@divyamanohar-stripe divyamanohar-stripe merged commit 32ba9c3 into master Feb 2, 2024
7 checks passed
@divyamanohar-stripe divyamanohar-stripe deleted the divyamanohar/tsutils-fastdateformat branch February 2, 2024 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants