Class TaskDispatcher

  • All Implemented Interfaces:
    ExtensionPoint

    @Extension
    public class TaskDispatcher
    extends QueueTaskDispatcher
    This QueueTaskDispatcher prevents any one Android emulator instance from being executed more than once concurrently on any one build machine.

    From the given Task, we form a hash of the emulator configuration and check whether any other build currently running on the given Node is already using this configuration. If so, we veto execution of the given Task.

    As Android emulator attributes will quite often be parameterised (especially for matrix builds), we attempt to expand as many variables as possible, i.e. from the environment of the Node and the axis combination for matrix builds. Because we are evaluating these parameters before the build has actually started, it's possible that the variable expansions made aren't 100% accurate, for example if there are earlier BuildWrapper instances contributing to the environment.