Feat/azure pipelines license check - #7964
Conversation
…caler (kedacore#5573) Signed-off-by: yogita-mehta <yogitamehta3488@gmail.com>
Signed-off-by: Yogita Mehta <yogitamehta3488@gmail.com>
Signed-off-by: yogita-mehta <yogitamehta3488@gmail.com>
…om/yogita-mehta/keda into feat/azure-pipelines-license-check
Signed-off-by: yogita-mehta <yogitamehta3488@gmail.com>
…om/yogita-mehta/keda into feat/azure-pipelines-license-check
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
|
Thank you for your contribution! 🙏 Please understand that we will do our best to review your PR and give you feedback as soon as possible, but please bear with us if it takes a little longer as expected. While you are waiting, make sure to:
Once the initial tests are successful, a KEDA member will ensure that the e2e tests are run. Once the e2e tests have been successfully completed, the PR may be merged at a later date. Please be patient. Learn more about our contribution guide. |
|
Hi @rickbrouwer / @JorTurFer, I have recreated this PR to ensure it strictly follows the repository's default pull request template and checklist (my sincere apologies for messing up the template in the previous PR!). All the code, including the 4 new unit tests and the newly added E2E test suite for the azure_pipelines_license_check feature, is ready in this branch. Could you please take a look and trigger the E2E test pipelines when you have a moment? Thank you for your patience and guidance! |
|
Ensure “make generate-scalers-schema” has been run to update the outdated generated files |
Signed-off-by: yogita-mehta <yogitamehta3488@gmail.com>
|
Hi @rickbrouwer, |
|
Can you indicate what you did to create the schema’s? |
|
Hi @rickbrouwer, To create the updated schema files, I ran the I also noticed that the |
|
Ok. You must run that command from the root in the KEDA directory on your working branch. |
This PR adds an optional
enableLicenseCheckparameter to the Azure Pipelines scaler. When enabled, the scaler queries the Azure DevOps organization's parallel job license usage and caps the reported queue length to the number of currently available licenses. This prevents KEDA from over-provisioning agent pods (and reserving resources like IPs) for jobs that Azure DevOps cannot actually schedule due to license limits.This is disabled by default (
enableLicenseCheck: false) to preserve existing behavior for users who don't need it.If the license usage lookup fails, the scaler logs the error and gracefully falls back to the uncapped queue length rather than failing the scaler entirely.
Testing Done:
azure_pipelines_scaler_test.goverifying the limit, skip, and fallback behaviors.azure_pipelines_license_checkin the latest commit.Checklist
make generate-scalers-schemahas been run to update any outdated generated filesFixes #5573
Relates to #