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

🔖(api:minor) bump release to 0.17.0 #365

Merged
merged 1 commit into from
Jan 29, 2025
Merged

Conversation

jmaupetit
Copy link
Member

Added

  • Activate and configure Sentry profiling by setting the SENTRY_PROFILES_SAMPLE_RATE configuration
  • Set request's user (username) in Sentry's context
  • Add Localisation.coordonneesXY unique contraint [BC] 💥
  • Implement Statique materialized view

Changed

  • Prefetch user-related groups and operational units in get_user dependency
  • Improve bulk endpoints permissions checking
  • Cache logged user object for API_GET_USER_CACHE_TTL seconds to decrease the number of database queries
  • CLI: sort groups and operational units alphabetically in the list-groups command
  • Decrease the number of database queries for dynamic endpoints
  • Cache the "get PointDeCharge id from its id_pdc_itinerance" database query
  • Improve JSON string parsing using pyarrow engine
  • Add default values for optional Statique model fields
  • Migrate database enum types from names to values
  • Improve API performance by integrating the Statique materialized view
  • Upgrade alembic to 1.14.1
  • Upgrade geoalchemy2 to 0.17.0
  • Upgrade psycopg to 3.2.4
  • Upgrade pyarrow to 19.0.0
  • Upgrade pydantic to 2.10.5
  • Upgrade pydantic-extra-types to 2.10.2
  • Upgrade pydantic-settings to 2.7.1
  • Upgrade python-multipart to 0.0.20
  • Upgrade questionary to 2.1.0
  • Upgrade sentry-sdk to 2.20.0

Fixed

  • Rename database raccordementemum to raccordementenum
  • Run database migrations in a post-deploy hook

Removed

  • Remove Localisation.adresse_station unique constraint

Added:

- Activate and configure Sentry profiling by setting the
  `SENTRY_PROFILES_SAMPLE_RATE` configuration
- Set request's user (`username`) in Sentry's context
- Add `Localisation.coordonneesXY` unique contraint [BC] 💥
- Implement `Statique` materialized view

Changed:

- Prefetch user-related groups and operational units in `get_user` dependency
- Improve bulk endpoints permissions checking
- Cache logged user object for `API_GET_USER_CACHE_TTL` seconds to decrease the
  number of database queries
- CLI: sort groups and operational units alphabetically in the `list-groups`
  command
- Decrease the number of database queries for dynamic endpoints
- Cache the "get PointDeCharge id from its `id_pdc_itinerance`" database query
- Improve JSON string parsing using pyarrow engine
- Add default values for optional Statique model fields
- Migrate database enum types from names to values
- Improve API performance by integrating the `Statique` materialized view
- Upgrade alembic to `1.14.1`
- Upgrade geoalchemy2 to `0.17.0`
- Upgrade psycopg to `3.2.4`
- Upgrade pyarrow to `19.0.0`
- Upgrade pydantic to `2.10.5`
- Upgrade pydantic-extra-types to `2.10.2`
- Upgrade pydantic-settings to `2.7.1`
- Upgrade python-multipart to `0.0.20`
- Upgrade questionary to `2.1.0`
- Upgrade sentry-sdk to `2.20.0`

Fixed:

- Rename database `raccordementemum` to `raccordementenum`
- Run database migrations in a post-deploy hook

Removed:

- Remove `Localisation.adresse_station` unique constraint
@jmaupetit jmaupetit self-assigned this Jan 29, 2025
@jmaupetit jmaupetit added release API Item related to the API service labels Jan 29, 2025
Copy link

Current benchmark

