update map reduce code >> search key on a thread.