How to pick right value of capacitor while switching DC source
A capacitor may work but it has to have a large value. Your 12 volt boost converter supplying 0.5 amps may be taking something like 1.5 amps from your 5 volt power rail. Your 5 volt load is taking 0.6 amps. If I have misinterpreted your detail please say!
That's 2.1 amps in total.
It then boils down to how much droop or voltage sag you can permit on the 5 volt rail during the 1 second blackout. If you can permit the 5 volts to sag down to 4.5 volts then you can figure out how much capacitance you need using the capacitor formula: -
$$I = C\cdot\dfrac{dv}{dt}$$
So, if dv/dt is 0.5 volts per second and I = 2.1 amps, capacitance needs to be greater than 4.2 farads. Looks like you might need a supercap rated at 5 volts. Get one with the lowest ESR you can find or, simulate to see by how much ESR affects the droop.