ChannelLogsManager to insert ChannelLogs if needed.

Rather than inserting ChannelLogs from many places, we now do it
from a common class: ChannelLogsManager where we do necessary
checks if a log is to be inserted into DB along with triggering
other events if needed.