I have a primary agent that carries out builds, database refreshes and some ftp deployments, the last two jobs taking 5 mins each. To prevent too much queuing i have setup additional agents to carry out the refresh and ftp jobs, however i would like to cater for peak demand by having further agents pick up these jobs if they are idle, but not unless all the other agents are busy as it will block their main task, e.g. web deployment.
Therefore I think it would be useful to rank the agents assigned to a resource. Then agents pick up the job associated with the resource by descending rank, so the web deployment agent doesn't pick up a refresh job before the other higher ranked agents get allocated.
Comments
2 comments
That's an interesting feature. Building on that, if the intent is to basically handle bottleneck scenarios, instead of "ranking" per-say, we could have a flag for each resource assigned to an agent:
Checking this flag would essentially make the agent not pick up a job with the matching resource right away, but only when all other agents with the flag unchecked are occupied. Would that be good enough? Or are there other scenarios you have in mind that could benefit from true ranking?
I considered if a primary agent /secondary agent approach would be good enough, which is basically what a flag to 'only pick up if no other matching agents are free' would give you, and it covered 90%.
However i think ranking of some form would help in the one case that triggered this post where i have one'secondary agent that is often free to do this overflow task, but I also have other agents that are not so avaialble but i may want to add to that resource pool, as third place agents with precedence given to the secondary overflow agent.
I understand that full ranking is getting a bit complicated for perhaps a rare case, so i would be happy with agents settings for primary resource, secondary resource, and tertiary resource as a possible solution (so for example agents with tertiary resource' build' will only get scheduled if all agents with primary or secondary resources set to 'build' are unavailable). Any interim move towards this, such as a flag, would be acceptable too.
Please sign in to leave a comment.