How to add priority to projects in Project Job Scheduling?

37 views
Skip to first unread message

Kent Zhang

unread,
Dec 6, 2022, 1:53:10 PM12/6/22
to OptaPlanner development
Hello everyone.
 
My scenario is based on the Project Job Scheduling example. Now I want to add a new feature to it. Each project has a priority (high - value 1, medium - value 2, low - value 3, meaning that the lower the value, the higher the priority) and tasks from projects with higher priority are executed earlier.
My approach is to add a constraint for this priority. When two tasks are assigned to the same resource and they are adjacent, I determine whether the project priority of the left task is higher than the right one, and if not, we subtract the project priority of the left task from the project priority of the right task, and the result is used as the penalty score.
But in the Project Job Scheduling example, the tasks on the same resource do not in a chain, so I cannot know which is the next task (right task) of a task under the same resource.


Can anyone give any advice?
Thanks in advance!
Reply all
Reply to author
Forward
Message has been deleted
0 new messages