Re: ps command does not show walsender's connected db

2022-11-23 Thread Michael Paquier
On Tue, Nov 22, 2022 at 08:46:22AM +0530, Bharath Rupireddy wrote: > Are you looking at the latest v3 patch > https://www.postgresql.org/message-id/4b5691462b994c18ff370aaa84cef0d0%40oss.nttdata.com? > It has no printf() calls. Yes, I was looking at v1. v3 can be simpler. All this information

Re: ps command does not show walsender's connected db

2022-11-21 Thread Bharath Rupireddy
On Tue, Nov 22, 2022 at 6:14 AM Michael Paquier wrote: > > On Thu, Nov 17, 2022 at 01:32:11PM +0900, Ian Lawrence Barwick wrote: > > Fujii-san is marked as committer on the commifest entry for this patch [1]; > > are you able to go ahead and get it committed? > > That's the state of the patch

Re: ps command does not show walsender's connected db

2022-11-21 Thread Michael Paquier
On Thu, Nov 17, 2022 at 01:32:11PM +0900, Ian Lawrence Barwick wrote: > Fujii-san is marked as committer on the commifest entry for this patch [1]; > are you able to go ahead and get it committed? That's the state of the patch since the 11th of October. Seeing the lack of activity, I propose to

Re: ps command does not show walsender's connected db

2022-11-16 Thread Ian Lawrence Barwick
2022年10月11日(火) 20:06 Bharath Rupireddy : > > On Tue, Oct 11, 2022 at 2:11 PM bt22nakamorit > wrote: > > > > 2022-10-10 16:12 Bharath Rupireddy wrote: > > > Thanks. LGTM. > > Thank you for your review! > > I have this issue posted on Commitfest 2022-11 with title "show > > walsender's connected db

Re: ps command does not show walsender's connected db

2022-10-11 Thread Bharath Rupireddy
On Tue, Oct 11, 2022 at 2:11 PM bt22nakamorit wrote: > > 2022-10-10 16:12 Bharath Rupireddy wrote: > > Thanks. LGTM. > Thank you for your review! > I have this issue posted on Commitfest 2022-11 with title "show > walsender's connected db for ps command entry". > May I change the status to "Ready

Re: ps command does not show walsender's connected db

2022-10-11 Thread bt22nakamorit
2022-10-10 16:12 Bharath Rupireddy wrote: Thanks. LGTM. Thank you for your review! I have this issue posted on Commitfest 2022-11 with title "show walsender's connected db for ps command entry". May I change the status to "Ready for Committer"? Best, Tatsuhiro Nakamori

Re: ps command does not show walsender's connected db

2022-10-10 Thread Bharath Rupireddy
On Mon, Oct 10, 2022 at 12:20 PM bt22nakamorit wrote: > > 2022-10-10 12:27 Bharath Rupireddy wrote: > > if (port->database_name != NULL && port->database_name[0] != '\0') > > appendStringInfo(_data, "%s ", port->database_name); > > > > The above works better. > > Thank you for the suggestion.

Re: ps command does not show walsender's connected db

2022-10-10 Thread bt22nakamorit
2022-10-10 12:27 Bharath Rupireddy wrote: if (port->database_name != NULL && port->database_name[0] != '\0') appendStringInfo(_data, "%s ", port->database_name); The above works better. Thank you for the suggestion. I have edited the patch to reflect your idea. Best, Tatsuhiro

Re: ps command does not show walsender's connected db

2022-10-09 Thread Bharath Rupireddy
On Mon, Oct 10, 2022 at 8:00 AM bt22nakamorit wrote: > > appendStringInfo will append extra space after null (since "%s "), so > the ps entry will look less neat in that case. > How about we check whether port->database_name is null or not, instead > of making it unconditional? > It will look

Re: ps command does not show walsender's connected db

2022-10-09 Thread bt22nakamorit
2022-10-09 18:30 Bharath Rupireddy wrote: -if (!am_walsender) +if (!am_walsender || am_db_walsender) appendStringInfo(_data, "%s ", port->database_name); Can the appendStringInfo be just unconditional? That is more readable IMO. We want the database_name to be appended whenever

Re: ps command does not show walsender's connected db

2022-10-09 Thread Bharath Rupireddy
On Fri, Oct 7, 2022 at 7:25 PM Fujii Masao wrote: > > Thanks for updating the patch! LGTM. -if (!am_walsender) +if (!am_walsender || am_db_walsender) appendStringInfo(_data, "%s ", port->database_name); Can the appendStringInfo be just unconditional? That is more readable IMO.

Re: ps command does not show walsender's connected db

2022-10-07 Thread Fujii Masao
On 2022/10/07 18:43, bt22nakamorit wrote: 2022-10-07 16:59  Fujii Masao wrote: s/subscriber/publisher ? I did not understand what this means. Sorry for confusing wording... I was just trying to say that walsender is connected to a database of the publisher instead of subscriber.

Re: ps command does not show walsender's connected db

2022-10-07 Thread bt22nakamorit
2022-10-07 16:59 Fujii Masao wrote: s/subscriber/publisher ? I did not understand what this means. Thanks for the patch! - + printf("fork child process\n"); + printf(" am_walsender: %d\n", am_walsender); + printf(" am_db_walsender: %d\n",

Re: ps command does not show walsender's connected db

2022-10-07 Thread Fujii Masao
On 2022/10/06 22:30, bt22nakamorit wrote: Hi, When walsender process is evoked for logical replication, walsender is connected to a database of the subscriber. Naturally, ones would want the name of the connected database to show in the entry of ps command for walsender. In detail, running

ps command does not show walsender's connected db

2022-10-06 Thread bt22nakamorit
Hi, When walsender process is evoked for logical replication, walsender is connected to a database of the subscriber. Naturally, ones would want the name of the connected database to show in the entry of ps command for walsender. In detail, running ps aux during the logical replication shows