handle message in goroutine