Collect metrics on build stages

Merged Alessio Caiazza requested to merge 2505-collecting-metrics into master

What does this MR do?

Wrap each stage executions with a timestamped section identifier.

Sample output here:

Why was this MR needed?

See #2505 and

Are there points in the code the reviewer needs to double check?

Does this MR meet the acceptance criteria?

  • Documentation created/updated
  • Tests
    • Added for this feature/bug
    • All builds are passing
  • Branch has no merge conflicts with master (if you do - rebase it please)

What are the relevant issue numbers?

Closes #2505