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

rewrite of request events #286

Merged
merged 5 commits into from
Nov 24, 2023
Merged

Conversation

mgor
Copy link
Collaborator

@mgor mgor commented Nov 23, 2023

needed to simplify fix for #280.

RestApiUser now uses locust.contrib.fasthttp.FastHttpSession for synchronous requests as well.

RequestLogger and RequestHandler is not inherited by the load user implementation any more, but always added for users inheriting GrizzlyUser, and added as event listeners on the dedicated event hook.

A new GrizzlyEventHook, that does not filter exceptions.

ResponseContextManager is only used with in RestApiUser._request. All events are fired from GrizzlyUser.request (final), so it's done the same way for all users.

removed SftpUser, never used and does not work as intended as it was.
remove unused interfaces HttpRequests and FileRequests.

make sure that load users always have the "global" metadata dictionary and that any request tasks executed by a load user has a metadata dictionary that is the merged version of "global" metadata and any request specific metadata, where the request specific metadata has precedence over the global one.

mgor added 4 commits November 22, 2023 19:21
needed to simplify fix of Biometria-se#280.

RestApiUser uses locust.contrib.fasthttp.FastHttpSession for synchronous requests as well.

RequestLogger and RequestHandler is not inherited, but always added for users inheriting GrizzlyUser, and added as event listeners on the dedicated event hook.

A new GrizzlyEventHook, so let through all exceptions.

ResponseContextManager is only used with in RestApiUser._request, all events are fired from GrizzlyUser.request (final), so it's done the same for all users.
remove SftpUser, never used and does not work as intended as it was.
remove unused interfaces, HttpRequests and FileRequests.
and that any request tasks executed by a load user has a metadata dictionary that is the merged version of "global" metadata and any request specific metadata.

where the request specific metadata has precedence over the global one.
@mgor mgor requested a review from boffman November 23, 2023 15:43
@boffman boffman merged commit ab8b7e2 into Biometria-se:main Nov 24, 2023
@mgor mgor deleted the feature/issue_280 branch November 8, 2024 09:21
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.

None yet

2 participants