Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-04-01 Thread Mathias Hasselmann

Am Samstag, den 29.03.2008, 12:25 + schrieb [EMAIL PROTECTED]:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1
 
 On Sat, Feb 23, 2008 at 01:13:38PM +0100, Mathias Hasselmann wrote:
 
 [...]
 
  Avahi/Bonjour/DNS-SD support[1] is very important, for integrating
  Postgresql with modern desktop environments like OSX, GNOME, KDE: It's
  very convenient to choose active DBMS servers in your local network from
  a list, instead of memorizing cryptic connection parameters. 
 
 [...]
 
  People not wanting DNS-SD support for their server can easily control
  that feature via the --with-avahi configure scripts.
 
 Sorry for a dumb question, but I couldn't figure that out from your
 references [1]..[4]: does that mean that the PostgreSQL server would
 advertise itself on the local net? Or what is the purpose of liking-in
 libavahi into the postmaster?

Yes, that's the purpose.

 Surely one wouldn't want this in a data center? 

Yes, this feature definitely targets small-office use, personal use, DB
developers. Don't know enough about data centers to judge the impact
there, but since Avahi - as used in the patch - announces to the local
network only, the impact sould be small.

Still you can tell Avahi to explicitly announce at a certain, non-local
domain, but this feature is not implemented by the patch. Maybe database
developers in large network environments could make use of such
announcements. It would be trivial to add.

 Is there a possiblity to disable that at run time?

The feature is disabled by default. As long as you do not specify a
zeroconf_name in your configuration file, nothing happens. This is the
same behavior as established by the Bonjour code.

Ciao,
Mathias
-- 
Mathias Hasselmann [EMAIL PROTECTED]
http://www.openismus.com/ - We can get it done.


-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-04-01 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Tue, Apr 01, 2008 at 09:35:56AM +0200, Mathias Hasselmann wrote:
 Am Samstag, den 29.03.2008, 12:25 + schrieb [EMAIL PROTECTED]:
 [...]
  Sorry for a dumb question, but I couldn't figure that out from your
  references [1]..[4]: does that mean that the PostgreSQL server would
  advertise itself on the local net? Or what is the purpose of liking-in
  libavahi into the postmaster?
 
 Yes, that's the purpose.
 
  Surely one wouldn't want this in a data center? 
 
 Yes, this feature definitely targets small-office use, personal use, DB
 developers [...]
 Still you can tell Avahi to explicitly announce at a certain, non-local
 domain, but this feature is not implemented by the patch. Maybe database
 developers in large network environments could make use of such
 announcements. It would be trivial to add.

Personally, I'be rather scared than delighted ;-)

  Is there a possiblity to disable that at run time?
 
 The feature is disabled by default. As long as you do not specify a
 zeroconf_name in your configuration file, nothing happens. This is the
 same behavior as established by the Bonjour code.

Thanks, good to know.

Isn't there a less-intrusive option to linking a lib into each and every
possible server, like a config file in which to put what is to be announced?

Regards
- -- tomás
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFH8iRFBcgs9XrR2kYRAmJ0AJkB7MkxfYI0nVa4RqHVEV1HYjz41gCdEgWz
YQ2T4Y/xfoLRF4D6hMLbpEk=
=Goho
-END PGP SIGNATURE-

-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-04-01 Thread Mathias Hasselmann

Am Dienstag, den 01.04.2008, 12:02 + schrieb [EMAIL PROTECTED]:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1
 
 On Tue, Apr 01, 2008 at 09:35:56AM +0200, Mathias Hasselmann wrote:
  Am Samstag, den 29.03.2008, 12:25 + schrieb [EMAIL PROTECTED]:
  [...]
   Sorry for a dumb question, but I couldn't figure that out from your
   references [1]..[4]: does that mean that the PostgreSQL server would
   advertise itself on the local net? Or what is the purpose of liking-in
   libavahi into the postmaster?
  
  Yes, that's the purpose.
  
   Surely one wouldn't want this in a data center? 
  
  Yes, this feature definitely targets small-office use, personal use, DB
  developers [...]
  Still you can tell Avahi to explicitly announce at a certain, non-local
  domain, but this feature is not implemented by the patch. Maybe database
  developers in large network environments could make use of such
  announcements. It would be trivial to add.
 
 Personally, I'be rather scared than delighted ;-)

So in data centers you don't even trust the machines in your broadcast
domain?

   Is there a possiblity to disable that at run time?
  
  The feature is disabled by default. As long as you do not specify a
  zeroconf_name in your configuration file, nothing happens. This is the
  same behavior as established by the Bonjour code.
 
 Thanks, good to know.
 
 Isn't there a less-intrusive option to linking a lib into each and every
 possible server, like a config file in which to put what is to be announced?

