RE: Add client connection check during the execution of the query - Mailing list pgsql-hackers

From tsunakawa.takay@fujitsu.com
Subject RE: Add client connection check during the execution of the query
Date
Msg-id TYAPR01MB2990E5F57212DBFD41F61983FE7A9@TYAPR01MB2990.jpnprd01.prod.outlook.com
Whole thread Raw
In response to Re: Add client connection check during the execution of the query  (Thomas Munro <thomas.munro@gmail.com>)
Responses Re: Add client connection check during the execution of the query
List pgsql-hackers
From: Thomas Munro <thomas.munro@gmail.com>
> > Following PostmasterIsAlive(), maybe it's better to name it as
> pq_connection_is_alive() pq_client_is_alive(), or pq_frontend_is_alive() like
> the pqcomm.c's head comment uses the word frontend?
> 
> I think it's OK, because it matches the name of the GUC.  I'm more concerned
> about the name of the GUC.  Will we still be happy with this name if a future
> releases sends a heartbeat message?  I think that is still OK, so I'm happy with
> these names for now, but if someone has a better name, please speak up very
> soon.

OK, agreed.


> > (4)
> > I think the new GUC works for walsender as well.  If so, how do we explain
> the relationship between the new GUC and wal_receiver_timeout and
> recommend the settings of them?
> 
> No, it only works while executing a query.  (Is there something in logical
> decoding, perhaps, that I have failed to consider?)

When I saw the following code, I thought the new GUC takes effect at the same time as wal\sender_timeout.  But they
don'tbecome effective simultaneously.  The new GUC is effective before the logical replication starts.  And
wal_sender_timeouttakes effect after the physical/logical replication starts.  So, there's no problem.
 

[PostgresMain]
                    if (am_walsender)
                    {
                        if (!exec_replication_command(query_string))
                            exec_simple_query(query_string);
                    }
                    else
                        exec_simple_query(query_string);


The patch looks committable to me.


> PS The "from" headers in emails received from Fujitsu seems to have the
> names stripped, somewhere in the tubes of the internet.  I see the full version
> when people from Fujitsu quote other people from Fujitsu.
> I copied one of those into the commit message, complete with its magnificent
> kanji characters (perhaps these are the cause of the filtering?), and I hope
> that's OK with you.

Certainly, it seems that only my email address appears in the sender field on the mailer.  I'll check my Outlook
settings.


Regards
Takayuki Tsunakawa



pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Proposal: Save user's original authenticated identity for logging
Next
From:
Date:
Subject: Fix pg_checksums progress report