Match Platform and Worker messages properties
Description
Take into account the properties specified by the client with Platform messages inside Command messages as well as the analogous properties specified for workers.
Note: The Platform messages are in process of being standardized. Relevant discussion: https://github.com/bazelbuild/remote-apis/issues/38
Changes proposed in this merge request:
-
Allow passing platform attributes in the CLI.
-
Refactor the dummy requests: all
Actionsmust have acommand_digestset, otherwiseExecutionInstance.execute()will throw aFailedPreconditionErrorexception. Change the tests to reflect that. -
Refactor the
Jobclass to have a newplatform_propertiesattribute. -
Refactor the scheduler to try and match properties between worker and job before doing work assignments. The scheduler will now go through the queue looking for the first job that can be assigned to the worker.
-
As a placeholder while the
Platformmessage is standardized, compare only OS and ISAs by using a simple set logic comparison. The logic is implemented inScheduler._worker_is_capable(), to be modified in the future.