Correcting L1 trigger printout and multithreading

This is an exact copy of PR #6704 to keep 73X up to date. The description of the original PR is below:

This PR modifies the output format of the L1 JSON by making sure that unassigned trigger bits (i.e. those without names) are included in the JSON file. This is necessary because the database expects vectors of a fixed size (even if the information in some entries is meaningless) whereas with the old approach the size could vary.

There is also a very small fix to the multithreading. A more thorough revision of the latter will be done after the mid-week global run.