From: | Andres Freund <andres(at)2ndquadrant(dot)com> |
---|---|
To: | Steve Singer <steve(at)ssinger(dot)info> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: changeset generation v5-01 - Patches & git tree |
Date: | 2013-07-05 16:04:00 |
Message-ID: | 20130705160400.GA20369@alap2.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2013-07-05 11:33:20 -0400, Steve Singer wrote:
> On 06/14/2013 06:51 PM, Andres Freund wrote:
> >The git tree is at:
> >git://git.postgresql.org/git/users/andresfreund/postgres.git branch xlog-decoding-rebasing-cf4
> >http://git.postgresql.org/gitweb/?p=users/andresfreund/postgres.git;a=shortlog;h=refs/heads/xlog-decoding-rebasing-cf4
>
>
> We discussed issues related to passing options to the plugins a number of
> months ago ( http://www.postgresql.org/message-id/20130129015732.GA24238@awork2.anarazel.de)
>
> I'm still having issues with the syntax you describe there.
>
>
> START_LOGICAL_REPLICATION "1" 0/0 ("foo","bar")
> unexpected termination of replication stream: ERROR: foo requires a
> parameter
I'd guess that's coming from your output plugin? You're using
defGetString() on DefElem without a value?
> START_LOGICAL_REPLICATION "1" 0/0 ("foo" "bar")
Yes, the option *names* are identifiers, together with plugin & slot
names. The passed values need to be SCONSTs atm
(src/backend/replication/repl_gram.y):
plugin_opt_elem:
IDENT plugin_opt_arg
{
$$ = makeDefElem($1, $2);
}
;
plugin_opt_arg:
SCONST { $$ = (Node *) makeString($1); }
| /* EMPTY */ { $$ = NULL; }
;
So, it would have to be:
START_LOGICAL_REPLICATION "1" 0/0 ("foo" 'bar blub frob', "sup" 'star', "noarg")
Now that's not completely obvious, I admit :/. Better suggestions?
Greetings,
Andres Freund
--
Andres Freund http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2013-07-05 16:08:18 | Re: [PATCH] Add transforms feature |
Previous Message | Bruce Momjian | 2013-07-05 15:48:01 | Re: strange IS NULL behaviour |