-
Type: Improvement
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: BSON, Performance
First suggested here: https://github.com/mongodb/js-bson/pull/611#issuecomment-1942706746
Use Case
As a BSON user
I want Dates to decode as quickly as possible
So that my app is more resonsive
User Impact
- Performance improvement for parsing Dates
Dependencies
- None
Unknowns
- The Long's construction and toNumber() calls appear redundant but do they provide value?
- toNumber has some form of implicit truncation and precision loss
- Note: JS Date's cannot be greater than 8640000000000000 nor less than -8640000000000000
Acceptance Criteria
Implementation Requirements
- Parse Dates without creating a throw-away Long object
Testing Requirements
- Ensure Date's are constructed correctly and without extraneous objects
Documentation Requirements
- None
Follow Up Requirements
- None