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

fix: avoid global unlimited config #89

Merged
merged 2 commits into from
Nov 18, 2023
Merged

fix: avoid global unlimited config #89

merged 2 commits into from
Nov 18, 2023

Conversation

Eomm
Copy link
Member

@Eomm Eomm commented Nov 18, 2023

fixes #88

I choose to use a number instead of adding a new long-lived object in memory to track the state of the event.
This reduces the memory footprint a bit.

@Uzlopak
Copy link
Contributor

Uzlopak commented Nov 18, 2023

How is the performance?

@Eomm
Copy link
Member Author

Eomm commented Nov 18, 2023

best of 3 runs. This branch win

This branch

warn x 79,974,928 ops/sec ±0.44% (100 runs sampled)
(node:45152) [FST_ERROR_CODE_1] FastifyWarning: message
(Use `node --trace-warnings ...` to show where the warning was created)
(node:45152) [FST_ERROR_CODE_3] FastifyWarning: message

main:

warn x 62,636,303 ops/sec ±0.28% (100 runs sampled)
(node:44977) [FST_ERROR_CODE_1] FastifyWarning: message
(Use `node --trace-warnings ...` to show where the warning was created)
(node:44977) [FST_ERROR_CODE_3] FastifyWarning: message

Copy link
Contributor

@Uzlopak Uzlopak left a comment

Choose a reason for hiding this comment

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

LGTM

@Uzlopak Uzlopak merged commit d455a6e into master Nov 18, 2023
21 checks passed
@Eomm Eomm deleted the fix-opts branch November 18, 2023 15:27
@jsumners jsumners mentioned this pull request Nov 27, 2023
Eomm added a commit that referenced this pull request Dec 2, 2023
Eomm added a commit that referenced this pull request Dec 2, 2023
* Revert "Use constants instead of magic numbers (#90)"

This reverts commit c56e1e8.

* Revert "fix: avoid global unlimited config (#89)"

This reverts commit d455a6e.
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.

All the warnings are either "fire once" or "unlimited" based on the flag passed to last "create" method
2 participants