deploying pyramid apps on heroku

146 views
Skip to first unread message

Ottavio

unread,
Jun 19, 2012, 3:40:33 AM6/19/12
to pylons-...@googlegroups.com
Hi, I am testing heroku as a platform to deploy pyramid apps.

I notice an extremely low performance (2 seconds to provide a page) and I am wondering what can be the reason. I am not using sqlalchemy, I have my custom sql methods with psycopg2 and that have proven on other platforms to be fast.

I still suspect that the database is the bottleneck, particularly with establishing the connection. Do you have experience with heroku? Are you facing the same problem? And how do you solve it? I am thinking about using a persistent connection, but I don't know how to do it...

Alexandre Conrad

unread,
Jun 20, 2012, 2:39:29 PM6/20/12
to pylons-...@googlegroups.com
I'd recommend you log the time it takes for your pyramid views to respond, as well as the model functions you call to make DB access to try to narrow down where the bottleneck comes from.

2012/6/19 Ottavio <ott...@campana.vi.it>
Hi, I am testing heroku as a platform to deploy pyramid apps.

I notice an extremely low performance (2 seconds to provide a page) and I am wondering what can be the reason. I am not using sqlalchemy, I have my custom sql methods with psycopg2 and that have proven on other platforms to be fast.

I still suspect that the database is the bottleneck, particularly with establishing the connection. Do you have experience with heroku? Are you facing the same problem? And how do you solve it? I am thinking about using a persistent connection, but I don't know how to do it...

--
You received this message because you are subscribed to the Google Groups "pylons-discuss" group.
To view this discussion on the web visit https://groups.google.com/d/msg/pylons-discuss/-/SKT-rzUIrfkJ.
To post to this group, send email to pylons-...@googlegroups.com.
To unsubscribe from this group, send email to pylons-discus...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en.



--
Alex | twitter.com/alexconrad

Ottavio

unread,
Jun 21, 2012, 4:28:26 AM6/21/12
to pylons-...@googlegroups.com
Il giorno mercoledì 20 giugno 2012 20:39:29 UTC+2, Alexandre Conrad ha scritto:
I'd recommend you log the time it takes for your pyramid views to respond, as well as the model functions you call to make DB access to try to narrow down where the bottleneck comes from.

Well, after making some tests and by using the debug toolbar, I was able to find that the problem was establishing connections to the db. Thus I inserted a mechanism for connection pooling and I was able to get a 16x speed increase.
Reply all
Reply to author
Forward
0 new messages