4
我正在使用以下代碼將數據從App Engine傳輸到BigQuery。目前請求被阻止。有沒有辦法使用這些請求異步使用這些請求(不使用deferred
庫或類似的)?異步insertAll使用python-api-client請求
credentials = AppAssertionCredentials(scope = 'https://www.googleapis.com/auth/bigquery')
http = credentials.authorize(httplib2.Http())
bigquery = build('bigquery', 'v2', http = http)
bigquery.tabledata().insertAll(
projectId = PROJECT_NUMBER,
datasetId = DATASET_ID,
tableId = TABLE_ID,
body = body).execute()
也許這將幫助https://cloud.google.com/appengine/docs/python/urlfetch/asynchronousrequests – 2014-11-24 14:07:19
@VincentBeltman謝謝,我熟悉並使用urlfetch rpc請求。我想知道是否有一種方法只使用'apiclient'而不是手動調度請求。 – Tzach 2014-11-24 14:08:39
就我所知,沒有這樣的事情。我實際上查看了整個代碼,但找不到任何代碼。那大概是半年左右。也許它改變了。 – 2014-11-24 14:11:08