RE: [INTERFACES] postmaster & JDBC
От | Peter Mount |
---|---|
Тема | RE: [INTERFACES] postmaster & JDBC |
Дата | |
Msg-id | 1B3D5E532D18D311861A00600865478CA057@exchange1.nt.maidstone.gov.uk обсуждение исходный текст |
Список | pgsql-interfaces |
[Correct me if I'm wrong here :-)] The postmaster here is the main process. When any client (not just JDBC) connects, it creates a new process, and that new process is what talks to the client. There is only one postmaster. The separate directory and port number is where in some rare cases, some of us mad ones have different versions of the back end running on the same machine (a production database and a development one). The rule here is, unless you really need to do this, don't - it can be horrendous. I'm actually thinking of setting up a new machine to handle the development side of things. As for having multiple connections, take a look at the source to the JAVA/CORBA example (src/interfaces/jdbc/example/corba), as there is a simple ConnectionManager class there that does exactly what you are doing. Peter -- Peter Mount Enterprise Support Maidstone Borough Council Any views stated are my own, and not those of Maidstone Borough Council. -----Original Message----- From: Mike Engelhart [mailto:aengelhart@austin.rr.com] Sent: 07 July 1999 01:49 To: pgsql-interfaces@postgreSQL.org Subject: [INTERFACES] postmaster & JDBC Hi - I'm a little confused at how the JDBC driver and the postmaster get along. I have a servlet system built that uses connection pooling to create a number of Connection objects to a PostgreSQL (6.5) database. I start out by creating 5 connections and up that by 3 new ones if it runs out of connections (which hasn't been an issue yet). Anyway, I just read the man page for postmaster this evening and noticed this comment: ***** Only one postmaster should be running at a time in a given Postgres installation." Here, an installation means a database directory and postmaster port number. You can run more than one postmaster on a machine only if each one has a separate directory and port number. ******* As I haven't been doing either of the aforementioned things (separate directory and port number for each postmaster), is the JDBC driver doing this for me? It seems that they must be all running on the same port because I'm calling a DriverManager.getConnection() with the same URL. Thanks for any explanation into how this works. Mike
В списке pgsql-interfaces по дате отправления: