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

Revise bodyToStringParser to use MemoryDataStream #2881

Merged
merged 1 commit into from
Aug 31, 2024

Conversation

mikee47
Copy link
Contributor

@mikee47 mikee47 commented Aug 30, 2024

Better dynamic memory reallocation and avoids conversion to MemoryDataStream at end anyway Still has the weakness that the decode is unbounded so bad actors can kill system with large POST

Better dynamic memory reallocation and avoids conversion to MemoryDataStream at end anyway
Still has the weakness that the decode is unbounded so bad actors can kill system with large POST
Copy link

what-the-diff bot commented Aug 30, 2024

PR Summary

  • Inclusion of a new Library
    The MemoryDataStream library has been added.

  • Variable Type Modification
    The type of the variable 'data' has been changed. Previously, it was a 'String*', now it has been replaced with 'ReadWriteStream*' and 'MemoryDataStream*' in different places in the code.

  • Change in Request Body Set Method
    The way request body is set has been changed. Previously, we were setting the body with pass-by-value(std::move(*data)), but now we're passing the address of the data in memory(data). This amendment can provide performance improvements because moving all the data around certain operations could be computationally expensive.

@slaff slaff added this to the 6.0.0 milestone Aug 31, 2024
@slaff slaff merged commit 1e39a56 into SmingHub:develop Aug 31, 2024
46 checks passed
@mikee47 mikee47 deleted the feature/bodyparser-stream branch August 31, 2024 12:18
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.

2 participants