Re: Notes on implementing URI syntax for libpq

From: Alexander Shulgin <ash(at)commandprompt(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Notes on implementing URI syntax for libpq
Date: 2011-11-24 13:50:47
Message-ID: 1322142391-sup-2339@moon
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Excerpts from Robert Haas's message of Thu Nov 24 15:35:36 +0200 2011:
>
> > Do you suggest that we should reconsider?
>
> I guess my feeling is that if we're going to have URLs, we ought to
> try to adhere to the same conventions that are used for pretty much
> every other service that supports URLs. user:pw(at)host:port is widely
> supported by multiple protocols, so I think we would need a very good
> reason to decide to go off in a completely different direction. It
> would be nice to be compatible with whatever JDBC does (link?) but I'm
> not prepared to put that ahead of general good design.

What JDBC supports is rather weird and far from being ideal: http://jdbc.postgresql.org/documentation/head/connect.html

The problem with supporting multiple syntaxes, IMO is that it makes libpq compatible in only one direction: from particular foreign syntax to libpq, but not from libqp to any other particular foreign syntax. So when you see psql -d <URL> you wouldn't know if you can copy that URL to JDBC or any other connection interface parameter, unless you check the docs thoroughly.

--
Alex

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2011-11-24 13:52:03 Re: Notes on implementing URI syntax for libpq
Previous Message Robert Haas 2011-11-24 13:48:39 Re: Time bug with small years