Basic async nodejs module based on events