[google-appengine] Asynchronous URLfetch Google Analytics. What happens when I don't call get_result()

2010-08-04 Thread Albert
Hi!

I'm using Google Analytics for Mobile Browsers wherein I connect with
Google Analytics servers via my appengine app to track users.

For performance reasons, I'm thinking of using asynchronous URLfetch
to call the google analytics tracking url near the middle of my
request handler code.

Well, I'm not really interested in the result of that urlfetch, so I'm
not interested in calling get_result(). So I don't want my app to wait
for the result, and just increase the time for the user to wait. I
just want it successfully called.

The documentation for Asynchronous URLfetch (http://code.google.com/
appengine/docs/python/urlfetch/asynchronousrequests.html) states If
the app request timer expires while the app is waiting, the call is
canceled.

What does it mean by the call is canceled?

My current request handler usually returns within 40-70ms (without the
urlfetch), and I'd like to keep it that way.

I haven't tested this in production. Will this be an OK practice?

Thanks!

-- 
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-appeng...@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.



Re: [google-appengine] Asynchronous URLfetch Google Analytics. What happens when I don't call get_result()

2010-08-04 Thread Pieter Coucke
If you just want to call an url and you don't need the result, you can
perform the url fetch in a task and just add that task to a queue from your
request handler.



On Wed, Aug 4, 2010 at 12:33 PM, Albert albertpa...@gmail.com wrote:

 Hi!

 I'm using Google Analytics for Mobile Browsers wherein I connect with
 Google Analytics servers via my appengine app to track users.

 For performance reasons, I'm thinking of using asynchronous URLfetch
 to call the google analytics tracking url near the middle of my
 request handler code.

 Well, I'm not really interested in the result of that urlfetch, so I'm
 not interested in calling get_result(). So I don't want my app to wait
 for the result, and just increase the time for the user to wait. I
 just want it successfully called.

 The documentation for Asynchronous URLfetch (http://code.google.com/
 appengine/docs/python/urlfetch/asynchronousrequests.htmlhttp://code.google.com/%0Aappengine/docs/python/urlfetch/asynchronousrequests.html)
 states If
 the app request timer expires while the app is waiting, the call is
 canceled.

 What does it mean by the call is canceled?

 My current request handler usually returns within 40-70ms (without the
 urlfetch), and I'd like to keep it that way.

 I haven't tested this in production. Will this be an OK practice?

 Thanks!

 --
 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-appeng...@googlegroups.com.
 To unsubscribe from this group, send email to
 google-appengine+unsubscr...@googlegroups.comgoogle-appengine%2bunsubscr...@googlegroups.com
 .
 For more options, visit this group at
 http://groups.google.com/group/google-appengine?hl=en.



-- 
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-appeng...@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.