Add description about GSSOpenServer wait event into document.
authorFujii Masao <fujii@postgresql.org>
Mon, 17 Feb 2020 07:16:08 +0000 (16:16 +0900)
committerFujii Masao <fujii@postgresql.org>
Mon, 17 Feb 2020 07:16:08 +0000 (16:16 +0900)
This commit also updates wait event enum into alphabetical order.
Previously the enum entry for GSSOpenServer was added out-of-order.

Back-patch to v12 where commit b0b39f72b9 introduced
GSSOpenServer wait event. In v12, the commit doesn't include
the update of wait event enum, not to break ABI.

Author: Fujii Masao
Reviewed-by: Michael Paquier
Discussion: https://postgr.es/m/949931aa-4ed4-d867-a7b5-de9c02b2292b@oss.nttdata.com

doc/src/sgml/monitoring.sgml
src/backend/postmaster/pgstat.c
src/include/pgstat.h

index 0e5a4a0b86abbef44a1361285842eadd70204792..a9f6ee6e32aa4a99049be2196c1174e438f9b0a2 100644 (file)
@@ -1293,7 +1293,7 @@ postgres   27093  0.0  0.0  30096  2752 ?        Ss   11:34   0:00 postgres: ser
          <entry>Waiting in main loop of WAL writer process.</entry>
         </row>
         <row>
-         <entry morerows="7"><literal>Client</literal></entry>
+         <entry morerows="8"><literal>Client</literal></entry>
          <entry><literal>ClientRead</literal></entry>
          <entry>Waiting to read data from the client.</entry>
         </row>
@@ -1301,6 +1301,10 @@ postgres   27093  0.0  0.0  30096  2752 ?        Ss   11:34   0:00 postgres: ser
          <entry><literal>ClientWrite</literal></entry>
          <entry>Waiting to write data to the client.</entry>
         </row>
+        <row>
+         <entry><literal>GSSOpenServer</literal></entry>
+         <entry>Waiting to read data from the client while establishing the GSSAPI session.</entry>
+        </row>
         <row>
          <entry><literal>LibPQWalReceiverConnect</literal></entry>
          <entry>Waiting in WAL receiver to establish connection to remote server.</entry>
index 7169509a797d0b6814ee7336021cf7789c030b62..59dc4f31abdb0695e8ff2c194fc0cbb1bc8588f9 100644 (file)
@@ -3697,6 +3697,9 @@ pgstat_get_wait_client(WaitEventClient w)
        case WAIT_EVENT_CLIENT_WRITE:
            event_name = "ClientWrite";
            break;
+       case WAIT_EVENT_GSS_OPEN_SERVER:
+           event_name = "GSSOpenServer";
+           break;
        case WAIT_EVENT_LIBPQWALRECEIVER_CONNECT:
            event_name = "LibPQWalReceiverConnect";
            break;
@@ -3715,9 +3718,6 @@ pgstat_get_wait_client(WaitEventClient w)
        case WAIT_EVENT_WAL_SENDER_WRITE_DATA:
            event_name = "WalSenderWriteData";
            break;
-       case WAIT_EVENT_GSS_OPEN_SERVER:
-           event_name = "GSSOpenServer";
-           break;
            /* no default case, so that compiler will warn */
    }
 
index aecb6013f00d2287447d3cb3673f29efa79a3f7c..3a65a5169626a33444638e3b0ed63d42def178ff 100644 (file)
@@ -799,13 +799,13 @@ typedef enum
 {
    WAIT_EVENT_CLIENT_READ = PG_WAIT_CLIENT,
    WAIT_EVENT_CLIENT_WRITE,
+   WAIT_EVENT_GSS_OPEN_SERVER,
    WAIT_EVENT_LIBPQWALRECEIVER_CONNECT,
    WAIT_EVENT_LIBPQWALRECEIVER_RECEIVE,
    WAIT_EVENT_SSL_OPEN_SERVER,
    WAIT_EVENT_WAL_RECEIVER_WAIT_START,
    WAIT_EVENT_WAL_SENDER_WAIT_WAL,
    WAIT_EVENT_WAL_SENDER_WRITE_DATA,
-   WAIT_EVENT_GSS_OPEN_SERVER,
 } WaitEventClient;
 
 /* ----------