Type Name Request Count Failure Count Median Response Time Average Response Time Min Response Time Max Response Time Average Content Size Requests/s Failures/s 50% 66% 75% 80% 90% 95% 98% 99% 99.9% 99.99% 100% git timestamp version
GET /auth/whoami 51 0 400.0 456.3036021960773 4.216188000015109 1764.8332690000077 160.0 1.753689503679551 0.0 400 620 670 680 840 1500 1500 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /dynamique/session/ 45 0 570.0 584.603280555556 7.736542999992935 1802.928745999992 45.0 1.5473730914819568 0.0 570 700 870 1100 1300 1500 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /dynamique/session/bulk 51 0 540.0 658.4087468235282 11.38348399999245 1875.3989439999827 411.0 1.753689503679551 0.0 540 800 1100 1100 1400 1800 1800 1900 1900 1900 1900 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /dynamique/status/ 49 0 420.0 576.7318345714308 10.889702000014267 1793.2235220000052 285.0 1.684917366280353 0.0 420 800 950 1100 1200 1500 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /dynamique/status/ 53 0 440.0 524.9648619622649 6.593931999987035 1753.5551219999943 45.0 1.822461641078749 0.0 440 720 810 940 1100 1500 1500 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /dynamique/status/FRALLEGO002006P3 50 0 520.0 560.5773270800001 10.482245999980933 1875.4531959999952 278.72 1.719303434979952 0.0 540 650 730 1000 1200 1500 1900 1900 1900 1900 1900 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /dynamique/status/FRALLEGO002006P3/history 48 0 440.0 572.1751363333342 16.527687000007063 1773.6994990000028 83928.91666666667 1.6505312975807538 0.0 480 750 950 990 1200 1500 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /dynamique/status/bulk 48 0 430.0 582.4789716041668 14.1938759999789 1834.9165630000075 411.0 1.6505312975807538 0.0 470 760 1100 1100 1200 1800 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /statique/ 42 16 410.0 474.9133276428577 24.45349799998553 1469.1767200000072 60.30952380952381 1.4442148853831596 0.5501770991935846 480 620 840 850 1100 1100 1500 1500 1500 1500 1500 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /statique/?limit=10 41 41 670.0 687.9675772926844 6.33770199999617 2118.817221 81.0 1.4098288166835606 1.4098288166835606 670 810 950 1000 1200 1800 2100 2100 2100 2100 2100 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /statique/?limit=100 43 43 620.0 626.9797892325578 32.518854999977975 1873.6425040000029 82.0 1.4786009540827587 1.4786009540827587 620 790 890 950 1100 1400 1900 1900 1900 1900 1900 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
PUT /statique/FR073EP7QU5233 46 0 410.0 490.1073120000008 26.961452999984203 1834.2858720000092 1371.0 1.5817591601815555 0.0 410 570 800 920 1000 1200 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
GET /statique/FRALLEGO002006P3 37 37 690.0 669.0815510270264 7.808661000012762 1785.9350850000055 111.0 1.2722845418851645 1.2722845418851645 690 810 990 1100 1200 1800 1800 1800 1800 1800 1800 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
POST /statique/bulk 43 0 950.0 925.269925697674 326.5739240000016 2111.001555999991 1094.8372093023256 1.4786009540827587 0.0 950 1100 1100 1400 1800 1800 2100 2100 2100 2100 2100 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0
Aggregated 647 137 530.0 594.889428825348 4.216188000015109 2118.817221 6543.0896445131375 22.24778644864058 4.710891411845068 530 750 930 1000 1200 1500 1800 1800 2100 2100 2100 9119819 2025-01-29 16:09:17.390006+00:00 0.17.0

Comparison with the latest previous benchmark

A lower (negative) value means the current version performs better than the previous one.

Type Name Request Count Failure Count Median Response Time Average Response Time Min Response Time Max Response Time Average Content Size Requests/s
GET /auth/whoami
POST /dynamique/session/
POST /dynamique/session/bulk
GET /dynamique/status/
POST /dynamique/status/
GET /dynamique/status/FRALLEGO002006P3
GET /dynamique/status/FRALLEGO002006P3/history
POST /dynamique/status/bulk
POST /statique/
GET /statique/?limit=10
GET /statique/?limit=100
PUT /statique/FR073EP7QU5233
GET /statique/FRALLEGO002006P3
POST /statique/bulk
Aggregated

@jmaupetit jmaupetit merged commit 6dbcda6 into main Jan 29, 2025
15 checks passed
@jmaupetit jmaupetit deleted the prepare-api-release-0.17.0 branch January 29, 2025 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Item related to the API service release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant