logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

pgpool_adm_pcp_health_check_stats - a function to display health check statistics data on given node ID

Arguments

node_id
           The index of backend node to get information of.

       pcp_server
           The foreign server name for pcp server.

       Otherarguments
           See pcp_common_options(1).

Description

pcp_health_check_stats displays health check statistics data on given node ID.

Example

       Here is an example output:

           test=# select * from pcp_health_check_stats(node_id => 0, host => '', port => 11001, username => 't-ishii', password => 't-ishii');
           -[ RECORD 1 ]-----------------+--------------------
           node_id                       | 0
           host                          | /tmp
           port                          | 11002
           status                        | up
           role                          | primary
           last_status_change            | 2020-02-25 16:05:29
           total_count                   | 3
           success_count                 | 3
           fail_count                    | 0
           skip_count                    | 0
           retry_count                   | 0
           average_retry_count           | 0
           max_retry_count               | 0
           max_health_check_duration     | 5
           min_health_check_duration     | 3
           average_health_check_duration | 4.333333
           last_health_check             | 2020-02-25 16:05:47
           last_successful_health_check  | 2020-02-25 16:05:47
           last_skip_health_check        |
           last_failed_health_check      |

       See Table 29, “Statistics data shown by pool_health_check_stats command” for details of data.

pgpool-II 4.6.1                                       2023                   PGPOOL_ADM_PCP_HEALTH_CHECK_STAT(3)

Name

       pgpool_adm_pcp_health_check_stats - a function to display health check statistics data on given node ID

Synopsis

pcp_health_check_statsreturnsrecord(integernode_id,texthost,integerport,textusername,textpassword,outnode_idinteger,outhosttext,outportinteger,outstatustext,outroletext,outlast_status_changetimestamp,outtotal_countbigint,outsuccess_countbigint,outfail_countbigint,outskip_countbigint,outretry_countbigint,outaverage_retry_countbigint,outmax_retry_countbigint,outmax_health_check_durationbigint,outmin_health_check_durationbigint,outaverage_health_check_durationfloat4,outlast_health_checktimestamp,outlast_successful_health_checktimestamp,outlast_skip_health_checktimestamp,outlast_failed_health_checktimestamp);pcp_health_check_statsreturnsrecord(integernode_id,textpcp_server,outnode_idinteger,outhosttext,outportinteger,outstatustext,outroletext,outlast_status_changetimestamp,outtotal_countbigint,outsuccess_countbigint,outfail_countbigint,outskip_countbigint,outretry_countbigint,outaverage_retry_countbigint,outmax_retry_countbigint,outmax_health_check_durationbigint,outmin_health_check_durationbigint,outaverage_health_check_durationfloat4,outlast_health_checktimestamp,outlast_successful_health_checktimestamp,outlast_skip_health_checktimestamp,outlast_failed_health_checktimestamp);

See Also