2

Change Job Queue Priority in Azure Pipelines

 2 years ago
source link: https://dev.to/n3wt0n/change-job-queue-priority-in-azure-pipelines-42oo
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Cover image for Change Job Queue Priority in Azure Pipelines

Change Job Queue Priority in Azure Pipelines

Sep 24

・2 min read

Have you ever had a bugfix which you needed to deploy right this minute but had to wait behind other CI and PR jobs?

Today I'm going to show you how to bump the priority of a queued job so it could be executed as soon as possible.

Video

As usual, if you are a visual learner, or simply prefer to watch and listen instead of reading, here you have the video with the whole explanation and demo, which to be fair is much more complete than this post.

Link to the video: https://youtu.be/hJsMq35KAMk

If you rather prefer reading, well... let's just continue :)

Let's Do It

So, how can we decide what job will run next in our Azure Pipelines?

Let's say you have a bunch of jobs and Pipelines run in the queue

They will each have their own spot in the queue, depending on how many agents you have, the degree of parallelism, etc.

To run a job next, aka make it jump the queue, just click on one of the queued items, then on the __Job_ you want to run.

In the Job Detail Page you'll see its status in the queue (8th, in the image above) and you'll have a Run Next button.

Click on it, and magically:

That job has been bumped 1st in the queue (and the Run Next button has disappeared).

You need to have the "Manage" permission on the pool, and this typically means pool administrators, to be able to see the new "Run next" button on the job details page.

Conclusions

Easy right? And super effective too.

This works with both the YAML Pipelines and the Classic Pipelines. Of course you'll still need available parallelism and a suitable agent to be able to run that job next.

What do you think of this feature? As I've mentioned before I think it is pretty useful if you need to have something "jumping the queue". Let me know in the comment section below what your thoughts are.

Also, checkout this video where I talk about how to avoid the most common DevOps mistakes.

Like, share and follow me πŸš€ for more content:

πŸ“½ YouTube
β˜• Buy me a coffee
πŸ’– Patreon
πŸ“§ Newsletter
🌐 CoderDave.io Website
πŸ‘• Merch
πŸ‘¦πŸ» Facebook page
πŸ±β€πŸ’» GitHub
πŸ‘²πŸ» Twitter
πŸ‘΄πŸ» LinkedIn
πŸ”‰ Podcast


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK