| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> | 
|---|---|
| To: | Michael Paquier <michael(at)paquier(dot)xyz> | 
| Cc: | Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp>, pavel(dot)stehule(at)gmail(dot)com, a(dot)zakirov(at)postgrespro(dot)ru, pgsql-hackers(at)postgresql(dot)org | 
| Subject: | Re: pg_get_functiondef forgets about most GUC_LIST_INPUT GUCs | 
| Date: | 2018-03-21 05:40:23 | 
| Message-ID: | 22579.1521610823@sss.pgh.pa.us | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
Michael Paquier <michael(at)paquier(dot)xyz> writes:
> On Tue, Mar 20, 2018 at 01:27:35PM -0400, Tom Lane wrote:
>> +       if (flags & GUC_LIST_QUOTE)
>> +               elog(FATAL, "extensions cannot define GUC_LIST_QUOTE variables");
> This would be better as an ereport with ERRCODE_FEATURE_NOT_SUPPORTED I
> think.  An ERROR is better in my opinion.
I don't mind making it an ereport, but I think it needs to be FATAL
for the reason stated in the comment.
>> +   record = find_option(name, false, WARNING);
>> +   if (record == NULL)
> LOG instead of WARNING?
I did it like that to match the similar code in flatten_set_variable_args.
In the end it doesn't matter, because find_option only uses its elevel
argument when create_placeholders is passed as true.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Rady, Doug | 2018-03-21 05:42:33 | Re: PATCH: pgbench - option to build using ppoll() for larger connection counts | 
| Previous Message | Pavel Stehule | 2018-03-21 05:24:16 | Re: [HACKERS] proposal: schema variables |