Ejemplo n.º 1
0
        public void Run(Vsync.Group vsyncGroup)
        {
            List <Tuple <MessageType, List <string> > > msgs;

            _dependencyStructure = _partition >= 0 ?
                                   new DependencyStructure(_leaderCloudMakefiles [_partition], _debugFilename) : null;
            if ((_partition >= 0) && (_rank == 0))
            {
                FindInitialEntries();
            }
            while (true)
            {
                lock (_queueLock) {
                    while (_queue.Count == 0)
                    {
                        Monitor.Wait(_queueLock);
                    }
                    msgs = new List <Tuple <MessageType, List <string> > > (_queue);
                    _queue.Clear();
                }
                ProcessMessages(vsyncGroup, msgs);
                if ((_state == State.ACTIVE) && (_partition >= 0) && (_rank == _leaders [_partition].Count - 1))
                {
                    RunCloudMake(vsyncGroup);
                }
            }
        }
Ejemplo n.º 2
0
        public void Run(Vsync.Group vsyncGroup)
        {
            List <Tuple <MessageType, List <string> > > msgs;

            _dependencyStructure = _localCloudMakefile == null ? null :
                                   new DependencyStructure(_localCloudMakefile, _debugFilename);
            while (true)
            {
                lock (_queueLock) {
                    while (_queue.Count == 0)
                    {
                        Monitor.Wait(_queueLock);
                    }
                    msgs = new List <Tuple <MessageType, List <string> > > (_queue);
                    _queue.Clear();
                }
                ProcessMessages(vsyncGroup, msgs);
            }
        }