[google-appengine] BlobStore - DownloadError: ApplicationError: 2 [Errno 35] Resource temporarily unavailable
In my app, the user uploads one or more files as blobs, then the app takes the blobs, adds BlobReader objects of them to a SOAP request, and sends the request to an external server. I've tested the SOAP request sender outside GAE (using open(filename) instead of BlobReader), and also confirmed that the file uploads to the app correctly. It seems like maybe the error is due to the SOAP request sender being unable to read from the blobstore - does anyone have any idea how I can fix this? Below is the error: INFO 2011-02-09 00:22:14,856 dev_appserver.py:3317] GET /test HTTP/1.1 500 - INFO 2011-02-09 00:22:15,063 dev_appserver.py:3317] GET / favicon.ico HTTP/1.1 200 - WARNING 2011-02-09 00:22:25,498 urlfetch_stub.py:284] Stripped prohibited headers from URLFetch request: ['Content-Length'] ERROR2011-02-09 00:22:25,503 __init__.py:395] ApplicationError: 2 [Errno 35] Resource temporarily unavailable Traceback (most recent call last): File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/ GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/ google/appengine/ext/webapp/__init__.py, line 515, in __call__ handler.get(*groups) File /Users/iratecat/opal/opalapp/handlers.py, line 84, in get res = c.launchJob(cmd_args, blobs) File /Users/iratecat/opal/opalapp/opalclient.py, line 132, in launchJob resp = self.appServicePort.launchJob(req) File ./client/AppService_client.py, line 60, in launchJob response = self.binding.Receive(launchJobResponse.typecode) File ./client/ZSI/client.py, line 547, in Receive self.ReceiveSOAP(**kw) File ./client/ZSI/client.py, line 430, in ReceiveSOAP if not self.IsSOAP(): File ./client/ZSI/client.py, line 422, in IsSOAP self.ReceiveRaw() File ./client/ZSI/client.py, line 389, in ReceiveRaw response = self.h.getresponse() File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/ GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/ google/appengine/dist/httplib.py, line 203, in getresponse self._allow_truncated, self._follow_redirects) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/ GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/ google/appengine/api/urlfetch.py, line 241, in fetch return rpc.get_result() File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/ GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/ google/appengine/api/apiproxy_stub_map.py, line 530, in get_result return self.__get_result_hook(self) File /Applications/GoogleAppEngineLauncher.app/Contents/Resources/ GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/ google/appengine/api/urlfetch.py, line 325, in _get_fetch_result raise DownloadError(str(err)) DownloadError: ApplicationError: 2 [Errno 35] Resource temporarily unavailable -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Re: Set a default deadline for urlfetch?
Perfect - thank you! On Jan 18, 7:54 pm, Nick Johnson (Google) nick.john...@google.com wrote: Hi Jawon, You can do this by using an API call hook, like so: def urlfetch_timeout_hook(service, call, request, response): if call != 'Fetch': return # Make the default deadline 10 seconds instead of 5. if not request.has_deadline(): request.set_deadline(10.0) apiproxy_stub_map.apiproxy.GetPreCallHooks().Append( 'urlfetch_timeout_hook', urlfetch_timeout_hook, 'urlfetch') On Wed, Jan 19, 2011 at 2:41 PM, Jawon jawonl...@gmail.com wrote: Hi, My app (in Python) uses the ZSI SOAP library to make SOAP calls to an external server that is not under my control. From what I can tell, the SOAP requests take about 5 seconds - enough that I consistently run into the 5 second deadline of GAE's urlfetch. Because I'm using the ZSI library, I am unclear about where the urlfetch request call is being made, although I do have access to the source code. Is there a way to override the default deadline of the urlfetch library? Here is the error log: ApplicationError: 5 Traceback (most recent call last): File /base/python_runtime/python_lib/versions/1/google/appengine/ ext/webapp/__init__.py, line 517, in __call__ handler.post(*groups) File /base/data/home/apps/opalapp/1.3477302363 tel:+13477302363 97102974/ handlers.py, line 162, in post res = c.launchJob(cmd_args, inputs) File /base/data/home/apps/opalapp/1.3477302363 tel:+13477302363 97102974/ opalclient.py, line 122, in launchJob resp = self.appServicePort.launchJob(req) File ./client/AppService_client.py, line 60, in launchJob response = self.binding.Receive(launchJobResponse.typecode) File ./client/ZSI/client.py, line 545, in Receive self.ReceiveSOAP(**kw) File ./client/ZSI/client.py, line 428, in ReceiveSOAP if not self.IsSOAP(): File ./client/ZSI/client.py, line 420, in IsSOAP self.ReceiveRaw() File ./client/ZSI/client.py, line 387, in ReceiveRaw response = self.h.getresponse() File /base/python_runtime/python_dist/lib/python2.5/httplib.py, line 197, in getresponse self._allow_truncated, self._follow_redirects) File /base/python_runtime/python_lib/versions/1/google/appengine/ api/urlfetch.py, line 241, in fetch return rpc.get_result() File /base/python_runtime/python_lib/versions/1/google/appengine/ api/apiproxy_stub_map.py, line 530, in get_result return self.__get_result_hook(self) File /base/python_runtime/python_lib/versions/1/google/appengine/ api/urlfetch.py, line 331, in _get_fetch_result raise DownloadError(str(err)) DownloadError: ApplicationError: 5 Thank you, Jawon Lee -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.comgoogle-appengine%2Bunsubscrib e...@googlegroups.com . For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en. -- Nick Johnson, Developer Programs Engineer, App Engine Google Ireland Ltd. :: Registered in Dublin, Ireland, Registration Number: 368047 -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Multiple blob uploads in single POST form?
Hi, I want to upload multiple, varying number of blobs with a single POST request. It seems that as of April of last year, this wasn't supported, and someone has posted a JavaScript workaround: http://blog.notdot.net/2010/04/Implementing-a-dropbox-service-with-the-Blobstore-API-part-3-Multiple-upload-support. I couldn't find any information on the official GAE docs as to whether or not this is still the case. Before I dive into the workaround above, could someone confirm that GAE still does not support multiple blob uploads? Thanks, Jawon -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
[google-appengine] Set a default deadline for urlfetch?
Hi, My app (in Python) uses the ZSI SOAP library to make SOAP calls to an external server that is not under my control. From what I can tell, the SOAP requests take about 5 seconds - enough that I consistently run into the 5 second deadline of GAE's urlfetch. Because I'm using the ZSI library, I am unclear about where the urlfetch request call is being made, although I do have access to the source code. Is there a way to override the default deadline of the urlfetch library? Here is the error log: ApplicationError: 5 Traceback (most recent call last): File /base/python_runtime/python_lib/versions/1/google/appengine/ ext/webapp/__init__.py, line 517, in __call__ handler.post(*groups) File /base/data/home/apps/opalapp/1.347730236397102974/ handlers.py, line 162, in post res = c.launchJob(cmd_args, inputs) File /base/data/home/apps/opalapp/1.347730236397102974/ opalclient.py, line 122, in launchJob resp = self.appServicePort.launchJob(req) File ./client/AppService_client.py, line 60, in launchJob response = self.binding.Receive(launchJobResponse.typecode) File ./client/ZSI/client.py, line 545, in Receive self.ReceiveSOAP(**kw) File ./client/ZSI/client.py, line 428, in ReceiveSOAP if not self.IsSOAP(): File ./client/ZSI/client.py, line 420, in IsSOAP self.ReceiveRaw() File ./client/ZSI/client.py, line 387, in ReceiveRaw response = self.h.getresponse() File /base/python_runtime/python_dist/lib/python2.5/httplib.py, line 197, in getresponse self._allow_truncated, self._follow_redirects) File /base/python_runtime/python_lib/versions/1/google/appengine/ api/urlfetch.py, line 241, in fetch return rpc.get_result() File /base/python_runtime/python_lib/versions/1/google/appengine/ api/apiproxy_stub_map.py, line 530, in get_result return self.__get_result_hook(self) File /base/python_runtime/python_lib/versions/1/google/appengine/ api/urlfetch.py, line 331, in _get_fetch_result raise DownloadError(str(err)) DownloadError: ApplicationError: 5 Thank you, Jawon Lee -- You received this message because you are subscribed to the Google Groups Google App Engine group. To post to this group, send email to google-appengine@googlegroups.com. To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.