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

Gateway: Adds header optimization #2098

Merged
merged 10 commits into from
Jan 4, 2021
Merged

Conversation

j82w
Copy link
Contributor

@j82w j82w commented Dec 29, 2020

Pull Request Template

Description

This adds a optimized header for the gateway store model. This model wraps the existing header objects. This avoids iterating and doing string join on all the operations.

Top10AVGRps for gateway mode

Master: 11868.333333
Optimized: 12555.411765

Profiler shows it consumes %16 of CPU from code in main branch. After this PR the profiler no longer shows the conversion.
MicrosoftTeams-image (1)

Type of change

Please delete options that are not relevant.

  • [] Bug fix (non-breaking change which fixes an issue)
  • [] New feature (non-breaking change which adds functionality)
  • [] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [] This change requires a documentation update

Closing issues

To automatically close an issue: closes #IssueNumber

@kirankumarkolli
Copy link
Member

kirankumarkolli commented Dec 29, 2020

What's the RPS impact?

Fully materialization and optimization are two improvements.
Pattern still does lazy materialization, any performance numbers (like RPS, micro-benchmark)?

@j82w
Copy link
Contributor Author

j82w commented Dec 29, 2020

What's the RPS impact?

Still running RPS for direct mode to see if there is an impact. Gateway mode RPS is described in the PR description with roughly 5.6% gain.

public override int Count()
{
int count = 0;
if (this.dictionaryNameValueCollection.IsValueCreated)
Copy link
Member

Choose a reason for hiding this comment

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

Nice:smile:

@j82w j82w merged commit 82277d8 into master Jan 4, 2021
@j82w j82w deleted the users/jawilley/perf/httpHeaders branch January 4, 2021 21:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants