From: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
---|---|
To: | Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com> |
Cc: | Peter Eisentraut <peter_e(at)gmx(dot)net>, Greg Stark <stark(at)mit(dot)edu>, Abhijit Menon-Sen <ams(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Providing catalog view to pg_hba.conf file - Patch submission |
Date: | 2015-04-04 05:19:15 |
Message-ID: | CAFj8pRARzDScocMK30gyYdOgiwuTUcZ7EvE-bBg+wV2Wg5EQRQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi
2015-03-31 14:38 GMT+02:00 Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com>:
> On Mon, Mar 30, 2015 at 4:34 AM, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
> wrote:
> > Hi
> >
> > I checked this patch. I like the functionality and behave.
>
> Thanks for the review.
>
> Here I attached updated patch with the following changes.
>
> 1. Addition of two new keyword columns
> keyword_databases - The database name can be "all", "replication",
> sameuser", "samerole" and "samegroup".
> keyword_roles - The role can be "all" and a group name prefixed with "+".
>
I am not very happy about name - but I have no better idea :( - maybe
"database_mask", "user_mask"
>
> The rest of the database and role names are treated as normal database
> and role names.
>
> 2. Added the code changes to identify the names with quoted.
>
Is it a good idea? Database's names are not quoted every else (in system
catalog). So now, we cannot to use join to this view.
postgres=# select (databases)[1] from pg_hba_conf ;
databases
-----------
"omega 2"
(4 rows)
postgres=# select datname from pg_database ;
datname
-----------
template1
template0
postgres
omega 2
(4 rows)
I dislike this - we know, so the name must be quoted in file (without it,
the file was incorrect). And if you need quotes, there is a function
quote_ident. If we use quotes elsewhere, then it should be ok, bot not now.
Please, remove it. More, it is not necessary, when you use a "keyword"
columns.
Regards
Pavel
>
> 3. Updated documentation changes
>
> 4. Regression test is corrected.
>
>
> Regards,
> Hari Babu
> Fujitsu Australia
>
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Gierth | 2015-04-04 06:11:00 | Re: Abbreviated keys for Numeric |
Previous Message | Tom Lane | 2015-04-04 03:29:11 | Re: Abbreviated keys for Numeric |