我正在嘗試將數據加載到BigQuery中,並且加載作業將無限期地保留在掛起狀態(我等待大約5分鐘)。我還需要做些什麼才能將工作轉移到運行狀態?在應用引擎上運行BigQuery加載作業會陷入掛起狀態
log.log(new LogRecord(Level.INFO, "Writing to big query table"));
JobConfigurationLoad loadConf = new JobConfigurationLoad();
loadConf.setDestinationTable(new TableReference().setProjectId(PROJECT_ID)
.setDatasetId(datasetId).setTableId(TABLE_ID));
loadConf.setWriteDisposition("WRITE_APPEND");
loadConf.setSourceUris(Arrays.asList("gs://" + bucket + "/" + "something.json"));
JobConfiguration configuration = new JobConfiguration().setLoad(loadConf);
Job loadJob = new Job().setConfiguration(configuration);
Jobs.Insert insertData = bigQuery.jobs().insert(PROJECT_ID, loadJob);
Job insertResp = insertData.execute();
JobStatus status = insertResp.getStatus();
while (!status.getState().equals("done")) {
System.out.println(status.getState());
status = insertResp.getStatus();
Thread.sleep(10000);
}
...
進口的要求BigQuery的排隊我們有超過進口了大約一個經驗1小時,因此請嘗試等待更多,您應該使用任務API或後端來監視此類工作,因爲請求和任務超時 –
您能否發送處於掛起狀態的作業的作業ID? –
pogoapps.com:pogoapps:job_9c2f67bee94342f397daa07fcb004568 –