Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Moved endpoint execution outside of get_request_handler for profiling#1027

Merged
tiangolo merged 2 commits intofastapi:masterfrom
sm-Fifteen:endpoint-profiling
Feb 29, 2020
Merged

Moved endpoint execution outside of get_request_handler for profiling#1027
tiangolo merged 2 commits intofastapi:masterfrom
sm-Fifteen:endpoint-profiling

Conversation

@sm-Fifteen
Copy link
Contributor

At the reccomendation of@tiangolo in#701 (comment), I have moved the endpoint execution section fromrouting.get_request_handler.<locals>.app to a separate function (currently named_run_endpoint) in order to facilitate profiling. Internal functions and callable object properties make it difficult for profilers to identify the function object being called, and since each request is only associated to one endpoint (not counting dependencies), this makes possible to simply profile "the endpoit that was used" for any given request.

@codecov
Copy link

codecovbot commentedFeb 24, 2020
edited
Loading

Codecov Report

Merging#1027 intomaster willnot change coverage.
The diff coverage is100%.

Impacted file tree graph

@@          Coverage Diff           @@##           master   #1027   +/-   ##======================================  Coverage     100%    100%           ======================================  Files         294     297    +3       Lines        7732    7815   +83     ======================================+ Hits         7732    7815   +83
Impacted FilesCoverage Δ
fastapi/routing.py100% <100%> (ø)⬆️
fastapi/dependencies/utils.py100% <0%> (ø)⬆️
fastapi/openapi/utils.py100% <0%> (ø)⬆️
fastapi/utils.py100% <0%> (ø)⬆️
fastapi/exceptions.py100% <0%> (ø)⬆️
tests/test_response_model_sub_types.py100% <0%> (ø)
tests/test_response_model_invalid.py100% <0%> (ø)
tests/test_param_in_path_and_dependency.py100% <0%> (ø)

Continue to review full report at Codecov.

Legend -Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing data
Powered byCodecov. Last update9c3c9b6...29d08c4. Read thecomment docs.

@tiangolotiangolo merged commit1ce6788 intofastapi:masterFeb 29, 2020
@tiangolo
Copy link
Member

Great! I updated it a bit to re-use the precomputedis_coroutine.

Thanks for your contribution! 🚀 🎉 🍰

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@sm-Fifteen@tiangolo

Comments


[8]ページ先頭

©2009-2026 Movatter.jp