Introduced type of the record inserted into DAS mapping db; this allows to avoid quering mapping DB with  or  clauses. Instead I created index on type the record and modified all mapping db queries to use it
Re-factor code to use type of the record
Fix issue with passing block name as input parameter; return early in file_run_lumis API if no blocks are found