From: | Sergio Mayoral <mayoralstuttgart(at)yahoo(dot)com> |
---|---|
To: | postgresql-perf <pgsql-performance(at)postgresql(dot)org> |
Subject: | PQconnectStart/PQconnectPoll |
Date: | 2012-11-15 09:02:57 |
Message-ID: | 1352970177.10135.YahooMailNeo@web39302.mail.mud.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
Hi,
i am running some tests to check performance between postgresql and mysql.
one important issue is PQconnectdb (PQconnectStart/PQconnectPoll) against mysql_init/mysql_real_connect functions. (debian platform/C application).
PQconnectdb("host=localhost dbname=my_db user=my_user password='' sslmode=disable");
co = mysql_init(NULL)
mysql_real_connect(co, "127.0.0.1", "my_user", "", "my_db", 0, NULL, 0)
PQconnectdb is taking too long comparing to mysql and i found out the time is consumed by PQconnectPoll waiting for the socket to be ready for reading/writing
but this behaviour is not seen in mysql.
I cannot use persistent connections. I must open/close a connection anytime I want to insert something new.
do i have to configure something different? Am i missing something?
this problem gets even worse under PHP.
Regards,
From | Date | Subject | |
---|---|---|---|
Next Message | Maria L. Wilson | 2012-11-15 15:03:10 | help on slow query using postgres 8.4 |
Previous Message | Peter Geoghegan | 2012-11-15 02:03:24 | Re: SOLVED - RE: Poor performance using CTE |