Hi, I will try to be objective:
The problems that I found: 1 - Seems that datetime.datetime.strptime is not threadsafe ( https://groups.google.com/group/google-appengine-python/browse_thread/thread/efbcffa181c32f33/48afebe467861674?pli=1 ) I needed to put a call to it on appengine_config.py following http://bugs.python.org/issue7980 2 - webapp2 follow PEP333, it seems that's why you need to specify str().encode('ascii') when sending response headers. I mean, if you do not specify it, str() will be the default coding (utf8 in my case). 3 - I'm not sure if before python2.7/webapp2, it was ok send ',' on cookie header. But, it was working on python2.5 and webapp. With python2.7 and webapp2 it stoped working. I replace it with '_' on cookie header. Now, the real problems: On python 2.5: most requests to my app uses only memcache.incr()/get()/set(). Some times the only thing that I need to do is an incr(). I'm using a global dict to cache things, and it was working pretty well. My instances latency is something *from 120ms to 200ms.* incr() is running* ~5ms,* same to get/set. Not more than *20ms* My app is CPU intensive, and is consuming* ~180 CPU seconds/sec running at 1300 req/sec* When I turn on appstats I'm able to see that my code (between the rpc calls) runs *from 80ms to 120ms, some times <20ms.* After changing to python 2.7 I noticed that inc()/get()/set() (memcache) takes *100ms+* to run. My code takes *1000ms+ to run.* Cpu seconds is* 350 CPU seconds/sec running at 1300 req/sec.* Instances latency increased to ~500ms In my opinion http://code.google.com/p/googleappengine/issues/detail?id=6323should be reopened. It's true that the latency is much better before issue 6323 be closed, but still not acceptable. Also, it's true that when using python 2.7 threadsafe=yes, the scheduler starts half of instances when running on python 2.5. But again, the latency is too high. By the way, I still not comfortable with the instance scheduler. Another thing that I noticed, is that when I change from python2.7 to python2.5 (appengine admin/versions), I get strange memcache errors: class Reference has no attribute '__new__' Traceback (most recent call last): File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/_webapp25.py", line 701, in __call__ handler.get(*groups) File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxxviews.py", line 29, in get self._get() File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxx/views.py", line 83, in _get output = rules.Process(nid, h, data, r, self.request) File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxx/rules.py", line 73, in Process match, location_info = geoip.GeoIP_Org.match(params, rule, geoip_ck) File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxx/matchers/geoip.py", line 101, in match return klass.compute_match(params, rule, cookie, storageclass=models.GeoIPOrg) File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxx/matchers/geoip.py", line 38, in compute_match geoip_row = klass.fetch_row(storageclass, params) File "/base/data/home/apps/xxxxxxx/xxxxxxxxx/xxxxxxx/matchers/geoip.py", line 68, in fetch_row cached_row = memcache.get(klass._row_key(addr)) File "/base/python_runtime/python_lib/versions/1/google/appengine/api/memcache/__init__.py", line 563, in get results = rpc.get_result() File "/base/python_runtime/python_lib/versions/1/google/appengine/api/apiproxy_stub_map.py", line 592, in get_result return self.__get_result_hook(self) File "/base/python_runtime/python_lib/versions/1/google/appengine/api/memcache/__init__.py", line 628, in __get_hook self._do_unpickle) File "/base/python_runtime/python_lib/versions/1/google/appengine/api/memcache/__init__.py", line 271, in _decode_value return do_unpickle(value) File "/base/python_runtime/python_lib/versions/1/google/appengine/api/memcache/__init__.py", line 404, in _do_unpickle return unpickler.load() File "/base/python_runtime/python_dist/lib/python2.5/pickle.py", line 852, in load dispatch[key](self) File "/base/python_runtime/python_dist/lib/python2.5/pickle.py", line 1077, in load_newobj obj = cls.__new__(cls, *args) AttributeError: class Reference has no attribute '__new__' I'm also trying to contact premier account sales team, but without success. It is very frustrating when you don't have to who ask for help. I know that there are a lot of good souls here :-) but most of time people are busy trying to solve their own problems. Making long story short, I need to choose between, save money (half of instances) or run fast. That should make sense, but in my opinion, python 2.7 should comes to save us money, running at same speed of python 2.5. Am I wrong ? Thank you for "listening me" :-) Cheers -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
