Updated to create session logs for each component.
Ceaned-up the code.