event emitter , write in go lang