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

Improve groupby operation in GET /auth/group/ #1745

Closed

Conversation

tcompa
Copy link
Collaborator

@tcompa tcompa commented Sep 10, 2024

Checklist before merging

  • I added an appropriate entry to CHANGELOG.md
  • I added logging to new code - if appropriate.
  • I merged main into the current branch.

@tcompa tcompa linked an issue Sep 10, 2024 that may be closed by this pull request
Copy link

github-actions bot commented Sep 10, 2024

Benchmark comparison

GET /api/alive/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 0.8 1.0 0.80 0.0 0.0
power 0.8 1.0 0.80 0.0 0.0
dataset 0.8 0.9 0.89 0.0 0.0
project 0.8 1.0 0.80 0.0 0.0
job 0.8 1.0 0.80 0.0 0.0

GET /api/v2/dataset/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 8.7 10.0 0.87 0.7 0.7
power 410.2 424.8 0.97 440.2 440.2
dataset 158.3 173.9 0.91 171.2 171.2
project 46.8 52.3 0.89 58.9 58.9
job 27.3 29.8 0.92 41.7 41.7

GET /api/v2/job/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 5.7 6.3 0.90 2.2 2.2
power 135.2 146.6 0.92 652.4 652.4
dataset 136.8 147.6 0.93 905.6 905.6
project 43.8 47.6 0.92 283.9 283.9
job 36.7 39.3 0.93 225.0 225.0

GET /api/v2/project/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 6.2 6.4 0.97 0.1 0.1
power 6.1 6.2 0.98 0.1 0.1
dataset 6.1 6.2 0.98 0.1 0.1
project 8.0 8.3 0.96 2.3 2.3
job 6.1 6.3 0.97 0.1 0.1

GET /api/v2/workflow/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 12.4 13.5 0.92 0.8 0.8
power 23.7 25.5 0.93 29.8 29.8
dataset 18.3 19.7 0.93 17.1 17.1
project 22.2 22.6 0.98 21.5 21.5
job 10.1 10.7 0.94 0.9 0.9

POST /api/v2/project/3/dataset/402/images/query/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
dataset 146.1 155.9 0.94 275.1 275.1

GET /auth/current-user/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
vanilla 4.2 4.7 0.89 0.2 0.2
power 4.0 4.8 0.83 0.2 0.2
dataset 4.0 4.7 0.85 0.2 0.2
project 4.0 4.8 0.83 0.2 0.2
job 4.0 4.8 0.83 0.2 0.2

POST /auth/token/login/

User Time current (ms) Time main (ms) Ratio current/main Size current (Kb) Size main (Kb)
dataset 260.7 262.5 0.99 0.2 0.2

Copy link

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  fractal_server/app/routes/auth
  group.py 58
  fractal_server/app/runner/executors/slurm/sudo
  executor.py
Project Total  

This report was generated by python-coverage-comment-action

@tcompa
Copy link
Collaborator Author

tcompa commented Sep 10, 2024

Closing. See #1742

@tcompa tcompa closed this Sep 10, 2024
@tcompa tcompa deleted the 1742-try-using-groupby-in-get-usergroup-endpoints branch September 10, 2024 13:02
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.

Optimize getting aggregated group/users data in API
1 participant