-
Notifications
You must be signed in to change notification settings - Fork 157
Job assign priority #431
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
base: master
Are you sure you want to change the base?
Job assign priority #431
Conversation
|
Thank you very much for your contribution, @pythonerdog @huamxu. These changes make sense to me, and all tests pass. That said, I don't use task priorities at all in my gearmand usage, so I'm a bit uncomfortable merging without getting a second opinion from @SpamapS. |
@esabol Thanks for your feedback. Further review is needed to make sure it works without any impacts |
|
Have you tested this with and without using the |
|
Yeah the scenario described is exactly the scenario round robin was
introduced to handle.
Will try and find some time to take a closer look this week.
…On Mon, Nov 3, 2025, 12:29 PM Ed Sabol ***@***.***> wrote:
*esabol* left a comment (gearman/gearmand#431)
<#431 (comment)>
Have you tested this with and without using the --round-robin option,
@pythonerdog <https://github.com/pythonerdog> ?
—
Reply to this email directly, view it on GitHub
<#431 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AADS6YHDR6PE6DHSZ7QUG3D326UKFAVCNFSM6AAAAACKYCLM3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTIOBSGQ3TCNRWGE>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Considering keep the round-robin feature not unaffected and test without using the |
|
Honestly, I think it may be time for us to make a release that makes
round-robin the default. It's hard to even describe the default behavior.
"Ignore priority if there are two queues" seems pretty counter-intuitive.
…On Mon, Nov 3, 2025 at 11:27 PM pythonerdog ***@***.***> wrote:
*pythonerdog* left a comment (gearman/gearmand#431)
<#431 (comment)>
Have you tested this with and without using the --round-robin option,
@pythonerdog <https://github.com/pythonerdog> ?
Considering keep the round-robin feature not unaffected and test without
using the --round-robin option.
I will do more tests with it, update later here
—
Reply to this email directly, view it on GitHub
<#431 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AADS6YHMLQXBSWSPFMTZUHT33BIOPAVCNFSM6AAAAACKYCLM3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTIOBUGI2DGMRXGM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
|
I have done the test with disabled / enabled round-robin in the business QA env (code review by CICD tool zuul https://zuul-ci.org/). Priority: normal for check pipeline, high for gate pipeline. disabled round-robin: enabled round-robin: I think this code will not affect the current round-robin feature. |
That wasn't my concern exactly, @pythonerdog. If I understand correctly, @SpamapS is saying that using the Before developing this pull request, did you try using the If we make |
Got the point, yes we have already try |
|
@pythonerdog wrote:
OK, good. Thank you for clarifying that point. |
|
@esabol may i ask what's the plan for next step or any other comment ? |
|
And I hope to find time in the next few days. Work has been unusually busy
the last few weeks.
…On Tue, Nov 18, 2025, 12:43 AM Ed Sabol ***@***.***> wrote:
*esabol* left a comment (gearman/gearmand#431)
<#431 (comment)>
@esabol <https://github.com/esabol> may i ask what's the plan for next
step or any other comment ? Our business want to use the community gearmand
purely. Thanks
I'm still waiting on @SpamapS <https://github.com/SpamapS> to review it.
—
Reply to this email directly, view it on GitHub
<#431 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AADS6YDCDKYXQURPZNUBAMD35LL3TAVCNFSM6AAAAACKYCLM3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTKNBWGIYTSNJXGU>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
|
Hey so I am not entirely sure I understand the scenario in which things are breaking down for you, but the code looks OK. What's not OK is there's no test that validates the behavior. If we're going to change a behavior, I would like to be sure it works. Can you write a test for this? |
This change primarily addresses the issue of task priority allocation, ensuring that higher-priority tasks are assigned first.
The current problem does not guarantee higher-priority task allocation in the following scenarios:
server_con->worker_list contains worker1 and worker2; worker1 has a medium-priority task, and worker2 has a high-priority task. The function will assign the medium-priority task when looping to worker1 and then break.
In our production environment, some lower priority Jenkins jobs were triggered eailer than higher. Configuration like this:
Jenkins has servral nodes (instance running test), each node can be configured servral executors and labels. Jenkins job use labels to select nodes to run jobs, one job can be configured more than one label and many jobs can be configured to the same label.
Jenkins gearman plugin as the interface to gearman server, which register functions to gearman server.
https://plugins.jenkins.io/gearman-plugin/