You could directly talk to the D-Bus interface of Avahi. libavahi-client
just is a convenience wrapper. Well, but this route will be much more
cumbersome.

One other route is calling avahi-publish-service on startup and killing
it on shutdown, but: avahi-publish-service really only exists for
demonstration purposes and doesn't handle service name collisions for
instance. I don't believe that a high-profile application like
Postgresql should rely on low-quality hacks, like invoking educational
demo programs.

Ciao,
Mathias
-- 
Mathias Hasselmann [EMAIL PROTECTED]
http://www.openismus.com/ - We can get it done.


-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-04-01 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Tue, Apr 01, 2008 at 05:07:31PM +0200, Mathias Hasselmann wrote:
[...]
  Personally, I'be rather scared than delighted ;-)
 
 So in data centers you don't even trust the machines in your broadcast
 domain?

Kind of. Put it another way: never have services running you don't use.

[...]

  Isn't there a less-intrusive option to linking a lib into each and every
  possible server, like a config file in which to put what is to be announced?
 
 You could directly talk to the D-Bus interface of Avahi. libavahi-client
 just is a convenience wrapper. Well, but this route will be much more
 cumbersome.

So this goes through the D-Bus. Makes kind of sense. Thanks for the
enlightenment.

 One other route is calling avahi-publish-service on startup and killing
 it on shutdown, but: avahi-publish-service really only exists for
 demonstration purposes and doesn't handle service name collisions for
 instance. I don't believe that a high-profile application like
 Postgresql should rely on low-quality hacks, like invoking educational
 demo programs.

Unelegant as it might seem -- this solution still affords a lot more
when it comes to separation of concerns. I'm still a bit wary at the
prospect that each and every daemon evolves into a huge fuzzball
linked to all conceivable service-lets with a multitude of funny
side-effects (remember tcpwrappers?).

Of course, you can always disable this at compile time, but let's face
it: with the predominance of binary distribs, the path of least
resistance will be to put up with whatever strange side-effects.

I would really prefer a more loosely coupled system.

Regards
- -- tomás
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFH8lYJBcgs9XrR2kYRAmDJAJ4jWKYkhUfKEAIaZVnIbAAEqJF2AwCfS/6D
4rH9OoY7wjia7h1cuk5CjZI=
=AF1W
-END PGP SIGNATURE-

-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-04-01 Thread Murray Cumming
On Tue, 2008-04-01 at 15:34 +, [EMAIL PROTECTED] wrote:
 I would really prefer a more loosely coupled system.

The functionality will be much the same. The implementation would be
more difficult and obscure and there would be more points of failure and
more things to configure, but it wouldn't remove much risk, I think.

Anyway, this feature is already in Postgres when it's built for MacOS X.
So this decision seems to have been made already, at least for that
platform.

-- 
[EMAIL PROTECTED]
www.murrayc.com
www.openismus.com


-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-03-29 Thread tomas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Sat, Feb 23, 2008 at 01:13:38PM +0100, Mathias Hasselmann wrote:

[...]

 Avahi/Bonjour/DNS-SD support[1] is very important, for integrating
 Postgresql with modern desktop environments like OSX, GNOME, KDE: It's
 very convenient to choose active DBMS servers in your local network from
 a list, instead of memorizing cryptic connection parameters. 

[...]

 People not wanting DNS-SD support for their server can easily control
 that feature via the --with-avahi configure scripts.

Sorry for a dumb question, but I couldn't figure that out from your
references [1]..[4]: does that mean that the PostgreSQL server would
advertise itself on the local net? Or what is the purpose of liking-in
libavahi into the postmaster?

Surely one wouldn't want this in a data center? Is there a possiblity to
disable that at run time?

Thanks for any insights

- -- tomás
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFH7jUxBcgs9XrR2kYRAsfOAJ0Ulfydo3G1kzQo3HTOdjtswA1A2gCfYYyL
VHprJ63unId85/Iht4ha2RE=
=get0
-END PGP SIGNATURE-

-- 
Sent via pgsql-patches mailing list (pgsql-patches@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-patches


Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Alvaro Herrera
Mathias Hasselmann wrote:

 The patches were in my initial mail, but now I've also uploaded them to
 my personal site for convenience:
 
   http://taschenorakel.de/files/pgsql-avahi-support/

Hmm, a quick look at the third patch reveals that it is using the
threaded Avahi client.  That's a showstopper.  Please consider using
some other approach -- writing our own handlers for AvahiPoll would seem
apropos.

-- 
Alvaro Herrerahttp://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

---(end of broadcast)---
TIP 1: if posting/reading through Usenet, please send an appropriate
   subscribe-nomail command to [EMAIL PROTECTED] so that your
   message can get through to the mailing list cleanly