[2.1] Add support for migrating logs from 2.0 to 2.1

- some code cleanup and refactors
Minor nitpick, but wouldn't it be more succinct to pass the LegacyLogIoUtil as an argument directly instead of a boolean that selects it?