Connect Failed error

From: "vijayendra mohan agrawal" <vijayendra(dot)agrawal(at)wipro(dot)com>
To: "PostGre SQL Mailing List" <pgsql-admin(at)postgresql(dot)org>
Subject: Connect Failed error
Date: 2001-01-09 11:43:39
Message-ID: 001b01c07a31$694b42a0$2a14a8c0@wipro.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hi all,

I have developed an application using PostGreSQL in the backend. The
application is to simulate some Network elements which should communicate
with some other application (Which is actually a Black Box for us). There is
always one instance of that application with each instance of Network
Element I simulate in my application.

That application will send different type of requests to my application, and
my application will respond to those requests by querying to the database.
The frequency of such requests are very high (maybe 4-5 requests per
second). Each request will be serviced in a "separate thread".

My interface to the database is executeQuery() and executeUpdate() type. The
connection object is local to the implementation of executeQuery() and
executeUpdate(). The connection object is made local to avoid
synchronization problems. (I am using C language). These methods are
connecting to database each time they are being called, and then after
finishing query, they close the database connection.

I am using PQsetdb() for connecting to the database and
PQfinish(DatabaseConnection db) to close database connection.

The application runs fine with as many as 50 instances of Network Elements
with a very high rate of message coming from 50 corresponding "Black Box
applications". But it will stop after some hours of continous run (max 16
hours). error :
"Connection to database failed"

I want the application to run forever. Please tell me what to do.

Platform : HP-UX 11.0
Language : C, Motif X-Windows Programming
Database : PostGreSQL 7.0.2

Thanks,
Vijay

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Peter Eisentraut 2001-01-09 17:50:39 Re: Granting Permissions to User To Access Database
Previous Message Anthony E . Greene 2001-01-08 23:20:33 Re: GRANT & DROP