From: | Erik Hofman <erik(at)ehofman(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | non blocking mode bug? |
Date: | 2001-02-15 11:10:46 |
Message-ID: | 3A8BB936.BB0CEB6@ehofman.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
I realy get into problems witht his one.
I've made an Irix nss library which connects to postgresql.
But somehow the backend doesn;t get into active status.
The blocking PQconnectdb halts until timeout (if i ignore the
errormessage, the results return right after the timeout has expired).
By using the non blocking function PQconnectStart() and using a callback
function and the select() mainloop of the nss daemon, the status of
PQconnectPoll() doesn't turn into PGRESS_POLLING_OK.
In the callback routine I check for PGRESS_POLLING_OK, but it never gets
active!
I put this little piece of code in the callback function for testing,
but the syslogs says this routine is called 6300 times before timeout.
It seems libpq is sending data to the socket as if it were ready, but it
doesn't get the PGRESS_POLLING_OK status!
nsd_callback_remove(PQsocket(pgc));
if (pgs != PGRES_POLLING_OK) {
nsd_callback_new(PQsocket(pgc), (void *)(ns_psql_ccb(file, pgc, s)),
NSD_READ);
return;
}
nsd_timeout_remove(file);
Does anybody have any idea about this problem?
I might be nss_daemon or even Irix reletaed, but i don't get a way to
check this out :(
Erik
From | Date | Subject | |
---|---|---|---|
Next Message | pejac | 2001-02-15 12:11:36 | Indexing new type ........ |
Previous Message | Trewern, Ben | 2001-02-15 09:58:44 | RE: Postgre SQL for Windows |