From: | Jan Wieck <jan(at)wi3ck(dot)info> |
---|---|
To: | Kuntal Ghosh <kuntalghosh(dot)2007(at)gmail(dot)com> |
Cc: | Dave Cramer <davecramer(at)postgres(dot)rocks>, Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Jonah H(dot) Harris" <jonah(dot)harris(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Extensibility of the PostgreSQL wire protocol |
Date: | 2021-02-22 15:01:41 |
Message-ID: | 3e36a065-655d-c5df-e8b3-ca3c10d19713@wi3ck.info |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2/19/21 4:36 AM, Kuntal Ghosh wrote:
> On Thu, Feb 18, 2021 at 9:32 PM Jan Wieck <jan(at)wi3ck(dot)info> wrote:
> Few comments in the extension code (although experimental):
>
> 1. In telnet_srv.c,
> + static int pe_port;
> ..
> + DefineCustomIntVariable("telnet_srv.port",
> + "Telnet server port.",
> + NULL,
> + &pe_port,
> + pe_port,
> + 1024,
> + 65536,
> + PGC_POSTMASTER,
> + 0,
> + NULL,
> + NULL,
> + NULL);
>
> The variable pe_port should be initialized to a value which is > 1024
> and < 65536. Otherwise, the following assert will fail,
> TRAP: FailedAssertion("newval >= conf->min", File: "guc.c", Line:
> 5541, PID: 12100)
>
> 2. The function pq_putbytes shouldn't be used by anyone other than
> old-style COPY out.
> + pq_putbytes(msg, strlen(msg));
> Otherwise, the following assert will fail in the same function:
> /* Should only be called by old-style COPY OUT */
> Assert(DoingCopyOut);
>
Attached are an updated patch and telnet_srv addressing the above problems.
Regards, Jan
--
Jan Wieck
Principle Database Engineer
Amazon Web Services
Attachment | Content-Type | Size |
---|---|---|
telnet_srv_2021-02-22_1.tgz | application/x-compressed-tar | 10.9 KB |
wire_proto_2021-02-22_1.diff.gz | application/gzip | 7.4 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2021-02-22 15:45:21 | Re: do coverage test without install lcov |
Previous Message | Jan Wieck | 2021-02-22 14:55:53 | Re: Extensibility of the PostgreSQL wire protocol |