DIRACGrid/DIRAC — pull request #979 by KrzysztofCiba (2012-10-09 21:56:57+00:00)
Title: NEW: DMS/StrategyHandler

New implementation of DMS helper class StrategyHandler, instead of dynamic creation of dags for every scheduled file from now on StrategyHandler is keeping a graph of sites (nodes) and FTS channels (edges):

* each node (LCGSIte) keeps a dictionary of SE with 'read' and 'write' statuses get from RSS and updated every 300 s (update period is tunable by a new CS option 'RSSUpdatePeriod' in the StrategyHandler);
* each edge (FTSChannel) keeps nb of successful and failed files, fileput, throughput, ..., so we don't have to guess if the certain FTS channel exists or is active on every schedule attempted.

This allows to speed up file scheduling + better error reporting, as now StrategyHandler knows that FTS channel is not active or not defined (previously it was just raising some dummy exception to bail out from several nested for loops).

BTW in this PR there is also a general directed graph implementation (Core/Utilities/Graph.py) and unit tests for it as well as for the new StartegyHandler.