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

Remove types, refactor bson packages #260

Open
1 task
AlekSi opened this issue Jan 14, 2022 · 3 comments
Open
1 task

Remove types, refactor bson packages #260

AlekSi opened this issue Jan 14, 2022 · 3 comments
Assignees
Labels
area/types Issues about data types, BSON, wire protocol, etc code/chore Code maintenance improvements not ready Issues that are not ready to be worked on; PRs that should skip CI

Comments

@AlekSi
Copy link
Member

AlekSi commented Jan 14, 2022

Problems with the current design:

  1. If type conversion is used (for example, from bson.doubleType to float64), validation can be skipped, and we might want to make NaN values invalid in the future.
  2. If type conversion is not used, then too much copying might be required.
  3. "convert" functions are confusing.
  4. Too many types are exported.
  5. Remove nolint:deadcode.
  6. Reduce memory allocations.

DoD:

  • The issue number shouldn't be mentioned in the code anymore (all the places that mention it should be refactored).
@AlekSi AlekSi added the code/chore Code maintenance improvements label Jan 14, 2022
@AlekSi AlekSi self-assigned this Jan 16, 2022
AlekSi added a commit that referenced this issue Jan 19, 2022
@AlekSi AlekSi added this to the v0.0.6 milestone Jan 19, 2022
AlekSi added a commit that referenced this issue Jan 19, 2022
@AlekSi AlekSi modified the milestones: v0.0.6, v0.0.7 Feb 10, 2022
AlekSi referenced this issue in AlekSi/FerretDB Feb 11, 2022
AlekSi referenced this issue in AlekSi/FerretDB Feb 14, 2022
@AlekSi AlekSi changed the title Unexport bson package types Refactor types, bson, fjson packages Feb 14, 2022
@AlekSi AlekSi modified the milestones: v0.0.7, v0.1.0, v0.1.1, v0.2.0 Mar 31, 2022
@AlekSi AlekSi modified the milestones: v0.2.0, v0.2.1 May 4, 2022
@AlekSi AlekSi modified the milestones: v0.2.1, v0.3.0 May 17, 2022
@AlekSi AlekSi modified the milestones: v0.3.0, v0.3.1 Jun 1, 2022
@AlekSi AlekSi added the not ready Issues that are not ready to be worked on; PRs that should skip CI label Jun 17, 2022
@AlekSi AlekSi removed this from the v0.4.0 milestone Jun 23, 2022
@AlekSi AlekSi removed their assignment Sep 1, 2022
@rumyantseva
Copy link
Member

I close this issue as the description is not complete/accurate. For validation, we have epic #871, where the complete list of validation tasks is mentioned.

@rumyantseva rumyantseva closed this as not planned Won't fix, can't repro, duplicate, stale Sep 28, 2022
@rumyantseva rumyantseva reopened this Oct 10, 2022
@rumyantseva
Copy link
Member

I reopened the issue as its number is mentioned in a few places in the code.

@AlekSi would it be possible to improve the description? Currently, it contains your observations, but it's not straightforward why. E.g. "convert" functions are confusing - what do you mean? What is confusing about them? What needs to be changed?

@AlekSi
Copy link
Member Author

AlekSi commented Oct 10, 2022

They are horrible. There should be a better solution. I don't know better yet, that's why this task has "not ready" label

@AlekSi AlekSi self-assigned this Nov 10, 2022
@AlekSi AlekSi removed the validation label Dec 27, 2022
@AlekSi AlekSi added the area/types Issues about data types, BSON, wire protocol, etc label Sep 19, 2023
@AlekSi AlekSi changed the title Refactor types, bson, fjson packages Remove types, bson, refactor bson2 packages Mar 13, 2024
@AlekSi AlekSi changed the title Remove types, bson, refactor bson2 packages Remove types, refactor bson packages Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/types Issues about data types, BSON, wire protocol, etc code/chore Code maintenance improvements not ready Issues that are not ready to be worked on; PRs that should skip CI
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants