Added notification_event and semaphore.
Refactored channel.