Uh oh!
There was an error while loading. Please reload this page.
AIP-81 Add Insert Multiple Pools API - #44121
Conversation
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
9fa560e to
42e8a51Comparebugraoz93
commented
Nov 19, 2024
Looks good! Thanks for the changes @jason810496! I believe the CI failure is likely a transient error caused by a DNS issue that couldn’t resolve AWS S3 at that moment. |
Lee-W
commented
Nov 20, 2024
just reran. seems to work fine 👀 |
42e8a51 to
1ec682fComparejason810496
commented
Nov 20, 2024
Just resolved the issue with inserting duplicate pools by handling the database exception rather than adding extra logic to the |
Uh oh!
There was an error while loading. Please reload this page.
pierrejeambrun
commented
Nov 20, 2024
That would be great. You can create an issue to track that if you're not going to work on it directly just so we do not forget about it. If you plan on tackling that right away, no need to create an issue opening a PR is perfectly fine. |
pierrejeambrun
left a comment
There was a problem hiding this comment.
maybe this is not the best approach
Uh oh!
There was an error while loading. Please reload this page.
bde6004 to
510e373CompareUh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- handle exception from db level instead of application level
510e373 to
c9b67c1Comparejason810496
commented
Nov 22, 2024
Just fixed the nit. I will refactor all endpoints to adopt the global error handler for managing unique constraint violation errors in further PR. |
pierrejeambrun
commented
Nov 22, 2024
Nice. 🎉 What is great about that is the |
* Add bulk post pools, refactor post pool * Add 409 case for TestPostPool * Add test for bulk post pools * Remove unused status code, rename post_body to body * Refactor duplicate pool insert handling - handle exception from db level instead of application level * Add global database exception handler for fastapi * Remove manual handle for unique constraint exc * Refactor test_pools * Fix bound for TypeVar, type for comment
closes: #43896
related: #43657
Fix: Add
max_length=256forPoolPostBody.poolThe model defined in https://github.com/apache/airflow/blob/main/airflow/models/pool.py#L54 enforces a string length constraint on
Pool.pool. To maintain consistency, this constraint should also be validated at the router level.Refactor: Handle Duplicate Cases in
Insert PoolThe
Insert Pool(single insert) functionality should account for cases where a duplicate pool name is provided, asPool.poolis defined with auniqueconstraint.Feat: Add Insert Multiple Pools API
A new API endpoint for inserting multiple pools has been introduced as
/pools/bulk. Alternative names such as/pools/batchor/pools/multiplewere considered. Feedback on which name best describes the endpoint is welcome.