BigQuery使用insertAll流式传输数据

时间:2014-09-19 14:57:48

标签: google-app-engine google-bigquery

我们正在实施Google云端解决方案。我们对如何插入所有问题有疑问?

  1. 是否必须等待文件导入才会超时?
  2. 我们在测试流媒体代码时遇到此错误。
  3. 追踪(最近一次呼叫最后一次):

      File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/runtime/wsgi.py", line 266, in Handle
        result = handler(dict(self._environ), self._StartResponse)
      File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1529, in __call__
        rv = self.router.dispatch(request, response)
      File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1278, in default_dispatcher
        return route.handler_adapter(request, response)
      File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1102, in __call__
        return handler.dispatch()
      File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 570, in dispatch
        return method(*args, **kwargs)
      File "/base/data/home/apps/s~silicon-alpha-636/mytest.378795683110553780/oauth2client/appengine.py", line 714, in check_oauth
        resp = method(request_handler, *args, **kwargs)
      File "/base/data/home/apps/s~silicon-alpha-636/mytest.378795683110553780/main.py", line 378, in get
        get_cloud_storage(self, http)
      File "/base/data/home/apps/s~silicon-alpha-636/mytest.378795683110553780/main.py", line 359, in get_cloud_storage
        jsonData = json.dumps(json_row, ensure_ascii = False, sort_keys = True, indent = 4).encode('utf-8')
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/__init__.py", line 250, in dumps
        sort_keys=sort_keys, **kw).encode(obj)
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/encoder.py", line 209, in encode
        chunks = list(chunks)
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/encoder.py", line 434, in _iterencode
        for chunk in _iterencode_dict(o, _current_indent_level):
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/encoder.py", line 408, in _iterencode_dict
        for chunk in chunks:
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/encoder.py", line 332, in _iterencode_list
        for chunk in chunks:
      File "/base/data/home/runtimes/python27/python27_dist/lib/python2.7/json/encoder.py", line 409, in _iterencode_dict
        yield chunk
    DeadlineExceededError
    

1 个答案:

答案 0 :(得分:3)

目前,Python运行时有几个名为DeadlineExceededError的错误:

google.appengine.runtime.DeadlineExceededError:如果整个请求超时,通常在60秒后,或者10分钟的任务队列请求,则会引发。

google.appengine.runtime.apiproxy_errors.DeadlineExceededError:如果RPC超过其截止日期,则会引发。这通常为5秒,但可以使用“截止日期”选项为某些API设置。

google.appengine.api.urlfetch_errors.DeadlineExceededError:如果URLFetch超时则引发。

Dealing with DeadlineExceededErrors

了解详情