def get_first_ready():
urls = ["http://www.google.com/", "http://www.blogspot.com/"]
context = ndb.get_context()
futures = [context.urlfetch(url) for url in urls]
first_future = ndb.Future.wait_any(futures)
return first_future.get_result().content
评论列表
文章目录