DistributedTaskScheduling / JobAdder

Source code of the JobAdder project
GNU General Public License v3.0
2 stars 1 forks source link

database: return cancelled but running jobs in get_schedule() #167

Closed ammen99 closed 4 years ago

ammen99 commented 4 years ago

Right now, the scheduler tries to get the schedule from the database, but looking at the code, this doesn't include cancelled-but-running jobs (these can be detected by looking at their assigned machine).

Also, the scheduler does not take these jobs into account.

I'll have to look into the scheduler part, @nikolatzotchev can you fix the database part?

nikolatzotchev commented 4 years ago

I could, is it really important for your tests? I'm asking just to know should I check it before doing my job.

ammen99 commented 4 years ago

You can add it in unit tests. If you see the docstring of the database, it says it should return ... types, and also these that have an assigned work machine.

It will be important for the tests since without this, a running job cannot be cancelled (its status will be set to cancelled, but this will never be forwarded to the dispatcher).