Handle events in processes