Mange two differente activities, like a producer-consumer model.