Re: 'MySQL server has gone away' with pool_recycle=1 , what's wrong here?

2007-10-31 Thread Atilla
Thanks Mike, it was indeed just wrong settings in the config file. I should pay more attention when looking through the documentation - I thought that there's something specific. It properly echoes back the queries now. It still doesn't explain why I would get Mysql has gone away though - I've

xml-rpc, authentication and sessions

2007-10-31 Thread oscar tackstrom
Hi, I'm developing a combined chat-bot/question answering system and plan to use xml-rpc with pylons to serve web clients. Since other parts of the project are already implemented in pylons (administration and database connections), I would rather not switch to Twisted for this. The server

Re: Reducing pylons app memory usage?

2007-10-31 Thread Marcin Kasperski
Just a (post-mortem?) note. After having very good experience from migration (on some non-pylons site) from moinmoin hosted on apache with fastcgi to moinmoin on twisted proxied behind nginx (I did not make any formal measures, but it just feels that the app runs faster) I opted for similar path

Re: Reducing pylons app memory usage?

2007-10-31 Thread Ben Bangert
On Oct 31, 2007, at 8:39 AM, Marcin Kasperski wrote: I am still not very happy with paster (~100MB virtual, 22MB resident), and hoping to search for some improvements here. But at least it is just one such process... Can you ask your ISP if the virtual is counting against some limit? The

Re: Reducing pylons app memory usage?

2007-10-31 Thread Marcin Kasperski
[server:main] threadpool_nworkers = 5 did not work for me. Resolved. One should use threadpool_workers = 5 (without 'n'). Then it works. Some observations in the next post. --~--~-~--~~~---~--~~ You received this message because you are

Re: Reducing pylons app memory usage?

2007-10-31 Thread Marcin Kasperski
Ben Bangert [EMAIL PROTECTED] writes: On Oct 31, 2007, at 8:39 AM, Marcin Kasperski wrote: I am still not very happy with paster (~100MB virtual, 22MB resident), and hoping to search for some improvements here. But at least it is just one such process... Can you ask your ISP

Re: Reducing pylons app memory usage?

2007-10-31 Thread Ben Bangert
On Oct 31, 2007, at 9:41 AM, Marcin Kasperski wrote: This is true. But this is also relatively easy to measure, it suffices to compare virtual size of the running app with virtual size of python which just loaded all the libraries. The latter is fairly well approximated by paster shell. The

Re: Reducing pylons app memory usage?

2007-10-31 Thread Graham Dumpleton
On Nov 1, 6:08 am, Ben Bangert [EMAIL PROTECTED] wrote: On Oct 31, 2007, at 9:41 AM, Marcin Kasperski wrote: This is true. But this is also relatively easy to measure, it suffices to compare virtual size of the running app with virtual size of python which just loaded all the libraries.

Re: model definition spread across several files

2007-10-31 Thread Ron Bickers
On Oct 31, 4:03 pm, Evert Rol [EMAIL PROTECTED] wrote: I have a quick question on what to do with the metadata object when my model definition is spread across several files. It's all in the same database, all different tables, but for my own logic, I'm defining parts in different model

Re: Reducing pylons app memory usage?

2007-10-31 Thread Ben Bangert
On Oct 31, 2007, at 4:44 PM, Graham Dumpleton wrote: What figures do you get for the above if you run: ulimit -s 512 in your shell prior to running the web application? You will need to exit the shell when done to get it back to default value. If the VPS Memory Limit (virtual memory size)

Re: Reducing pylons app memory usage?

2007-10-31 Thread Ben Bangert
On Oct 31, 2007, at 5:05 PM, Ben Bangert wrote: You can run Pylons with FastCGI, directly loading the Pylons app (thus no threadpools). This should work great with your nginx setup as well, and mitigate the Virtual issue from the thread size on linux. Your virtual should then hover around

Re: using use_unicode in mysql:// uri causes url_for crash in pylons

2007-10-31 Thread SamDonaldson
On my dev machine running pastehttpserver, I noticed that it only works if I use the use_unicode=1 param on my db uri, even after passing in the convert_unicode and encoding params to create_engine (note that I'm calling my own create_engine). Thanks, Saureen On Oct 30, 10:25 pm, Mike Orr

Re: using use_unicode in mysql:// uri causes url_for crash in pylons

2007-10-31 Thread Mike Orr
use_unicode and convert_unicode should not be used together. use_unicode makes MySQLdb convert the database values to Unicode. convert_unicode does the same thing in SQLAlchemy.. encoding twice will lead to exceptions or wrong values if there are any non-ASCII characters. If users paste text

Re: using use_unicode in mysql:// uri causes url_for crash in pylons

2007-10-31 Thread SamDonaldson
FYI, I noticed ths post that's very similar: http://groups.google.com/group/pylons-discuss/browse_thread/thread/42f2728b1f0264f7/59959f5bdd503884?lnk=gstq=FastCGI+Unicode+HTML I noticed that the url_for implementation for Routes 1.7 is different from Routes 1.6.8 under util.py. In 1.7, which