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

sync wg changes #383

Merged
merged 14 commits into from
Aug 22, 2023
Merged

sync wg changes #383

merged 14 commits into from
Aug 22, 2023

Conversation

- perf: optimize Document.ValueToJSON()
- perf: avoid unneccesary intermediate JSON object generation on input
processing
internal/pkg/quotes/quotes.go Dismissed Show dismissed Hide dismissed
pvormste and others added 11 commits August 21, 2023 13:16
This fix improves drastically performance of enriching data in federated
services. The inner for loop in jsonparser.ArrayEach is bottleneck if
response to be enriched is large and has unique keys.

The reason is size of responseMapping will grow to size of input, making
computation n^2.
In our case the fix reduced time from 20minutes to 16 seconds for
response with hundred thousand objects.

Co-authored-by: phob0s <[email protected]>
Co-authored-by: Sergiy <[email protected]>
If the response type of a field on a root type is changed, the alias
checks would be bypassed by addCustomField.

Co-authored-by: David Stutt <[email protected]>
@sonarcloud
Copy link

sonarcloud bot commented Aug 21, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 32 Code Smells

No Coverage information No Coverage information
30.0% 30.0% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@pvormste pvormste merged commit 8693715 into master Aug 22, 2023
4 of 5 checks passed
@pvormste pvormste deleted the cherry/wg-sync branch August 22, 2023 12:03
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.

9 participants