Skip site navigation (1) Skip section navigation (2)

Possible bug in ECPGlib thread-safety (Postgres 7.4)...

From: "Demetres Pantermalis" <dpant(at)intracom(dot)gr>
To: <pgsql-interfaces(at)postgresql(dot)org>
Subject: Possible bug in ECPGlib thread-safety (Postgres 7.4)...
Date: 2003-12-04 11:43:24
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-interfaces
Dear All,

trying to run some tests for the thread-safety of the ecpg library, I
modified the test_thread.pgc to be like the one attached (test_thread1.pgc).

The changes are as follows:
1) All the connections used for insertions, begin in main function (and not
inside each thread)
2) The statement "EXEC SQL SET CONNECTION <conn> followed by the inserts is
used, instead of the"EXEC SQL AT <conn> ..." statement.
3) A new line for ECPGlog was added.

The results of executing the code are unexpected. Either a core dump
results, or one of the two threads inserts the rows in the table and the
process never returns to OS prompt, while the other thread seems to insert
the rows, but never commits.

A log file produced by ECPGlog is also attached.

Platforms tested: SunOS 5.8 and Linux RH9 (with the same results)

Any suggestions appreciated.

PS. I've found out that somebody else had about the same problem, but that
was during testing phase and I assumed that it could have been solved by
now. The links found are:

Demetres Pantermalis
Intracom SA
Network Support Systems.

Attachment: thr_sfty.tar.gz
Description: application/x-gzip (1.3 KB)


pgsql-interfaces by date

Next:From: Philip YarraDate: 2003-12-04 12:08:12
Subject: Re: Possible bug in ECPGlib thread-safety (Postgres
Previous:From: D'Arcy J.M. CainDate: 2003-12-04 11:41:03
Subject: Re: 7.4 and Pygresql

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group