Added sleep function as mongo.sleep, using nanosleep