Thread

Commits

  1. Remove all references to "xlog" from SQL-callable functions in pg_proc.

  2. Replace pg_shadow and pg_group by new role-capable catalogs pg_authid

  1. [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2016-12-13T17:47:55Z

    Based on discussion in
    https://www.postgresql.org/message-id/CAE1wr-w%3DLE1cK5uG_rmAh-VBxc4_Bnw-gAE3qSqL-%3DtWwvLvjQ%40mail.gmail.com
    .
    
    Tested via regression tests.
    To be applied in master only and to be included in 10.0.
    
    
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  2. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2016-12-14T16:07:20Z

    On 12/13/16 12:47 PM, Vladimir Rusinov wrote:
    > Based on discussion in
    > https://www.postgresql.org/message-id/CAE1wr-w%3DLE1cK5uG_rmAh-VBxc4_Bnw-gAE3qSqL-%3DtWwvLvjQ%40mail.gmail.com.
    >     
    > Tested via regression tests.
    > To be applied in master only and to be included in 10.0.
    
    I don't think the idea was to rename just one "xlog" function to "wal".
    
    Personally, I think this is not important, but if you want to do it, I'd
    follow the suggestion in the thread to rename all functions and leave
    the old names as aliases or wrappers of some kind.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  3. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2016-12-14T16:20:00Z

    On Wed, Dec 14, 2016 at 4:07 PM, Peter Eisentraut <
    peter.eisentraut@2ndquadrant.com> wrote:
    
    > On 12/13/16 12:47 PM, Vladimir Rusinov wrote:
    > > Based on discussion in
    > > https://www.postgresql.org/message-id/CAE1wr-w%
    > 3DLE1cK5uG_rmAh-VBxc4_Bnw-gAE3qSqL-%3DtWwvLvjQ%40mail.gmail.com.
    > >
    > > Tested via regression tests.
    > > To be applied in master only and to be included in 10.0.
    >
    > I don't think the idea was to rename just one "xlog" function to "wal".
    >
    
    Others will follow later in separate patches. Or is it preferred to have
    one huge patch submitted?
    
    Personally, I think this is not important, but if you want to do it, I'd
    > follow the suggestion in the thread to rename all functions and leave
    > the old names as aliases or wrappers of some kind.
    >
    
    I think I agree with Michael Paquier: "Better to do breakages in a single
    release rather than spreading them across releases.".
    There's going to be a lot of broken scripts following pg_xlog rename, so I
    think it makes sense to just drop functions as well. We don't maintain
    pg_xlog -> pg_wal symlink, do we?
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  4. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2016-12-14T23:51:31Z

    On Thu, Dec 15, 2016 at 1:20 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >
    > On Wed, Dec 14, 2016 at 4:07 PM, Peter Eisentraut
    > <peter.eisentraut@2ndquadrant.com> wrote:
    > Others will follow later in separate patches. Or is it preferred to have one
    > huge patch submitted?
    
    Please yes. One change makes little sense.
    
    >> Personally, I think this is not important, but if you want to do it, I'd
    >> follow the suggestion in the thread to rename all functions and leave
    >> the old names as aliases or wrappers of some kind.
    >
    > I think I agree with Michael Paquier: "Better to do breakages in a single
    > release rather than spreading them across releases.".
    > There's going to be a lot of broken scripts following pg_xlog rename, so I
    > think it makes sense to just drop functions as well.
    
    For consistency that makes sense in my view. But I won't be too noisy
    as well if people think that we should keep aliases for compatibility.
    
    > We don't maintain pg_xlog -> pg_wal symlink, do we?
    
    This part would be a mess for base backups, that's why we didn't do
    it. Symlinks are equivalent to empty directories in the pg_basebackup
    world. So by having one you would very likely break your backup *and*
    restore tools silently.
    -- 
    Michael
    
    
    
  5. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2016-12-15T11:23:26Z

    On Wed, Dec 14, 2016 at 11:51 PM, Michael Paquier <michael.paquier@gmail.com
    > wrote:
    
    > > On Wed, Dec 14, 2016 at 4:07 PM, Peter Eisentraut
    > > <peter.eisentraut@2ndquadrant.com> wrote:
    > > Others will follow later in separate patches. Or is it preferred to have
    > one
    > > huge patch submitted?
    >
    > Please yes. One change makes little sense.
    
    
    Ack. I was not sure what patch size is preferred here. Will continue with a
    patch in original thread later.
    
    Thanks for feedback!
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  6. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2016-12-27T03:15:44Z

    On Thu, Dec 15, 2016 at 8:51 AM, Michael Paquier
    <michael.paquier@gmail.com> wrote:
    > On Thu, Dec 15, 2016 at 1:20 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >>> Personally, I think this is not important, but if you want to do it, I'd
    >>> follow the suggestion in the thread to rename all functions and leave
    >>> the old names as aliases or wrappers of some kind.
    >>
    >> I think I agree with Michael Paquier: "Better to do breakages in a single
    >> release rather than spreading them across releases.".
    >> There's going to be a lot of broken scripts following pg_xlog rename, so I
    >> think it makes sense to just drop functions as well.
    >
    > For consistency that makes sense in my view. But I won't be too noisy
    > as well if people think that we should keep aliases for compatibility.
    
    Actually, I am changing my mind on this bit, following Peter's
    opinion. Maintaining aliases of the past functions is a no-brainer,
    and it has no cost in terms of maintenance. That will save much pain
    to many monitoring scripts as well.
    -- 
    Michael
    
    
    
  7. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Cynthia Shang <cynthia.shang@crunchydata.com> — 2016-12-29T16:43:34Z

    1) I agree with Michael that we should make this change backward compatible. It would help PostgreSQL image if we did not break everyone's code. It costs businesses money to rewrite code (e.g. middle tier software, backup tools, etc), test and redeploy to their customers. 
    
    2) We decided to rename the pg_xlog directory because people were deleting it when disks were getting full thinking it was just unimportant logging data; I get that. I'm a little unclear why we need to change the functions - it would be less painful to our users and less risky if we just left them as is. Could someone please elaborate why this change is necessary? I'm just trying to understand that.
    
    Thanks,
    -Cynthia
    
  8. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2016-12-29T17:07:34Z

    Cynthia,
    
    * Cynthia Shang (cynthia.shang@crunchydata.com) wrote:
    > 1) I agree with Michael that we should make this change backward compatible. It would help PostgreSQL image if we did not break everyone's code. It costs businesses money to rewrite code (e.g. middle tier software, backup tools, etc), test and redeploy to their customers. 
    
    While I agree that we don't want to break client code or to make
    backwards incompatible changes without good cause, in this case, it's
    definitely a good cause and it makes sense to have things be consistent
    and that includes changing these functions.
    
    We make backwards-incompatible changes with each major release, which is
    part of why we support older versions of PG for as long as we do- to
    give PG users time to make any necessary changes for the new version of
    PG.  One could argue that we shouldn't ever make a backwards
    incompatible change because it will break an existing user's code and
    cost users time and effort to rewrite that code, but the flip side of
    that is that the extra code and complexity results in its own
    maintenance burdens for the code and the project moving forward.
    
    Generally speaking, we've also found that backwards compatibility
    'features' end up having a much longer life than they should.
    Ultimately, the best way forward tends to be either make the backwards
    incompatible change or don't make the change at all.  We've already
    agreed on this particular change, and with good reason, so the way
    forward is to make the rest of the changes, not to go half-way or to try
    and provide some backwards compatibility complexity.
    
    > 2) We decided to rename the pg_xlog directory because people were deleting it when disks were getting full thinking it was just unimportant logging data; I get that. I'm a little unclear why we need to change the functions - it would be less painful to our users and less risky if we just left them as is. Could someone please elaborate why this change is necessary? I'm just trying to understand that.
    
    It would be inconsistent to change the directory name without also
    changing the documentation, functions, and other user-facing pieces.
    
    Thanks!
    
    Stephen
    
  9. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Cynthia Shang <cynthia.shang@crunchydata.com> — 2016-12-29T17:48:56Z

    I have never heard of coding standards where naming conventions required a function/variable name match a directory or file name. It seems that would be restrictive. 
    
    I'm not trying to pick a fight, I just think the pros should outweigh the cons when choosing a path forward. In this case I see lots of cons and one partial pro; partial because renaming only user facing functions and documentation will create inconsistency within the Postgres code for all of the following. It sounds as if your minds are already made up, which saddens me but I will say nothing further on the matter.
    
    
    xlog <https://doxygen.postgresql.org/structlogstreamer__param.html#aa537f3fc7164183c962c58ded88e89f0> - logstreamer_param
    xlog.c <https://doxygen.postgresql.org/xlog_8c.html>
    xlog.h <https://doxygen.postgresql.org/xlog_8h.html>
    XLOG_BACKUP_END <https://doxygen.postgresql.org/pg__control_8h.html#ad9d92339bbf37810f7dfae4b3dbdf2c3> - pg_control.h
    XLOG_BACKUP_LABEL <https://doxygen.postgresql.org/pg__standby_8c.html#a9e28a4fd60add05fb281b523dde816d9> - pg_standby.c
    xlog_blcksz <https://doxygen.postgresql.org/structControlFileData.html#ae41f5131a8b8add3a9a8896027dcd7eb> - ControlFileData
    XLOG_BLCKSZ_K <https://doxygen.postgresql.org/pg__test__fsync_8c.html#afc05fa8d4ff04e3820d70e13e7a8c9f3> - pg_test_fsync.c
    XLOG_BRIN_CREATE_INDEX <https://doxygen.postgresql.org/brin__xlog_8h.html#ab56748e29ec0e518dbe6aec2ad9174d2> - brin_xlog.h
    XLOG_BRIN_INIT_PAGE <https://doxygen.postgresql.org/brin__xlog_8h.html#ad4da725dab7941c79b95f306f93f0733> - brin_xlog.h
    XLOG_BRIN_INSERT <https://doxygen.postgresql.org/brin__xlog_8h.html#af325e689ce6b134004d634e5f4f5fc22> - brin_xlog.h
    XLOG_BRIN_OPMASK <https://doxygen.postgresql.org/brin__xlog_8h.html#abda79bb9dc455d307cbe04550b4a75a0> - brin_xlog.h
    XLOG_BRIN_REVMAP_EXTEND <https://doxygen.postgresql.org/brin__xlog_8h.html#a3ee32c12f868b6645d522a3cd8697a29> - brin_xlog.h
    XLOG_BRIN_REVMAP_VACUUM <https://doxygen.postgresql.org/brin__xlog_8h.html#aebb67fc99f73c1fd6a3408683cd4165a> - brin_xlog.h
    XLOG_BRIN_SAMEPAGE_UPDATE <https://doxygen.postgresql.org/brin__xlog_8h.html#a6e8d0c699dbecfa2d1be99b9c68ed529> - brin_xlog.h
    XLOG_BRIN_UPDATE <https://doxygen.postgresql.org/brin__xlog_8h.html#adacb7563b0c0d602cdcb22a853834009> - brin_xlog.h
    XLOG_BTREE_DELETE <https://doxygen.postgresql.org/nbtree_8h.html#af36ce520ea71dc51d72ee11c637bad71> - nbtree.h
    XLOG_BTREE_INSERT_LEAF <https://doxygen.postgresql.org/nbtree_8h.html#a855451db931e66a5536c04967332c353> - nbtree.h
    XLOG_BTREE_INSERT_META <https://doxygen.postgresql.org/nbtree_8h.html#ac7c6b3a582fd3d4cd57744f70829d017> - nbtree.h
    XLOG_BTREE_INSERT_UPPER <https://doxygen.postgresql.org/nbtree_8h.html#a902a50eeae554560fdfc83947ede0798> - nbtree.h
    XLOG_BTREE_MARK_PAGE_HALFDEAD <https://doxygen.postgresql.org/nbtree_8h.html#acb2d5fad8d393b45d5baed66eb963cac> - nbtree.h
    XLOG_BTREE_NEWROOT <https://doxygen.postgresql.org/nbtree_8h.html#aeb46a6c11b567f31166bc637871b8940> - nbtree.h
    XLOG_BTREE_REUSE_PAGE <https://doxygen.postgresql.org/nbtree_8h.html#adb8efa2ad4e95da9e9a30fa3ba86d66a> - nbtree.h
    XLOG_BTREE_SPLIT_L <https://doxygen.postgresql.org/nbtree_8h.html#ae01749da77b228c8bd873557877dbdbb> - nbtree.h
    XLOG_BTREE_SPLIT_L_ROOT <https://doxygen.postgresql.org/nbtree_8h.html#a3fc243b315c69170c44d58cfbf9cf1a9> - nbtree.h
    XLOG_BTREE_SPLIT_R <https://doxygen.postgresql.org/nbtree_8h.html#a619f011a3d4e02994f10a5c5eca1bbce> - nbtree.h
    XLOG_BTREE_SPLIT_R_ROOT <https://doxygen.postgresql.org/nbtree_8h.html#a509d120723af55b9004d2154a9788776> - nbtree.h
    XLOG_BTREE_UNLINK_PAGE <https://doxygen.postgresql.org/nbtree_8h.html#aa0f8ea18c61c3c2d1f492e700f63d128> - nbtree.h
    XLOG_BTREE_UNLINK_PAGE_META <https://doxygen.postgresql.org/nbtree_8h.html#aa1e90ef7a8ae497f6ba95d9b6544dfaa> - nbtree.h
    XLOG_BTREE_VACUUM <https://doxygen.postgresql.org/nbtree_8h.html#a470f820d137d81d227e7d6d9d53835a3> - nbtree.h
    XLOG_CHECKPOINT_ONLINE <https://doxygen.postgresql.org/pg__control_8h.html#afc093bf9e7639cfeda0a45ef48c9c77e> - pg_control.h
    XLOG_CHECKPOINT_SHUTDOWN <https://doxygen.postgresql.org/pg__control_8h.html#ab5870b9e3586602b5c0cfaad533c9c3c> - pg_control.h
    XLOG_CONTROL_FILE <https://doxygen.postgresql.org/xlog__internal_8h.html#a243af5b9b94bfc6356d44053a6f08e13>xlog_internal.h
    XLOG_DATA <https://doxygen.postgresql.org/pg__standby_8c.html#a37d04756edf3c23236e1182e9b41f7b8>pg_standby.c
    XLOG_DBASE_CREATE <https://doxygen.postgresql.org/dbcommands__xlog_8h.html#ab2eb2d181264280d88da0de6023a5b03> - dbcommands_xlog.h
    XLOG_DBASE_DROP <https://doxygen.postgresql.org/dbcommands__xlog_8h.html#a82159f86420a7d740047120d691e078c> - dbcommands_xlog.h
    xlog_desc <javascript:searchResults.Toggle(%22SR_xlog_5fdesc%22)>
    xlog_dir <javascript:searchResults.Toggle(%22SR_xlog_5fdir%22)>
    XLOG_END_OF_RECOVERY <https://doxygen.postgresql.org/pg__control_8h.html#afe9e6ee9f0b19be02e7d802fd7b0dd5d> - pg_control.h
    xlog_fn.h <https://doxygen.postgresql.org/xlog__fn_8h.html>
    XLOG_FNAME_LEN <https://doxygen.postgresql.org/xlog__internal_8h.html#a806888338de344e3fbb7c91a788149da> - xlog_internal.h
    XLOG_FPI <https://doxygen.postgresql.org/pg__control_8h.html#a77c5fe73e060f7759deb421a0b2c4af6> - pg_control.h
    XLOG_FPI_FOR_HINT <https://doxygen.postgresql.org/pg__control_8h.html#a7cc48ed8535d7c8321cd096d62bc84da> - pg_control.h
    XLOG_FPW_CHANGE <https://doxygen.postgresql.org/pg__control_8h.html#a21c819d8dad919204caf8198d6f29e8a> - pg_control.h
    XLOG_FROM_ANY <https://doxygen.postgresql.org/xlog_8c.html#aa4ae6b53287149eeb167868e4a55d714aea9ce17d7eded4324cc8f5416a0163da> - xlog.c
    XLOG_FROM_ARCHIVE <https://doxygen.postgresql.org/xlog_8c.html#aa4ae6b53287149eeb167868e4a55d714adffd65e4ec3f1091765ac4438e6beacd> - xlog.c
    XLOG_FROM_PG_WAL <https://doxygen.postgresql.org/xlog_8c.html#aa4ae6b53287149eeb167868e4a55d714a6953cfa8a50e9a0cca70e93713b673f2> - xlog.c
    XLOG_FROM_STREAM <https://doxygen.postgresql.org/xlog_8c.html#aa4ae6b53287149eeb167868e4a55d714abb692a2dd46cbbf9d2b4f346a8ef5ff9> - xlog.c
    XLOG_GIN_CREATE_INDEX <https://doxygen.postgresql.org/gin__private_8h.html#aaecaef66228a8f431493e643bcbc3cf8> - gin_private.h
    XLOG_GIN_CREATE_PTREE <https://doxygen.postgresql.org/gin__private_8h.html#aa0136e6761a3c5a3c5d33e4c135be255> - gin_private.h
    XLOG_GIN_DELETE_LISTPAGE <https://doxygen.postgresql.org/gin__private_8h.html#af5de469705afaa58f3991be80091c1e1> - gin_private.h
    XLOG_GIN_DELETE_PAGE <https://doxygen.postgresql.org/gin__private_8h.html#aaa85fe6ca88d3b567ebf8f58454b2602> - gin_private.h
    XLOG_GIN_INSERT <https://doxygen.postgresql.org/gin__private_8h.html#a847d779049f75dff8be5b1c99400505f> - gin_private.h
    XLOG_GIN_INSERT_LISTPAGE <https://doxygen.postgresql.org/gin__private_8h.html#ab697c4aab9b2da31177a87c5b46cca05> - gin_private.h
    XLOG_GIN_SPLIT <https://doxygen.postgresql.org/gin__private_8h.html#ae601d320a2ed9b4dd95bab6967e7dd24> - gin_private.h
    XLOG_GIN_UPDATE_META_PAGE <https://doxygen.postgresql.org/gin__private_8h.html#a19e96aa1f1af8c8917a7aea7f4238f0b> - gin_private.h
    XLOG_GIN_VACUUM_DATA_LEAF_PAGE <https://doxygen.postgresql.org/gin__private_8h.html#ac1638e8f4fc822004e1cb66fd37ba48f> - gin_private.h
    XLOG_GIN_VACUUM_PAGE <https://doxygen.postgresql.org/gin__private_8h.html#aa15459bf08d3806311e789b4e6de102c> - gin_private.h
    XLOG_GIST_CREATE_INDEX <https://doxygen.postgresql.org/gist__private_8h.html#a5a8e2e98e31d45df90d39057e704ef73> - gist_private.h
    XLOG_GIST_PAGE_SPLIT <https://doxygen.postgresql.org/gist__private_8h.html#ad8fe365920af63ec3592f5045d1d5f7c> - gist_private.h
    XLOG_GIST_PAGE_UPDATE <https://doxygen.postgresql.org/gist__private_8h.html#ae1dfd9314093a34bd1559be465fa7a46> - gist_private.h
    XLOG_HEAP2_CLEAN <https://doxygen.postgresql.org/heapam__xlog_8h.html#afd43c607f260d10d107b82ec56b46457> - heapam_xlog.h
    XLOG_HEAP2_CLEANUP_INFO <https://doxygen.postgresql.org/heapam__xlog_8h.html#a287947ce9e8640c834c965da8e68ec31> - heapam_xlog.h
    XLOG_HEAP2_FREEZE_PAGE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a99228d35e6c15389dc6c0c932f8f2084> - heapam_xlog.h
    XLOG_HEAP2_LOCK_UPDATED <https://doxygen.postgresql.org/heapam__xlog_8h.html#a953ee78dad4f0c83640fb5b58d450064> - heapam_xlog.h
    XLOG_HEAP2_MULTI_INSERT <https://doxygen.postgresql.org/heapam__xlog_8h.html#a09d28a8ec766e208ef3f14c941a9dceb> - heapam_xlog.h
    XLOG_HEAP2_NEW_CID <https://doxygen.postgresql.org/heapam__xlog_8h.html#aa6dce017eba7e3f59439352fac58a2c6> - heapam_xlog.h
    XLOG_HEAP2_REWRITE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a1d79b0ce034201fdb685f9023c73a496> - heapam_xlog.h
    XLOG_HEAP2_VISIBLE <https://doxygen.postgresql.org/heapam__xlog_8h.html#ae2fb90fa2889e34ddbf1a9eb36ca0d58> - heapam_xlog.h
    XLOG_HEAP_CONFIRM <https://doxygen.postgresql.org/heapam__xlog_8h.html#afb6ec95decce57c1fc5833050b687480> - heapam_xlog.h
    XLOG_HEAP_DELETE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a1699edb7efa9b08de135ca89a9d1e23c> - heapam_xlog.h
    XLOG_HEAP_HOT_UPDATE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a124f8f7c6207e8d372efa0b3b16bd60a> - heapam_xlog.h
    XLOG_HEAP_INIT_PAGE <https://doxygen.postgresql.org/heapam__xlog_8h.html#ae969c2b1184a09f88380015d0e4130fe> - heapam_xlog.h
    XLOG_HEAP_INPLACE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a94a3532f2f214b304f3098919748edec> - heapam_xlog.h
    XLOG_HEAP_INSERT <https://doxygen.postgresql.org/heapam__xlog_8h.html#acc254c522710da2616bae261202b9696> - heapam_xlog.h
    XLOG_HEAP_LOCK <https://doxygen.postgresql.org/heapam__xlog_8h.html#ab9ac57018bc8ff9c82f6d44a8d3c1f57> - heapam_xlog.h
    XLOG_HEAP_OPMASK <https://doxygen.postgresql.org/heapam__xlog_8h.html#a47385bef217a3dc92c3e9b99d69c70a3> - heapam_xlog.h
    XLOG_HEAP_UPDATE <https://doxygen.postgresql.org/heapam__xlog_8h.html#a514352c407ee9f18f5056bd4d800e4c1> - heapam_xlog.h
    XLOG_HISTORY <https://doxygen.postgresql.org/pg__standby_8c.html#a4da8f71093d15f8ddf825e8f14e6aacd> - pg_standby.c
    xlog_identify <javascript:searchResults.Toggle(%22SR_xlog_5fidentify%22)>
    XLOG_INCLUDE_ORIGIN <https://doxygen.postgresql.org/xlog_8h.html#a68159f3b34be48904cf9fcb06b58b36f> - xlog.h
    xlog_internal.h <https://doxygen.postgresql.org/xlog__internal_8h.html>
    XLOG_INVALIDATIONS <https://doxygen.postgresql.org/standbydefs_8h.html#a16cd2e19ee4c0d0ce2eb22167e0a5c38> - standbydefs.h
    XLOG_LOGICAL_MESSAGE <https://doxygen.postgresql.org/message_8h.html#a83dd85b27791b757d7b1f9ee36faa5c4> - message.h
    XLOG_MARK_UNIMPORTANT <https://doxygen.postgresql.org/xlog_8h.html#a150a45ddc593edecef4c8ba2f286e0fa> - xlog.h
    XLOG_MULTIXACT_CREATE_ID <https://doxygen.postgresql.org/multixact_8h.html#a8e47af7b2edbf0ed8860fcdb68e59b77> - multixact.h
    XLOG_MULTIXACT_TRUNCATE_ID <https://doxygen.postgresql.org/multixact_8h.html#a7e837595a280f12025a41fb023f6975d> - multixact.h
    XLOG_MULTIXACT_ZERO_MEM_PAGE <https://doxygen.postgresql.org/multixact_8h.html#a15b1dd070fbcabfbaeadad4c61e9fe75> - multixact.h
    XLOG_MULTIXACT_ZERO_OFF_PAGE <https://doxygen.postgresql.org/multixact_8h.html#a2977df1a4118452b0a0e5566fce294c8> - multixact.h
    XLOG_NEXTOID <https://doxygen.postgresql.org/pg__control_8h.html#a8b15845655cddbc8ceff021e18b6bd5b> - pg_control.h
    XLOG_NOOP <https://doxygen.postgresql.org/pg__control_8h.html#aa8d44e6e58023f97028a8d7774e3ae86> - pg_control.h
    xlog_outdesc <https://doxygen.postgresql.org/xlog_8c.html#a28b0b87f29ac8c681ec55538c7a0d04b> - xlog.c
    XLOG_PAGE_MAGIC <https://doxygen.postgresql.org/xlog__internal_8h.html#a8e4c79b6eca34bb621882f23adede48a> - xlog_internal.h
    XLOG_PARAMETER_CHANGE <https://doxygen.postgresql.org/pg__control_8h.html#adc354269b79e6a53ea84bda5ca2e2b23> - pg_control.h
    xlog_redo <javascript:searchResults.Toggle(%22SR_xlog_5fredo%22)>
    XLOG_RELMAP_UPDATE <https://doxygen.postgresql.org/relmapper_8h.html#a0bb2f002d83ea93ea184515fcb12c487> - relmapper.h
    XLOG_REPLORIGIN_DROP <https://doxygen.postgresql.org/origin_8h.html#aa1f479555c70bf34a53f288eb4fa9d57> - origin.h
    XLOG_REPLORIGIN_SET <https://doxygen.postgresql.org/origin_8h.html#ae090bab365094adb43942a941a860089> - origin.h
    XLOG_RESTORE_POINT <https://doxygen.postgresql.org/pg__control_8h.html#a0bc4e125e73e57add7c1a2b7555f483d> - pg_control.h
    XLOG_RUNNING_XACTS <https://doxygen.postgresql.org/standbydefs_8h.html#ab12fbc0105f85b9584eb7abdf4be9c8f> - standbydefs.h
    xlog_seg_size <https://doxygen.postgresql.org/structControlFileData.html#a23cf13e46c79d5ce43e944851bc3174b> - ControlFileData
    XLOG_SEQ_LOG <https://doxygen.postgresql.org/sequence_8h.html#ae204442ea6ae0d63ec9dd9ecf6214b4c> - sequence.h
    XLOG_SMGR_CREATE <https://doxygen.postgresql.org/storage__xlog_8h.html#a40d32269b4e6f811ff573b8ad8d2a7d1> - storage_xlog.h
    XLOG_SMGR_TRUNCATE <https://doxygen.postgresql.org/storage__xlog_8h.html#a499478a7c38a8cc140996a22a71562d5> - storage_xlog.h
    XLOG_SPGIST_ADD_LEAF <https://doxygen.postgresql.org/spgist__private_8h.html#a996b243b8c3c467525c5fdf491e2bc6a> - spgist_private.h
    XLOG_SPGIST_ADD_NODE <https://doxygen.postgresql.org/spgist__private_8h.html#a991c366ac0b700ea6cf97859a52fd521> - spgist_private.h
    XLOG_SPGIST_CREATE_INDEX <https://doxygen.postgresql.org/spgist__private_8h.html#a513a49635d4eab4620fa4a9cd0a66725> - spgist_private.h
    XLOG_SPGIST_MOVE_LEAFS <https://doxygen.postgresql.org/spgist__private_8h.html#aaa895e0a5137b26cdee5793bdeee78d0> - spgist_private.h
    XLOG_SPGIST_PICKSPLIT <https://doxygen.postgresql.org/spgist__private_8h.html#abdebd43c7d8301a686a9d9b2e88a03c0> - spgist_private.h
    XLOG_SPGIST_SPLIT_TUPLE <https://doxygen.postgresql.org/spgist__private_8h.html#a1bb43c5b6f08956332f2b50fbfeac404> - spgist_private.h
    XLOG_SPGIST_VACUUM_LEAF <https://doxygen.postgresql.org/spgist__private_8h.html#a4c695d55d965513172367a54dfb3cdd1> - spgist_private.h
    XLOG_SPGIST_VACUUM_REDIRECT <https://doxygen.postgresql.org/spgist__private_8h.html#aed51a1b70c04d574444e535448bf35f6> - spgist_private.h
    XLOG_SPGIST_VACUUM_ROOT <https://doxygen.postgresql.org/spgist__private_8h.html#a27c83b2efb3f0be9f543689cecaa5767> - spgist_private.h
    XLOG_STANDBY_LOCK <https://doxygen.postgresql.org/standbydefs_8h.html#a5fd8850a1cbb0fb49ea85661db7a60a2> - standbydefs.h
    XLOG_SWITCH <https://doxygen.postgresql.org/pg__control_8h.html#ad048df99b35282ec30f163c1957de9d3> - pg_control.h
    XLOG_TBLSPC_CREATE <https://doxygen.postgresql.org/tablespace_8h.html#a2e90aef5768f29c831df3725ffa1afcc> - tablespace.h
    XLOG_TBLSPC_DROP <https://doxygen.postgresql.org/tablespace_8h.html#a2b346ec30d305ad34a70419a14298a9a> - tablespace.h
    XLOG_XACT_ABORT <https://doxygen.postgresql.org/xact_8h.html#a825804340e245b3d4c60e72cbd7a3b91> - xact.h
    XLOG_XACT_ABORT_PREPARED <https://doxygen.postgresql.org/xact_8h.html#acf1fdec439e01d3c36aec08566f6af1f> - xact.h
    XLOG_XACT_ASSIGNMENT <https://doxygen.postgresql.org/xact_8h.html#aca8845707c6dad5ad3afe07d5882eca4> - xact.h
    XLOG_XACT_COMMIT <https://doxygen.postgresql.org/xact_8h.html#a6b0dd66a4a28c9923855a8834318ca09> - xact.h
    XLOG_XACT_COMMIT_PREPARED <https://doxygen.postgresql.org/xact_8h.html#a1b3730bd05f35ffa696212d6589d0ce3> - xact.h
    XLOG_XACT_HAS_INFO <https://doxygen.postgresql.org/xact_8h.html#adbbeafa721c6cd308c11022c965926ae> - xact.h
    XLOG_XACT_OPMASK <https://doxygen.postgresql.org/xact_8h.html#a6b97d131ba561ba540b35f1990e8c669> - xact.h
    XLOG_XACT_PREPARE <https://doxygen.postgresql.org/xact_8h.html#a544c5a98d349d6c27bb35ab636d029ed> - xact.h
    xlogarchive.c <https://doxygen.postgresql.org/xlogarchive_8c.html>
    XLogArchiveCheckDone <javascript:searchResults.Toggle(%22SR_xlogarchivecheckdone%22)>
    XLogArchiveCleanup <javascript:searchResults.Toggle(%22SR_xlogarchivecleanup%22)>
    XLogArchiveCommand <javascript:searchResults.Toggle(%22SR_xlogarchivecommand%22)>
    XLogArchiveCommandSet <https://doxygen.postgresql.org/xlog_8h.html#a04faf4a0d4aa1cea61846b93f2afde94> - xlog.h
    XLogArchiveForceDone <javascript:searchResults.Toggle(%22SR_xlogarchiveforcedone%22)>
    XLogArchiveIsBusy <javascript:searchResults.Toggle(%22SR_xlogarchiveisbusy%22)>
    XLogArchiveIsReady <javascript:searchResults.Toggle(%22SR_xlogarchiveisready%22)>
    XLogArchiveIsReadyOrDone <javascript:searchResults.Toggle(%22SR_xlogarchiveisreadyordone%22)>
    XLogArchiveMode <javascript:searchResults.Toggle(%22SR_xlogarchivemode%22)>
    XLogArchiveNotify <javascript:searchResults.Toggle(%22SR_xlogarchivenotify%22)>
    XLogArchiveNotifySeg <javascript:searchResults.Toggle(%22SR_xlogarchivenotifyseg%22)>
    XLogArchiveTimeout <javascript:searchResults.Toggle(%22SR_xlogarchivetimeout%22)>
    XLogArchivingActive <https://doxygen.postgresql.org/xlog_8h.html#a0722d9ca53151b7bc56ab5309dd29105> - xlog.h
    XLogArchivingAlways <https://doxygen.postgresql.org/xlog_8h.html#ad0bef96195ee515f84087bc418251ae5> - xlog.h
    XLogBackgroundFlush <javascript:searchResults.Toggle(%22SR_xlogbackgroundflush%22)>
    XLogBeginInsert <javascript:searchResults.Toggle(%22SR_xlogbegininsert%22)>
    XLOGbuffers <javascript:searchResults.Toggle(%22SR_xlogbuffers%22)>
    XLogBytePosToEndRecPtr <https://doxygen.postgresql.org/xlog_8c.html#a63e9218c8da4f289d7fabafaf099c70d> - xlog.c
    XLogBytePosToRecPtr <https://doxygen.postgresql.org/xlog_8c.html#a22948211fffe860cc7e711417fd2b88a> - xlog.c
    XLogCacheBlck <https://doxygen.postgresql.org/structXLogCtlData.html#a7efa18acfc83b86b7e0bb39c5a1d6180> - XLogCtlData
    XLogCheckBufferNeedsBackup <javascript:searchResults.Toggle(%22SR_xlogcheckbufferneedsbackup%22)>
    XLogCheckInvalidPages <javascript:searchResults.Toggle(%22SR_xlogcheckinvalidpages%22)>
    XLogCheckpointNeeded <https://doxygen.postgresql.org/xlog_8c.html#ac7fcdcaf3c30bfff91ba34a95f5b241f> - xlog.c
    XLOGChooseNumBuffers <https://doxygen.postgresql.org/xlog_8c.html#a62eba629a392548a2ea30e4d301e68bf> - xlog.c
    XLogCompressBackupBlock <https://doxygen.postgresql.org/xloginsert_8c.html#ae22ca35d456e30a52e7588ad53c578e5> - xloginsert.c
    XLogCtl <https://doxygen.postgresql.org/xlog_8c.html#a08295a9c52c91e205eabca6c53dcbdbe> - xlog.c
    XLogCtlData <javascript:searchResults.Toggle(%22SR_xlogctldata%22)>
    XLogCtlInsert <javascript:searchResults.Toggle(%22SR_xlogctlinsert%22)>
    xlogdefs.h <https://doxygen.postgresql.org/xlogdefs_8h.html>
    xlogdesc.c <https://doxygen.postgresql.org/xlogdesc_8c.html>
    XLOGDIR <https://doxygen.postgresql.org/xlog__internal_8h.html#a77e39e7339e0131203fbbf1da5faa873> - xlog_internal.h
    XLogDropDatabase <javascript:searchResults.Toggle(%22SR_xlogdropdatabase%22)>
    XLogDropRelation <javascript:searchResults.Toggle(%22SR_xlogdroprelation%22)>
    XLogDumpConfig <javascript:searchResults.Toggle(%22SR_xlogdumpconfig%22)>
    XLogDumpCountRecord <https://doxygen.postgresql.org/pg__xlogdump_8c.html#aff82bbaf0480cad26c82637fa0762056> - pg_xlogdump.c
    XLogDumpDisplayRecord <https://doxygen.postgresql.org/pg__xlogdump_8c.html#aa022c354036b3f1d1989720730345f34> - pg_xlogdump.c
    XLogDumpDisplayStats <https://doxygen.postgresql.org/pg__xlogdump_8c.html#a54882baadad1d6a5fcbdc7bdfe7bc5f8> - pg_xlogdump.c
    XLogDumpPrivate <javascript:searchResults.Toggle(%22SR_xlogdumpprivate%22)>
    XLogDumpReadPage <https://doxygen.postgresql.org/pg__xlogdump_8c.html#a20618c188fe79ca5007b4e77d2df205f> - pg_xlogdump.c
    XLogDumpStats <javascript:searchResults.Toggle(%22SR_xlogdumpstats%22)>
    XLogDumpStatsRow <https://doxygen.postgresql.org/pg__xlogdump_8c.html#aada1baa0d1f491b8d215dbceaf9a0daf> - pg_xlogdump.c
    XLogDumpXLogRead <https://doxygen.postgresql.org/pg__xlogdump_8c.html#a4b36fa810a7810236008bb22c25f5ec3> - pg_xlogdump.c
    xlogendptr <https://doxygen.postgresql.org/pg__basebackup_8c.html#af3c480069d8ad046ff341a6297d66b27> - pg_basebackup.c
    XLogEnsureRecordSpace <javascript:searchResults.Toggle(%22SR_xlogensurerecordspace%22)>
    XLogFileClose <https://doxygen.postgresql.org/xlog_8c.html#aa2986727c67ea03d40a1dbd566427822> - xlog.c
    XLogFileCopy <https://doxygen.postgresql.org/xlog_8c.html#a48c561d496c6f6c127f5d3c7584edabc> - xlog.c
    XLogFileInit <javascript:searchResults.Toggle(%22SR_xlogfileinit%22)>
    XLogFileName <https://doxygen.postgresql.org/xlog__internal_8h.html#afc1a7b6a24ef166178cbe21014abe8a2> - xlog_internal.h
    XLogFileNameById <https://doxygen.postgresql.org/xlog__internal_8h.html#ab81e30c6e569e65b5d8f04bbb48f021c> - xlog_internal.h
    XLogFileNameP <javascript:searchResults.Toggle(%22SR_xlogfilenamep%22)>
    XLogFileOpen <javascript:searchResults.Toggle(%22SR_xlogfileopen%22)>
    xlogFilePath <javascript:searchResults.Toggle(%22SR_xlogfilepath%22)>
    XLogFileRead <https://doxygen.postgresql.org/xlog_8c.html#a3b8c9c7dfdc4d28fb3071152bfe7017d> - xlog.c
    XLogFileReadAnyTLI <https://doxygen.postgresql.org/xlog_8c.html#a7b23db980fb02113f4314e8132fe4d52> - xlog.c
    XLOGfileslop <https://doxygen.postgresql.org/xlog_8c.html#a2f56b9336f820514ceecfece76228a7b> - xlog.c
    XLogFlush <javascript:searchResults.Toggle(%22SR_xlogflush%22)>
    xlogfpath <https://doxygen.postgresql.org/parsexlog_8c.html#afa3dcf4e435a4ed1b5f9a45f92d739e9> - parsexlog.c
    XLogFromFileName <https://doxygen.postgresql.org/xlog__internal_8h.html#ab2ded6f67666f0069571b0e0c4ee556a> - xlog_internal.h
    xlogfuncs.c <https://doxygen.postgresql.org/xlogfuncs_8c.html>
    XLogGetLastRemovedSegno <javascript:searchResults.Toggle(%22SR_xloggetlastremovedsegno%22)>
    XLogGetReplicationSlotMinimumLSN <https://doxygen.postgresql.org/xlog_8c.html#a459b5855b0f32fc4042a27193a8632d4> - xlog.c
    XLogHaveInvalidPages <javascript:searchResults.Toggle(%22SR_xloghaveinvalidpages%22)>
    XLogHintBitIsNeeded <https://doxygen.postgresql.org/xlog_8h.html#afba8efbfce50e33c2c306e79c7d7f853> - xlog.h
    xlogid <https://doxygen.postgresql.org/structPageXLogRecPtr.html#ae1e0b292b5ec19588ed021069f200c44> - PageXLogRecPtr
    XLogInitBufferForRedo <javascript:searchResults.Toggle(%22SR_xloginitbufferforredo%22)>
    XLogInsert <javascript:searchResults.Toggle(%22SR_xloginsert%22)>
    xloginsert.c <https://doxygen.postgresql.org/xloginsert_8c.html>
    xloginsert.h <https://doxygen.postgresql.org/xloginsert_8h.html>
    xloginsert_cxt <https://doxygen.postgresql.org/xloginsert_8c.html#a8b6566189db35d25132cc5498796531a> - xloginsert.c
    XLogInsertAllowed <javascript:searchResults.Toggle(%22SR_xloginsertallowed%22)>
    XLogInsertRecord <javascript:searchResults.Toggle(%22SR_xloginsertrecord%22)>
    XLogIsNeeded <https://doxygen.postgresql.org/xlog_8h.html#af4225b3b8fcad6601cb5bde514838976> - xlog.h
    XLogLogicalInfoActive <https://doxygen.postgresql.org/xlog_8h.html#a3565c399ee3d40ed4afa140478f7933e> - xlog.h
    XLogLongPageHeader <https://doxygen.postgresql.org/xlog__internal_8h.html#a1b2b37485b2502f4c3b8e13caeb46eef> - xlog_internal.h
    XLogLongPageHeaderData <javascript:searchResults.Toggle(%22SR_xloglongpageheaderdata%22)>
    XLogNeedsFlush <javascript:searchResults.Toggle(%22SR_xlogneedsflush%22)>
    XLogPageHeader <https://doxygen.postgresql.org/xlog__internal_8h.html#a6bf328cd65b03f2b2998ef4918464cf2> - xlog_internal.h
    XLogPageHeaderData <javascript:searchResults.Toggle(%22SR_xlogpageheaderdata%22)>
    XLogPageHeaderSize <https://doxygen.postgresql.org/xlog__internal_8h.html#ad4624af98c03ce138ba37961def4eb0c> - xlog_internal.h
    XLogPageRead <https://doxygen.postgresql.org/xlog_8c.html#a0d4418cd82148abf0d5d163334851d85> - xlog.c
    XLogPageReadCB <https://doxygen.postgresql.org/xlogreader_8h.html#a3a3a749f86bb5799646ba7a6af8b1821> - xlogreader.h
    XLogPageReadPrivate <javascript:searchResults.Toggle(%22SR_xlogpagereadprivate%22)>
    XLogPutNextOid <javascript:searchResults.Toggle(%22SR_xlogputnextoid%22)>
    XLogRead <javascript:searchResults.Toggle(%22SR_xlogread%22)>
    XLogReadBufferExtended <javascript:searchResults.Toggle(%22SR_xlogreadbufferextended%22)>
    XLogReadBufferForRedo <javascript:searchResults.Toggle(%22SR_xlogreadbufferforredo%22)>
    XLogReadBufferForRedoExtended <javascript:searchResults.Toggle(%22SR_xlogreadbufferforredoextended%22)>
    xlogreader.c <https://doxygen.postgresql.org/xlogreader_8c.html>
    xlogreader.h <https://doxygen.postgresql.org/xlogreader_8h.html>
    XLogReaderAllocate <javascript:searchResults.Toggle(%22SR_xlogreaderallocate%22)>
    XLogReaderFree <javascript:searchResults.Toggle(%22SR_xlogreaderfree%22)>
    XLogReaderInvalReadState <javascript:searchResults.Toggle(%22SR_xlogreaderinvalreadstate%22)>
    XLogReaderState <javascript:searchResults.Toggle(%22SR_xlogreaderstate%22)>
    xlogreadfd <https://doxygen.postgresql.org/parsexlog_8c.html#a9c2a5beb275c3e24a51da84e5b31f17d> - parsexlog.c
    XLogReadRecord <javascript:searchResults.Toggle(%22SR_xlogreadrecord%22)>
    xlogreadsegno <https://doxygen.postgresql.org/parsexlog_8c.html#a5dae7dfe7aa758e9ff0521a133961c76> - parsexlog.c
    XlogReadTwoPhaseData <https://doxygen.postgresql.org/twophase_8c.html#a044e6f482ece6c76aa19c2439e299469> - twophase.c
    XLogRecData <javascript:searchResults.Toggle(%22SR_xlogrecdata%22)>
    XLogReceiptSource <https://doxygen.postgresql.org/xlog_8c.html#a3f0d82893675c7792adcd4f92e52bf3c> - xlog.c
    XLogReceiptTime <https://doxygen.postgresql.org/xlog_8c.html#ab42473e36af5d4090c276ed76948c244> - xlog.c
    XLogRecGetBlockData <javascript:searchResults.Toggle(%22SR_xlogrecgetblockdata%22)>
    XLogRecGetBlockTag <javascript:searchResults.Toggle(%22SR_xlogrecgetblocktag%22)>
    XLogRecGetData <https://doxygen.postgresql.org/xlogreader_8h.html#a50063610bc5acb8bbf040147d6cdd7a7> - xlogreader.h
    XLogRecGetDataLen <https://doxygen.postgresql.org/xlogreader_8h.html#a185e655425468ba0f002727139e954e3> - xlogreader.h
    XLogRecGetInfo <https://doxygen.postgresql.org/xlogreader_8h.html#a20fc706271c4119b87defc34526016cb> - xlogreader.h
    XLogRecGetOrigin <https://doxygen.postgresql.org/xlogreader_8h.html#a00b3b7a225a7f7a1bfb9ec7117dea1fd> - xlogreader.h
    XLogRecGetPrev <https://doxygen.postgresql.org/xlogreader_8h.html#acaae032e576cc6b3d635469332c6597a> - xlogreader.h
    XLogRecGetRmid <https://doxygen.postgresql.org/xlogreader_8h.html#a48a8f2bac4018d6753b09805a1546043> - xlogreader.h
    XLogRecGetTotalLen <https://doxygen.postgresql.org/xlogreader_8h.html#a6518506bbdc4870638bf908b8ef647af> - xlogreader.h
    XLogRecGetXid <https://doxygen.postgresql.org/xlogreader_8h.html#a845e6dce9851c668fd79907d0965d177> - xlogreader.h
    XLogRecHasAnyBlockRefs <https://doxygen.postgresql.org/xlogreader_8h.html#ae5c8b95fa208a8eabf13b954311c30a5> - xlogreader.h
    XLogRecHasBlockImage <https://doxygen.postgresql.org/xlogreader_8h.html#ac1a4a85adc4e0c19962be566a90a5633> - xlogreader.h
    XLogRecHasBlockRef <https://doxygen.postgresql.org/xlogreader_8h.html#ac7ad516d66ff06aca1a2910b51823b4c> - xlogreader.h
    XLogRecord <javascript:searchResults.Toggle(%22SR_xlogrecord%22)>
    xlogrecord.h <https://doxygen.postgresql.org/xlogrecord_8h.html>
    XLogRecordAssemble <https://doxygen.postgresql.org/xloginsert_8c.html#a46d746c6c6f2af9a494749982bb7e226> - xloginsert.c
    XLogRecordBlockCompressHeader <javascript:searchResults.Toggle(%22SR_xlogrecordblockcompressheader%22)>
    XLogRecordBlockHeader <javascript:searchResults.Toggle(%22SR_xlogrecordblockheader%22)>
    XLogRecordBlockImageHeader <javascript:searchResults.Toggle(%22SR_xlogrecordblockimageheader%22)>
    XLogRecordBuffer <javascript:searchResults.Toggle(%22SR_xlogrecordbuffer%22)>
    XLogRecordDataHeaderLong <javascript:searchResults.Toggle(%22SR_xlogrecorddataheaderlong%22)>
    XLogRecordDataHeaderShort <javascript:searchResults.Toggle(%22SR_xlogrecorddataheadershort%22)>
    XLogRecordPageWithFreeSpace <javascript:searchResults.Toggle(%22SR_xlogrecordpagewithfreespace%22)>
    XLogRecPtr <https://doxygen.postgresql.org/xlogdefs_8h.html#a9f798cf05369dc78cd7688060d2c5993> - xlogdefs.h
    XLogRecPtrIsInvalid <https://doxygen.postgresql.org/xlogdefs_8h.html#a318e8305e570ecfb15130e6febed0e4e> - xlogdefs.h
    XLogRecPtrToBufIdx <https://doxygen.postgresql.org/xlog_8c.html#a7724df206772409331239f2d400098cb> - xlog.c
    XLogRecPtrToBytePos <https://doxygen.postgresql.org/xlog_8c.html#a71b7afa1e52f3cbbaf13713927de6c5a> - xlog.c
    XLogRedoAction <https://doxygen.postgresql.org/xlogutils_8h.html#aed615cdfe11ef9fe82f892664c157d01> - xlogutils.h
    XLogRegisterBlock <javascript:searchResults.Toggle(%22SR_xlogregisterblock%22)>
    XLogRegisterBufData <javascript:searchResults.Toggle(%22SR_xlogregisterbufdata%22)>
    XLogRegisterBuffer <javascript:searchResults.Toggle(%22SR_xlogregisterbuffer%22)>
    XLogRegisterData <javascript:searchResults.Toggle(%22SR_xlogregisterdata%22)>
    XLogReportParameters <https://doxygen.postgresql.org/xlog_8c.html#a4247736f85ad96f33cc37a290bbb1bf7> - xlog.c
    XLogRequestWalReceiverReply <javascript:searchResults.Toggle(%22SR_xlogrequestwalreceiverreply%22)>
    XLogResetInsertion <javascript:searchResults.Toggle(%22SR_xlogresetinsertion%22)>
    XLogRestorePoint <javascript:searchResults.Toggle(%22SR_xlogrestorepoint%22)>
    XLogSaveBufferForHint <javascript:searchResults.Toggle(%22SR_xlogsavebufferforhint%22)>
    XLogSegmentsPerXLogId <https://doxygen.postgresql.org/xlog__internal_8h.html#a8ddde6138f591b4282127df0b62b17f5> - xlog_internal.h
    XLogSegNo <https://doxygen.postgresql.org/xlogdefs_8h.html#afa9db36d4b92482e150dea8f2b079760> - xlogdefs.h
    XLogSegNoOffsetToRecPtr <https://doxygen.postgresql.org/xlog__internal_8h.html#ab02a343a9314a29ab9f94fc96e0c9ffb> - xlog_internal.h
    XLogSegSize <https://doxygen.postgresql.org/xlog__internal_8h.html#a223aba5b5efcaa6f9465cdf6b0e236e0> - xlog_internal.h
    XLogSendLogical <https://doxygen.postgresql.org/walsender_8c.html#a4fe0e7ef70e1bf17e92708c09e0f5984> - walsender.c
    XLogSendPhysical <https://doxygen.postgresql.org/walsender_8c.html#a1b69b9b9f5373335c6dc28671d20c3eb> - walsender.c
    XLogSetAsyncXactLSN <javascript:searchResults.Toggle(%22SR_xlogsetasyncxactlsn%22)>
    XLogSetRecordFlags <javascript:searchResults.Toggle(%22SR_xlogsetrecordflags%22)>
    XLogSetReplicationSlotMinimumLSN <javascript:searchResults.Toggle(%22SR_xlogsetreplicationslotminimumlsn%22)>
    XLOGShmemInit <javascript:searchResults.Toggle(%22SR_xlogshmeminit%22)>
    XLOGShmemSize <javascript:searchResults.Toggle(%22SR_xlogshmemsize%22)>
    XLogSource <https://doxygen.postgresql.org/xlog_8c.html#aa4ae6b53287149eeb167868e4a55d714> - xlog.c
    xlogSourceNames <https://doxygen.postgresql.org/xlog_8c.html#a2bc71ea31ed3e005d6c67c444ace160e> - xlog.c
    XLogStandbyInfoActive <https://doxygen.postgresql.org/xlog_8h.html#afc72a658a332edc7df1e62a52795fb03> - xlog.h
    XLogTruncateRelation <javascript:searchResults.Toggle(%22SR_xlogtruncaterelation%22)>
    xlogutils.c <https://doxygen.postgresql.org/xlogutils_8c.html>
    xlogutils.h <https://doxygen.postgresql.org/xlogutils_8h.html>
    xlogVacuumPage <https://doxygen.postgresql.org/ginvacuum_8c.html#a50c6cda171adcec5b3aabb90f46cd86e> - ginvacuum.c
    XLogWalRcvFlush <https://doxygen.postgresql.org/walreceiver_8c.html#ae807ab6c61cc901281f1c4f79c4353d4> - walreceiver.c
    XLogWalRcvProcessMsg <https://doxygen.postgresql.org/walreceiver_8c.html#abea9da4cdfbaff6e1b67394abe9fa01e> - walreceiver.c
    XLogWalRcvSendHSFeedback <https://doxygen.postgresql.org/walreceiver_8c.html#ab160b7b903131c79de34f3ebc6236e52> - walreceiver.c
    XLogWalRcvSendReply <https://doxygen.postgresql.org/walreceiver_8c.html#ad2122e96cbfb1c04533ead161720c455> - walreceiver.c
    XLogWalRcvWrite <https://doxygen.postgresql.org/walreceiver_8c.html#aba5a7785f0fa8b96f70bd378df95aab2> - walreceiver.c
    XLogWrite <https://doxygen.postgresql.org/xlog_8c.html#a2e2fc1a5e9a6536b067ce943d87f5b7c> - xlog.c
    XLogwrtResult <javascript:searchResults.Toggle(%22SR_xlogwrtresult%22)>
    XLogwrtRqst <javascript:searchResults.Toggle(%22SR_xlogwrtrqst%22)>
    
    
    
    
    > On Dec 29, 2016, at 12:07 PM, Stephen Frost <sfrost@snowman.net> wrote:
    > 
    > Cynthia,
    > 
    > * Cynthia Shang (cynthia.shang@crunchydata.com) wrote:
    >> 1) I agree with Michael that we should make this change backward compatible. It would help PostgreSQL image if we did not break everyone's code. It costs businesses money to rewrite code (e.g. middle tier software, backup tools, etc), test and redeploy to their customers. 
    > 
    > While I agree that we don't want to break client code or to make
    > backwards incompatible changes without good cause, in this case, it's
    > definitely a good cause and it makes sense to have things be consistent
    > and that includes changing these functions.
    > 
    > We make backwards-incompatible changes with each major release, which is
    > part of why we support older versions of PG for as long as we do- to
    > give PG users time to make any necessary changes for the new version of
    > PG.  One could argue that we shouldn't ever make a backwards
    > incompatible change because it will break an existing user's code and
    > cost users time and effort to rewrite that code, but the flip side of
    > that is that the extra code and complexity results in its own
    > maintenance burdens for the code and the project moving forward.
    > 
    > Generally speaking, we've also found that backwards compatibility
    > 'features' end up having a much longer life than they should.
    > Ultimately, the best way forward tends to be either make the backwards
    > incompatible change or don't make the change at all.  We've already
    > agreed on this particular change, and with good reason, so the way
    > forward is to make the rest of the changes, not to go half-way or to try
    > and provide some backwards compatibility complexity.
    > 
    >> 2) We decided to rename the pg_xlog directory because people were deleting it when disks were getting full thinking it was just unimportant logging data; I get that. I'm a little unclear why we need to change the functions - it would be less painful to our users and less risky if we just left them as is. Could someone please elaborate why this change is necessary? I'm just trying to understand that.
    > 
    > It would be inconsistent to change the directory name without also
    > changing the documentation, functions, and other user-facing pieces.
    > 
    > Thanks!
    > 
    > Stephen
    
    
  10. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2016-12-29T17:59:28Z

    Cynthia,
    
    Please don't top-post on the PG mailing lists but rather write responses
    in-line.
    
    * Cynthia Shang (cynthia.shang@crunchydata.com) wrote:
    > I have never heard of coding standards where naming conventions required a function/variable name match a directory or file name. It seems that would be restrictive. 
    
    We aren't discussing a coding standard, we're talking about changing the
    references from 'xlog' to 'wal' to match the change we did to the
    directory, to be consistent.
    
    > I'm not trying to pick a fight, I just think the pros should outweigh the cons when choosing a path forward. In this case I see lots of cons and one partial pro; partial because renaming only user facing functions and documentation will create inconsistency within the Postgres code for all of the following. It sounds as if your minds are already made up, which saddens me but I will say nothing further on the matter.
    
    All backwards incompatible changes are judgement calls and people are
    certainly welcome to have different opinions.  I have a pretty strong
    feeling about this particular change being worthwhile and also pretty
    long overdue.
    
    [... list of references to xlog in the code ...]
    
    No need to include a list, I can find them myself. :)
    
    Nearly all of the references listed are internal functions or references
    in the code.  Those don't need to be changed, just the user-facing
    pieces, which is quite a bit less.
    
    The doxygen website is generated directly off of the code and isn't
    user-facing documentation.
    
    Thanks!
    
    Stephen
    
  11. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2016-12-30T11:08:56Z

    On Thu, Dec 29, 2016 at 5:48 PM, Cynthia Shang <
    cynthia.shang@crunchydata.com> wrote:
    
    > I have never heard of coding standards where naming conventions required a
    > function/variable name match a directory or file name. It seems that would
    > be restrictive.
    >
    
    This is not about coding standard, this is about terminology and common
    sense.
    
    
    >
    > I'm not trying to pick a fight, I just think the pros should outweigh the
    > cons when choosing a path forward. In this case I see lots of cons and one
    > partial pro; partial because renaming only user facing functions and
    > documentation will create inconsistency within the Postgres code for all of
    > the following. It sounds as if your minds are already made up, which
    > saddens me but I will say nothing further on the matter.
    >
    
    Ultimately, from user/dba perspective code does not matter. Consistency
    does. I found out firsthand that the fact pg_swicth_xlog() does something
    in pg_wal directory is rather confusing.
    
    The way I see it decision has been made to rename 'pg_xlog' to 'pg_wal'.
    Since this directory name is effectively part of API (e.g. for setups with
    xlog on different disk, backup scripts, etc), rest of API either needs to
    follow or this decision needs to be revised (but that ship has probably
    sailed).
    I think small inconvenience of a small group of people (PostgreSQL
    developers) is worth the improvement for much larger group of people
    (PostgreSQL users).
    
    Now, I'm not sure whether it is worth maintaining function aliases.
    Assuming these are indeed trivial (can somebody point me to example?) I see
    roughly the same amount of downsides both ways.
    Having aliases raises additional questions:
    - do we keep them documented (probably not?)
    - do we keep them forever or kill in some future version?
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  12. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2016-12-30T11:10:09Z

    On Thu, Dec 29, 2016 at 5:59 PM, Stephen Frost <sfrost@snowman.net> wrote:
    
    > I have a pretty strong
    > feeling about this particular change being worthwhile and also pretty
    > long overdue.
    >
    
    Yeah, sorry for that. I should be able to make some progress early January.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  13. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2016-12-30T11:42:41Z

    On Fri, Dec 30, 2016 at 2:59 AM, Stephen Frost <sfrost@snowman.net> wrote:
    > All backwards incompatible changes are judgement calls and people are
    > certainly welcome to have different opinions.  I have a pretty strong
    > feeling about this particular change being worthwhile and also pretty
    > long overdue.
    
    The renaming is definitely worth it to be consistent with the new
    pg_wal/. Now as in the case of those functions we have ways a simple
    way to avoid useless pain to users we should really take it easy. So
    introducing a set of aliases and deprecating them after a couple of
    years is a fine plan IMO.
    -- 
    Michael
    
    
    
  14. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2016-12-30T11:45:08Z

    On Fri, Dec 30, 2016 at 8:08 PM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > Now, I'm not sure whether it is worth maintaining function aliases. Assuming
    > these are indeed trivial (can somebody point me to example?) I see roughly
    > the same amount of downsides both ways.
    > Having aliases raises additional questions:
    > - do we keep them documented (probably not?)
    > - do we keep them forever or kill in some future version?
    
    The idea here is to keep documented only the new function names, but
    mention in the release notes that aliases are kept, and that those
    will be dropped in a couple of years (see for example 5d58c07a for
    initdb). This will give plenty of time to monitoring script
    maintainers to adapt to the new world order.
    -- 
    Michael
    
    
    
  15. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2016-12-30T14:57:25Z

    * Michael Paquier (michael.paquier@gmail.com) wrote:
    > On Fri, Dec 30, 2016 at 8:08 PM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > > Now, I'm not sure whether it is worth maintaining function aliases. Assuming
    > > these are indeed trivial (can somebody point me to example?) I see roughly
    > > the same amount of downsides both ways.
    > > Having aliases raises additional questions:
    > > - do we keep them documented (probably not?)
    > > - do we keep them forever or kill in some future version?
    > 
    > The idea here is to keep documented only the new function names, but
    > mention in the release notes that aliases are kept, and that those
    > will be dropped in a couple of years (see for example 5d58c07a for
    > initdb). This will give plenty of time to monitoring script
    > maintainers to adapt to the new world order.
    
    I don't particularly like this.  Undocumented aliases that make things
    keep working are bound to just confuse people who are looking at what's
    happening (eg: logging queries) and wondering "what the heck is that
    function?!" and then if they're unable to find it in the docs then they
    might think it's some local function that they can remove or similar.
    
    Worse, those function aliases will probably continue to persist for
    forever because no one can agree on removing them.
    
    We maintain back-branches for years to provide people time to adjust
    their code and whatever else they need to, no one is going to be forced
    to move to 10 for quite a few years yet.
    
    Additionally, people who are actually using these bits of the system are
    almost certainly going to have to adjust things for the directory
    change, having to change other bits of related code nearby at the same
    time is much better than someone changing just the directory now and
    then having to remmeber/realize that they have to change the function
    calls in a few years or "whenever the PG people decide to remove the
    function aliases."
    
    Let's make this a clean break/change.  Perhaps it will also encourage
    people who have their own hacked together scripts to consider using a
    well maintained alternative solution.
    
    Thanks!
    
    Stephen
    
  16. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Fetter <david@fetter.org> — 2016-12-30T17:46:40Z

    On Fri, Dec 30, 2016 at 09:57:25AM -0500, Stephen Frost wrote:
    
    > Let's make this a clean break/change.
    
    +1 
    
    If there are known management gizmos to notify, it'd be nice to try to
    give them some sort of warning, but even for them, the release notes
    should spell it out clearly.
    
    That business where people would delete files with "log" in the path,
    not infrequently on a system running at capacity, isn't just
    theoretical.  I've seen people lose data permanently that way, and I
    know I'm not the only one who's seen this in the real world.
    
    Best,
    David.
    -- 
    David Fetter <david(at)fetter(dot)org> http://fetter.org/
    Phone: +1 415 235 3778  AIM: dfetter666  Yahoo!: dfetter
    Skype: davidfetter      XMPP: david(dot)fetter(at)gmail(dot)com
    
    Remember to vote!
    Consider donating to Postgres: http://www.postgresql.org/about/donate
    
    
    
  17. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vik Fearing <vik@2ndquadrant.fr> — 2016-12-30T22:07:56Z

    On 12/30/2016 06:46 PM, David Fetter wrote:
    > On Fri, Dec 30, 2016 at 09:57:25AM -0500, Stephen Frost wrote:
    > 
    >> Let's make this a clean break/change.
    > 
    > +1 
    
    +1
    -- 
    Vik Fearing                                          +33 6 46 75 15 36
    http://2ndQuadrant.fr     PostgreSQL : Expertise, Formation et Support
    
    
    
  18. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-01T15:48:02Z

    On 12/30/16 9:57 AM, Stephen Frost wrote:
    > Additionally, people who are actually using these bits of the system are
    > almost certainly going to have to adjust things for the directory
    > change,
    
    Some *xlog* functions are commonly used to measure replay lag.  That
    usage would not be affected by the directory renaming.  Renaming those
    functions would only serve to annoy users and have them delay their
    upgrades.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  19. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Jim Nasby <jim.nasby@bluetreble.com> — 2017-01-02T17:30:40Z

    On 1/1/17 9:48 AM, Peter Eisentraut wrote:
    > On 12/30/16 9:57 AM, Stephen Frost wrote:
    >> Additionally, people who are actually using these bits of the system are
    >> almost certainly going to have to adjust things for the directory
    >> change,
    >
    > Some *xlog* functions are commonly used to measure replay lag.  That
    > usage would not be affected by the directory renaming.  Renaming those
    > functions would only serve to annoy users and have them delay their
    > upgrades.
    
    Perhaps we should split the difference and do what we did for XML: 
    provide a contrib module with alias functions using the old (xlog) names.
    -- 
    Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
    Experts in Analytics, Data Architecture and PostgreSQL
    Data in Trouble? Get it in Treble! http://BlueTreble.com
    855-TREBLE2 (855-873-2532)
    
    
    
  20. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-01-02T17:39:39Z

    
    On 1/2/17 12:30 PM, Jim Nasby wrote:
    > On 1/1/17 9:48 AM, Peter Eisentraut wrote:
    >> On 12/30/16 9:57 AM, Stephen Frost wrote:
    >>> Additionally, people who are actually using these bits of the system are
    >>> almost certainly going to have to adjust things for the directory
    >>> change,
    >>
    >> Some *xlog* functions are commonly used to measure replay lag.  That
    >> usage would not be affected by the directory renaming.  Renaming those
    >> functions would only serve to annoy users and have them delay their
    >> upgrades.
    > 
    > Perhaps we should split the difference and do what we did for XML:
    > provide a contrib module with alias functions using the old (xlog) names.
    
    -1
    
    Since these functions are normally used by admins and not generally used
    in SQL and functions, I'm not convinced the maintenance of the extension
    would be worth it.  Admins are free to create whatever aliases they need
    to get their work done.
    
    -- 
    -David
    david@pgmasters.net
    
    
    
  21. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Jim Nasby <jim.nasby@bluetreble.com> — 2017-01-02T19:09:21Z

    On 1/2/17 11:39 AM, David Steele wrote:
    >
    >
    > On 1/2/17 12:30 PM, Jim Nasby wrote:
    >> On 1/1/17 9:48 AM, Peter Eisentraut wrote:
    >>> On 12/30/16 9:57 AM, Stephen Frost wrote:
    >>>> Additionally, people who are actually using these bits of the system are
    >>>> almost certainly going to have to adjust things for the directory
    >>>> change,
    >>>
    >>> Some *xlog* functions are commonly used to measure replay lag.  That
    >>> usage would not be affected by the directory renaming.  Renaming those
    >>> functions would only serve to annoy users and have them delay their
    >>> upgrades.
    >>
    >> Perhaps we should split the difference and do what we did for XML:
    >> provide a contrib module with alias functions using the old (xlog) names.
    >
    > -1
    >
    > Since these functions are normally used by admins and not generally used
    > in SQL and functions, I'm not convinced the maintenance of the extension
    > would be worth it.  Admins are free to create whatever aliases they need
    > to get their work done.
    
    AIUI several others are arguing that this name change is going to break 
    a lot of user monitoring code. I certainly agree with Stephen that some 
    of the *xlog* functions are used for monitoring replay lag. So I think a 
    backwards compatibility fix is reasonable.
    
    Why would we force users to each come up with their own solution to this 
    when we can just provide one?
    
    BTW, I think fears of the maintenance cost of a contrib module are 
    pretty overblown... it's not like we change these functions that often. 
    We have added quite a few in the last few releases, but we don't need 
    backwards compatibility for new stuff.
    -- 
    Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
    Experts in Analytics, Data Architecture and PostgreSQL
    Data in Trouble? Get it in Treble! http://BlueTreble.com
    855-TREBLE2 (855-873-2532)
    
    
    
  22. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-02T19:18:07Z

    Jim Nasby <Jim.Nasby@BlueTreble.com> writes:
    > On 1/2/17 11:39 AM, David Steele wrote:
    >> On 1/2/17 12:30 PM, Jim Nasby wrote:
    >>> On 1/1/17 9:48 AM, Peter Eisentraut wrote:
    >>> Perhaps we should split the difference and do what we did for XML:
    >>> provide a contrib module with alias functions using the old (xlog) names.
    
    >> -1
    >> Since these functions are normally used by admins and not generally used
    >> in SQL and functions, I'm not convinced the maintenance of the extension
    >> would be worth it.  Admins are free to create whatever aliases they need
    >> to get their work done.
    
    > BTW, I think fears of the maintenance cost of a contrib module are 
    > pretty overblown... it's not like we change these functions that often. 
    > We have added quite a few in the last few releases, but we don't need 
    > backwards compatibility for new stuff.
    
    I'm also -1 on this idea.  If we're going to provide backwards
    compatibility, we should just leave the old names in the core.
    Providing an extension is more work for *everybody* --- for us, and
    for the users who will have to learn about and install the extension.
    I don't see any gain to justify that work, either.
    
    			regards, tom lane
    
    
    
  23. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-03T11:56:31Z

    On Tue, Jan 3, 2017 at 4:18 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > I'm also -1 on this idea.  If we're going to provide backwards
    > compatibility, we should just leave the old names in the core.
    > Providing an extension is more work for *everybody* --- for us, and
    > for the users who will have to learn about and install the extension.
    > I don't see any gain to justify that work, either.
    
    Yeah, let's make the life of users just easier if we can, without any
    extension. Some people are likely going to forget to enable it anyway,
    and some more don't like installing the package dedicated to contrib
    modules.
    -- 
    Michael
    
    
    
  24. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-03T13:26:50Z

    On Tue, Jan 3, 2017 at 11:56 AM, Michael Paquier <michael.paquier@gmail.com>
    wrote:
    
    > Yeah, let's make the life of users just easier if we can, without any
    > extension. Some people are likely going to forget to enable it anyway,
    > and some more don't like installing the package dedicated to contrib
    > modules.
    >
    
    I think I +1 on this.
    I've did a github search on these function names and there is a lot of code
    that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    keep the aliases around for couple of versions after which hopefully a lot
    of the code will be updated.
    
    After I'm done with a patch I can take a look if there's a way to mass-fill
    issues to affected projects on github (and maybe other hosting providers)
    and ask them to migrate to new function names. This is of course will not
    fix everything, but it would be a significant chunk. I suspect a lot of
    private tools/scripts borrow snippets from github as well.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  25. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-03T15:37:08Z

    Vladamir, all,
    
    * Vladimir Rusinov (vrusinov@google.com) wrote:
    > On Tue, Jan 3, 2017 at 11:56 AM, Michael Paquier <michael.paquier@gmail.com>
    > wrote:
    > 
    > > Yeah, let's make the life of users just easier if we can, without any
    > > extension. Some people are likely going to forget to enable it anyway,
    > > and some more don't like installing the package dedicated to contrib
    > > modules.
    > 
    > I think I +1 on this.
    > I've did a github search on these function names and there is a lot of code
    > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    > keep the aliases around for couple of versions after which hopefully a lot
    > of the code will be updated.
    
    And there's 12k hits for pg_xlog.
    
    If we do that, we'll just end up with exactly the same question about
    removing them and the same amount of code breakage in a few years.  I
    don't see how that is really helping anyone.
    
    > After I'm done with a patch I can take a look if there's a way to mass-fill
    > issues to affected projects on github (and maybe other hosting providers)
    > and ask them to migrate to new function names. This is of course will not
    > fix everything, but it would be a significant chunk. I suspect a lot of
    > private tools/scripts borrow snippets from github as well.
    
    If they're maintained, then they'll be updated.  I don't have any
    sympathy if they aren't maintained.
    
    If we really feel that this is the only thing between 9.6 and 10 that'll
    cause problems for some serious amount of code and we don't expect to
    change the function APIs anytime in the near future then perhaps we
    could keep aliases, *document* them, and treat them as full functions
    just like the regular ones.  Doing that requires a bit of extra
    documentation and a few extra entries in pg_proc.  If we ever change
    them then we'll need to make sure to let people know that they're both
    changing, of course, in release notes and anywhere else.
    
    Personally, I'm not excited about keeping these as documented aliases
    because, frankly, I don't think it's the only thing that's going to
    break for these projects between 9.6 and 10, and if they're being well
    maintained then making the change isn't going to be a big deal, but I
    won't object to adding them if that's what it takes to make progress
    here.
    
    Thanks!
    
    Stephen
    
  26. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-03T16:17:40Z

    On Tue, Jan 3, 2017 at 3:37 PM, Stephen Frost <sfrost@snowman.net> wrote:
    
    > If they're maintained, then they'll be updated.  I don't have any
    >
    sympathy if they aren't maintained.
    >
    
    Updating may be non-trivial effort even if they are maintained. E.g. some
    project may need to support both 9.6 and 10.0, and a lot of them written in
    a way that makes conditionals on function names non-trivial (e.g. there's
    just flat .sql file that is expected to work everywhere).
    
     *document* them, and treat them as full functions just like the regular
    > ones.
    
    
    In my next WIP version of the patch (
    https://github.com/vrusinov/postgres/tree/rename-xlog) I keep references to
    old names in the description for the new names. This makes it
    searchable/greppable and does not encourage their usage. Exact format may
    change, but I'd certainly not like to treat them exactly like full
    functions and I'd like them to be mentioned so it's possible to search.
    
    Overall, I don't feel super-strong either way. Adding aliases does not seem
    like a lot of effort or burden and I also see arguments for dropping them
    sooner than later. As a compromise I propose keep aliases with hard
    deadline for removal in 11.0.
    This way we are nicer to people who maintain their tools and read release
    notes via giving them more time, and nicer to ourselves via cleaning legacy
    stuff relatively soon.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  27. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-03T16:34:50Z

    * Vladimir Rusinov (vrusinov@google.com) wrote:
    > On Tue, Jan 3, 2017 at 3:37 PM, Stephen Frost <sfrost@snowman.net> wrote:
    > > If they're maintained, then they'll be updated.  I don't have any
    > >
    > sympathy if they aren't maintained.
    > >
    > 
    > Updating may be non-trivial effort even if they are maintained. E.g. some
    > project may need to support both 9.6 and 10.0, and a lot of them written in
    > a way that makes conditionals on function names non-trivial (e.g. there's
    > just flat .sql file that is expected to work everywhere).
    
    I don't think we should be concerned with that.  Anything but the
    simplest SQL scripts have a good chance of being broken across major
    version upgrades, *especially* ones that are using admin functions,
    which we change on a regular basis for various reasons.
    
    >  *document* them, and treat them as full functions just like the regular
    > > ones.
    > 
    > In my next WIP version of the patch (
    > https://github.com/vrusinov/postgres/tree/rename-xlog) I keep references to
    > old names in the description for the new names. This makes it
    > searchable/greppable and does not encourage their usage. Exact format may
    > change, but I'd certainly not like to treat them exactly like full
    > functions and I'd like them to be mentioned so it's possible to search.
    
    My point is that we need to document them and make sure to mention them
    whenever we change anything about them (release notes, etc), exactly to
    make sure that someone reading the release notes will know what to
    search their code for.
    
    > Overall, I don't feel super-strong either way. Adding aliases does not seem
    > like a lot of effort or burden and I also see arguments for dropping them
    > sooner than later. As a compromise I propose keep aliases with hard
    > deadline for removal in 11.0.
    
    Ugh, no, I don't want to have this argument again next year.
    
    > This way we are nicer to people who maintain their tools and read release
    > notes via giving them more time, and nicer to ourselves via cleaning legacy
    > stuff relatively soon.
    
    They have plenty of time.  If we're going to remove them, then let's
    just do it and have a clean break.
    
    Thanks!
    
    Stephen
    
  28. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-04T07:32:28Z

    Hi,
    
    On 2017-01-03 10:37:08 -0500, Stephen Frost wrote:
    > * Vladimir Rusinov (vrusinov@google.com) wrote:
    > > I think I +1 on this.
    > > I've did a github search on these function names and there is a lot of code
    > > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    > > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    > > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    > > keep the aliases around for couple of versions after which hopefully a lot
    > > of the code will be updated.
    > 
    > And there's 12k hits for pg_xlog.
    
    > If we do that, we'll just end up with exactly the same question about
    > removing them and the same amount of code breakage in a few years.  I
    > don't see how that is really helping anyone.
    
    Meh^2.  The cost of having pg_xlog was that people lost their
    data. Hence their was motivation of changing things. The cost of having
    some function aliases is, what, a pg_proc line?  If we end up carrying
    them forever, so what?
    
    
    > If we really feel that this is the only thing between 9.6 and 10 that'll
    > cause problems for some serious amount of code and we don't expect to
    > change the function APIs anytime in the near future then perhaps we
    > could keep aliases, *document* them, and treat them as full functions
    > just like the regular ones.
    
    I think we've been far to cavalier lately about unnecessarily breaking
    admin and monitoring tools. There's been pg_stat_activity backward
    incompat changes in most of the last releases. It's a *PAIN* to develop
    monitoring / admin tools that work with a number of releases.  It's fine
    to cause that pain if there's some considerable benefit (e.g. not
    triggering data loss seems like a case for that, as imo is unifying
    configuration), but I don't see how that justifying breaking things
    gratuitously.  Just renaming well known functions for a minor bit of
    cleanliness seems not to survive a cost/benefit analysis.
    
    Greetings,
    
    Andres Freund
    
    
    
  29. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Simon Riggs <simon@2ndquadrant.com> — 2017-01-04T08:25:09Z

    On 4 January 2017 at 07:32, Andres Freund <andres@anarazel.de> wrote:
    
    > I think we've been far to cavalier lately about unnecessarily breaking
    > admin and monitoring tools.
    
    > Just renaming well known functions for a minor bit of
    > cleanliness seems not to survive a cost/benefit analysis.
    
    +1
    
    This thread is at best a minor cleanup item, yet major work still
    remains for 10.0.
    
    -- 
    Simon Riggs                http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  30. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-04T14:38:42Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-03 10:37:08 -0500, Stephen Frost wrote:
    > > * Vladimir Rusinov (vrusinov@google.com) wrote:
    > > > I think I +1 on this.
    > > > I've did a github search on these function names and there is a lot of code
    > > > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    > > > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    > > > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    > > > keep the aliases around for couple of versions after which hopefully a lot
    > > > of the code will be updated.
    > > 
    > > And there's 12k hits for pg_xlog.
    > 
    > > If we do that, we'll just end up with exactly the same question about
    > > removing them and the same amount of code breakage in a few years.  I
    > > don't see how that is really helping anyone.
    > 
    > Meh^2.  The cost of having pg_xlog was that people lost their
    > data. Hence their was motivation of changing things. The cost of having
    > some function aliases is, what, a pg_proc line?  If we end up carrying
    > them forever, so what?
    
    I outlined exactly that in the part you didn't quote.
    
    > > If we really feel that this is the only thing between 9.6 and 10 that'll
    > > cause problems for some serious amount of code and we don't expect to
    > > change the function APIs anytime in the near future then perhaps we
    > > could keep aliases, *document* them, and treat them as full functions
    > > just like the regular ones.
    > 
    > I think we've been far to cavalier lately about unnecessarily breaking
    > admin and monitoring tools. There's been pg_stat_activity backward
    > incompat changes in most of the last releases. It's a *PAIN* to develop
    > monitoring / admin tools that work with a number of releases.  It's fine
    > to cause that pain if there's some considerable benefit (e.g. not
    > triggering data loss seems like a case for that, as imo is unifying
    > configuration), but I don't see how that justifying breaking things
    > gratuitously.  Just renaming well known functions for a minor bit of
    > cleanliness seems not to survive a cost/benefit analysis.
    
    I agree that we have been breaking monitoring tools on the regular for a
    while as we continue to add capabilities and improve things, which is
    part of the reason that I don't see this particular break as a very big
    deal- serious monitoring tools are going to need to be updated anyway.
    
    I don't see that changing any time soon either- we are woefully far
    behind in this area compared to other databases and we should be trying
    to encourage people to continue improving these areas, not making things
    unnecessairly difficult by requiring backwards compatibility hacks.
    
    As I said in what you did quote above- I won't complain if someone wants
    the aliases and we include them in the documentation, but I don't agree
    with the other suggestions of having undocumented aliases or not making
    the change.
    
    Thanks!
    
    Stephen
    
  31. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-04T14:55:25Z

    Stephen Frost <sfrost@snowman.net> writes:
    > As I said in what you did quote above- I won't complain if someone wants
    > the aliases and we include them in the documentation, but I don't agree
    > with the other suggestions of having undocumented aliases or not making
    > the change.
    
    FWIW, that position makes sense to me as well.  If we keep aliases,
    let's just reconcile ourselves to the probability that they'll be there
    indefinitely.  It's not that big a deal, and the other proposals are
    bigger warts than having an alias.
    
    			regards, tom lane
    
    
    
  32. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-05T16:31:56Z

    Attaching a patch that renames all 'xlog' functions, keeping aliases for
    old ones (since it looks like majority vote is for keeping them).
    
    Following functions have been renamed:
    
        Name                            |   Replaced by
        --------------------------------|-------------------------------
        pg_current_xlog_flush_location  | pg_current_wal_flush_location
        pg_current_xlog_insert_location | pg_current_wal_insert_location
        pg_current_xlog_location        | pg_current_wal_location
        pg_is_xlog_replay_paused        | pg_is_recovery_paused
        pg_last_xlog_receive_location   | pg_last_wal_receive_location
        pg_last_xlog_replay_location    | pg_last_wal_replay_location
        pg_switch_xlog                  | pg_switch_wal
        pg_xlog_location_diff           | pg_wal_location_diff
        pg_xlog_replay_pause            | pg_pause_recovery
        pg_xlog_replay_resume           | pg_resume_recovery
        pg_xlogfile_name                | pg_wal_file_name
        pg_xlogfile_name_offset         | pg_wal_file_name_offset
    
    
    Questions/possible follow-up work:
    
    - OIDs - where do I get numbers from? I was kinda choosing them at random,
    unaware if there is some process for keeping track of them. Please point me
    if such thing exists and I'll change them.
    - Documentation. I've added a new section with a simple table, keeping it
    somewhat neglected on purpose. We'll have old names in index and searchable
    on page, but nothing more. Is it sufficient?
    - New function names. I've used 'recovery' instead of 'xlog_replay' and
    used 'wal_file' instead of 'xlogfile'. Does it make sense?
    - Release notes. I was unable to find a draft for 10.0. How do I make sure
    these renames are not forgotten?
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  33. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-05T19:10:12Z

    On 2017-01-04 09:38:42 -0500, Stephen Frost wrote:
    > Andres,
    > 
    > * Andres Freund (andres@anarazel.de) wrote:
    > > On 2017-01-03 10:37:08 -0500, Stephen Frost wrote:
    > > > * Vladimir Rusinov (vrusinov@google.com) wrote:
    > > > > I think I +1 on this.
    > > > > I've did a github search on these function names and there is a lot of code
    > > > > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    > > > > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    > > > > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    > > > > keep the aliases around for couple of versions after which hopefully a lot
    > > > > of the code will be updated.
    > > > 
    > > > And there's 12k hits for pg_xlog.
    > > 
    > > > If we do that, we'll just end up with exactly the same question about
    > > > removing them and the same amount of code breakage in a few years.  I
    > > > don't see how that is really helping anyone.
    > > 
    > > Meh^2.  The cost of having pg_xlog was that people lost their
    > > data. Hence their was motivation of changing things. The cost of having
    > > some function aliases is, what, a pg_proc line?  If we end up carrying
    > > them forever, so what?
    > 
    > I outlined exactly that in the part you didn't quote.
    
    Sure, but my point was that you and several others essentially argue for
    breaking things gratuitously. And I think that's bad. That you can live
    with backward compatibility doesn't change that point.
    
    
    > > > If we really feel that this is the only thing between 9.6 and 10 that'll
    > > > cause problems for some serious amount of code and we don't expect to
    > > > change the function APIs anytime in the near future then perhaps we
    > > > could keep aliases, *document* them, and treat them as full functions
    > > > just like the regular ones.
    > > 
    > > I think we've been far to cavalier lately about unnecessarily breaking
    > > admin and monitoring tools. There's been pg_stat_activity backward
    > > incompat changes in most of the last releases. It's a *PAIN* to develop
    > > monitoring / admin tools that work with a number of releases.  It's fine
    > > to cause that pain if there's some considerable benefit (e.g. not
    > > triggering data loss seems like a case for that, as imo is unifying
    > > configuration), but I don't see how that justifying breaking things
    > > gratuitously.  Just renaming well known functions for a minor bit of
    > > cleanliness seems not to survive a cost/benefit analysis.
    > 
    > I agree that we have been breaking monitoring tools on the regular for a
    > while as we continue to add capabilities and improve things, which is
    > part of the reason that I don't see this particular break as a very big
    > deal- serious monitoring tools are going to need to be updated anyway.
    
    I have no problem with breaking things when necessary. I do have a
    problem when we do so willy-nilly when providing backward-compatibility
    would have been easy enough. E.g. Nearly all recent pg_stat_activity
    changes would have been doable just as well without breakage.
    
    
    > I don't see that changing any time soon either- we are woefully far
    > behind in this area compared to other databases and we should be trying
    > to encourage people to continue improving these areas, not making things
    > unnecessairly difficult by requiring backwards compatibility hacks.
    
    By breaking stuff on a regular basis we're also showing that we're
    behind. Compatibility also is a big topic. We also force users to stay
    behind longer, and to upgrade less frequently.
    
    
    Andres
    
    
    
  34. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-05T20:04:36Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-04 09:38:42 -0500, Stephen Frost wrote:
    > > * Andres Freund (andres@anarazel.de) wrote:
    > > > On 2017-01-03 10:37:08 -0500, Stephen Frost wrote:
    > > > > * Vladimir Rusinov (vrusinov@google.com) wrote:
    > > > > > I think I +1 on this.
    > > > > > I've did a github search on these function names and there is a lot of code
    > > > > > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    > > > > > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    > > > > > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    > > > > > keep the aliases around for couple of versions after which hopefully a lot
    > > > > > of the code will be updated.
    > > > > 
    > > > > And there's 12k hits for pg_xlog.
    > > > 
    > > > > If we do that, we'll just end up with exactly the same question about
    > > > > removing them and the same amount of code breakage in a few years.  I
    > > > > don't see how that is really helping anyone.
    > > > 
    > > > Meh^2.  The cost of having pg_xlog was that people lost their
    > > > data. Hence their was motivation of changing things. The cost of having
    > > > some function aliases is, what, a pg_proc line?  If we end up carrying
    > > > them forever, so what?
    > > 
    > > I outlined exactly that in the part you didn't quote.
    > 
    > Sure, but my point was that you and several others essentially argue for
    > breaking things gratuitously. And I think that's bad. That you can live
    > with backward compatibility doesn't change that point.
    
    I do not agree that we are arguing for breaking things gratuitously.
    That's saying that there's no justification for such a change and I
    think that's wrong- the prior names were driven off the directory name
    and were, really, not well suited to what the functions were actually
    for.  This change is to align the functions with the agreed-upon
    directory name change and because the new name is distinctly more
    accurate than the prior name.  As discussed previously, the term
    'transaction log' is more closely related to what *clog* is than the
    write-ahead log.
    
    My feeling is that people who are arguing for the aliases are doing so
    from a position of "it's easy for us to do, so we should," which I am
    generally not in favor of when it comes to backwards compatibility
    because it leaves things in an inconsistent state.  Tools which monitor
    the progression of our write-ahead-log (wal) from the primary to stanbys
    will end up using a function that has "xlog" in the name, even though
    that's an inconsistent and less than accurate name for what they're
    actually doing, simply because "well, that part didn't break, so we
    don't have to change it, even though these other things had to be
    changed to refer to 'wal'".  That, in my opinion, isn't the right
    compromise to be making.
    
    > > > > If we really feel that this is the only thing between 9.6 and 10 that'll
    > > > > cause problems for some serious amount of code and we don't expect to
    > > > > change the function APIs anytime in the near future then perhaps we
    > > > > could keep aliases, *document* them, and treat them as full functions
    > > > > just like the regular ones.
    > > > 
    > > > I think we've been far to cavalier lately about unnecessarily breaking
    > > > admin and monitoring tools. There's been pg_stat_activity backward
    > > > incompat changes in most of the last releases. It's a *PAIN* to develop
    > > > monitoring / admin tools that work with a number of releases.  It's fine
    > > > to cause that pain if there's some considerable benefit (e.g. not
    > > > triggering data loss seems like a case for that, as imo is unifying
    > > > configuration), but I don't see how that justifying breaking things
    > > > gratuitously.  Just renaming well known functions for a minor bit of
    > > > cleanliness seems not to survive a cost/benefit analysis.
    > > 
    > > I agree that we have been breaking monitoring tools on the regular for a
    > > while as we continue to add capabilities and improve things, which is
    > > part of the reason that I don't see this particular break as a very big
    > > deal- serious monitoring tools are going to need to be updated anyway.
    > 
    > I have no problem with breaking things when necessary. I do have a
    > problem when we do so willy-nilly when providing backward-compatibility
    > would have been easy enough. E.g. Nearly all recent pg_stat_activity
    > changes would have been doable just as well without breakage.
    
    Would those changes have resulted in an inconsistent and difficult
    system to understand and follow?  For pg_stat_activity, frankly, I don't
    recall offhand which probably means they weren't a very big deal for me.
    
    Changes to anything related to the 'pg_xlog' directory or the set of
    functions that pgbackrest or our tools care about are a lot closer to me
    and changes there represent serious time that I'll need to ask David and
    Jeff to spend on updating pgbackrest and our tooling for, yet I've had
    no push-back from them on this because there is general agreement that
    this is a good change to be making.
    
    > > I don't see that changing any time soon either- we are woefully far
    > > behind in this area compared to other databases and we should be trying
    > > to encourage people to continue improving these areas, not making things
    > > unnecessairly difficult by requiring backwards compatibility hacks.
    > 
    > By breaking stuff on a regular basis we're also showing that we're
    > behind. Compatibility also is a big topic. We also force users to stay
    > behind longer, and to upgrade less frequently.
    
    I don't mind showing that we're behind, it's a fact and anyone who cares
    to will found that out quickly enough.  I do object to putting up
    roadblocks or making it more difficult than necessary to making
    progress.
    
    I have a pretty hard time believing that users are going to seriously
    stay on older versions for very much longer just because of these
    changes.  Either they have a strong interest in the new features in
    later releases and have cause to upgrade, in which case updating a few
    function calls isn't going to be a big deal, or they don't have much
    cause to change and therefore they're not going to rush to do so (which
    is an entirly acceptable position!).
    
    Lastly, if they have an issue with the tooling around the database that
    uses these functions or they have an issue with the maintenance
    requirements associated with such relativly mundane changes, that they
    instead use tools which are well maintained and are updated consistently
    with the changes being made.
    
    Thanks!
    
    Stephen
    
  35. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-06T00:44:32Z

    On Fri, Jan 6, 2017 at 1:31 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > Attaching a patch that renames all 'xlog' functions, keeping aliases for old
    > ones (since it looks like majority vote is for keeping them).
    
    OK.
    
    > - OIDs - where do I get numbers from? I was kinda choosing them at random,
    > unaware if there is some process for keeping track of them. Please point me
    > if such thing exists and I'll change them.
    
    You can use src/include/catalog/unused_oids to look at the OIDs not
    yet assigned. Assigning them logically increasing may be a good idea.
    But OID ordering is not that mandatory for the internal functions and
    operators.
    
    > - Documentation. I've added a new section with a simple table, keeping it
    > somewhat neglected on purpose. We'll have old names in index and searchable
    > on page, but nothing more. Is it sufficient?
    
    I find quite clear what you have produced here. The table states
    clearly the one-one mapping between the old and new entries.
    
    > - New function names. I've used 'recovery' instead of 'xlog_replay'
    
    I would not have touched this one. But if we go this way, let's
    bike-shed and use pg_recovery_ as prefix for consistency.
    
    > and used 'wal_file' instead of 'xlogfile'. Does it make sense?
    
    This one yes.
    
    For simplicity I would just have done a s/xlog/wal/ and keep the names
    consistent a maximum with the old ones. But I am just working here.
    You clearly put thoughts in the new names.
    
    > - Release notes. I was unable to find a draft for 10.0. How do I make sure
    > these renames are not forgotten?
    
    That's part of the job of the release note writer, very likely Tom or
    Bruce. The commit message should be explicit enough that the writer
    does not have to dig into the code itself for the changes.
    -- 
    Michael
    
    
    
  36. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Bruce Momjian <bruce@momjian.us> — 2017-01-07T01:21:01Z

    On Wed, Jan  4, 2017 at 09:38:42AM -0500, Stephen Frost wrote:
    > > I think we've been far to cavalier lately about unnecessarily breaking
    > > admin and monitoring tools. There's been pg_stat_activity backward
    > > incompat changes in most of the last releases. It's a *PAIN* to develop
    > > monitoring / admin tools that work with a number of releases.  It's fine
    > > to cause that pain if there's some considerable benefit (e.g. not
    > > triggering data loss seems like a case for that, as imo is unifying
    > > configuration), but I don't see how that justifying breaking things
    > > gratuitously.  Just renaming well known functions for a minor bit of
    > > cleanliness seems not to survive a cost/benefit analysis.
    > 
    > I agree that we have been breaking monitoring tools on the regular for a
    > while as we continue to add capabilities and improve things, which is
    > part of the reason that I don't see this particular break as a very big
    > deal- serious monitoring tools are going to need to be updated anyway.
    > 
    > I don't see that changing any time soon either- we are woefully far
    > behind in this area compared to other databases and we should be trying
    > to encourage people to continue improving these areas, not making things
    > unnecessairly difficult by requiring backwards compatibility hacks.
    
    I agree.  I know these changes are painful, and I will take
    responsibility for perhaps the most cavalier breakage of
    pg_stat_statements in renaming column procpid to pid.  (I still stand
    behind that change.)
    
    As painful as these breakages are *at* the time of the breakage,
    long-term, it keeps our user API clean.  Frankly, because changes are
    reviewed by so many people, we don't normally make dumb API mistakes
    that require changes --- rather new features or complex interactions
    require user API changes.  We often feel we have too many users to make
    the change, but every few years we double our user base and all those
    new users see a nice clean API that previous users had to adjust to.
    
    If we don't make changes like this, our API becomes nonintuitive very
    quickly, and let's face it, we expose a lot of internal interfaces to
    our users, so clarity is extra important.
    
    I don't think anyone is arguing that these API breakages are cost-free,
    but I think long-term, the costs are minor compared to the clean API we
    provide to users.
    
    -- 
      Bruce Momjian  <bruce@momjian.us>        http://momjian.us
      EnterpriseDB                             http://enterprisedb.com
    
    + As you are, so once was I.  As I am, so you will be. +
    +                      Ancient Roman grave inscription +
    
    
    
  37. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Jim Nasby <jim.nasby@bluetreble.com> — 2017-01-08T03:35:59Z

    On 1/6/17 7:21 PM, Bruce Momjian wrote:
    > I don't think anyone is arguing that these API breakages are cost-free,
    > but I think long-term, the costs are minor compared to the clean API we
    > provide to users.
    
    Except in this case we can provide a clean new API without gratuitously 
    breaking the old one.
    
    I absolutely do agree that we have to have a way of making incompatible 
    changes from time to time (as I've been arguing over and over in the 
    plpgsql2 thread). I also think a one-size-fits-all approach to when a 
    break is allowed would be good. That said, the change to 
    pg_stat_activity caused a lot of needless user pain, and this one will 
    as well.
    
    What makes this even more frustrating (to me at least) is that the 
    attitude that's been demonstrated around plpgsql is that there can 
    absolutely NEVER be a compatibility break of any kind.
    
    So part of the project thinks it's perfectly OK to just break things 
    without any warning or support, while another part of the project 
    adamantly refuses any kind of a break at all, even what's breaking has 
    never officially been supported.
    
    I don't think that dichotomy is good for the community or for our users.
    -- 
    Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
    Experts in Analytics, Data Architecture and PostgreSQL
    Data in Trouble? Get it in Treble! http://BlueTreble.com
    855-TREBLE2 (855-873-2532)
    
    
    
  38. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-09T15:50:37Z

    On Fri, Jan 6, 2017 at 12:44 AM, Michael Paquier <michael.paquier@gmail.com>
    wrote:
    
    > > - OIDs - where do I get numbers from? I was kinda choosing them at
    > random,
    > > unaware if there is some process for keeping track of them. Please point
    > me
    > > if such thing exists and I'll change them.
    >
    > You can use src/include/catalog/unused_oids to look at the OIDs not
    > yet assigned. Assigning them logically increasing may be a good idea.
    > But OID ordering is not that mandatory for the internal functions and
    > operators.
    >
    
    Thanks, that's useful tip.
    Looks like I am fine, although I could have reused some lower numbers.
    
    
    > > - New function names. I've used 'recovery' instead of 'xlog_replay'
    >
    > I would not have touched this one. But if we go this way, let's
    > bike-shed and use pg_recovery_ as prefix for consistency.
    >
    
    Makes sense, renamed those to wal_replay.
    
    
    > > - Release notes. I was unable to find a draft for 10.0. How do I make
    > sure
    >
    > these renames are not forgotten?
    >
    > That's part of the job of the release note writer, very likely Tom or
    > Bruce. The commit message should be explicit enough that the writer
    > does not have to dig into the code itself for the changes.
    >
    
    I see. Attached patch is just a output of 'git diff master' and does not
    contain message since I've messed up squashing, but here's the commit
    message I intended to use (feel free to reuse fully or partially, beware
    that I have probably messed up grammar, so somebody who actually knows
    English should review):
    
        Remove 'xlog' references from admin functions.
    
        After 'pg_xlog' has been renamed to 'pg_wal' 'xlog' reference in
    function names is confusing.
        This change renames 'xlog' in function names to 'wal', keeping old
        function names as aliases.
    
        Following functions have been renamed:
    
        Name                            |   Replaced by
        --------------------------------|-------------------------------
        pg_current_xlog_flush_location  | pg_current_wal_flush_location
        pg_current_xlog_insert_location | pg_current_wal_insert_location
        pg_current_xlog_location        | pg_current_wal_location
        pg_is_xlog_replay_paused        | pg_is_recovery_paused
        pg_last_xlog_receive_location   | pg_last_wal_receive_location
        pg_last_xlog_replay_location    | pg_last_wal_replay_location
        pg_switch_xlog                  | pg_switch_wal
        pg_xlog_location_diff           | pg_wal_location_diff
        pg_xlog_replay_pause            | pg_wal_replay_pause
        pg_xlog_replay_resume           | pg_wal_replay_resume
        pg_xlogfile_name                | pg_wal_file_name
        pg_xlogfile_name_offset         | pg_wal_file_name_offset
    
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  39. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-09T16:14:40Z

    On 1/9/17 10:50 AM, Vladimir Rusinov wrote:
    > pg_is_xlog_replay_paused        | pg_is_recovery_paused
    
    All the other xlog_replay names have been changed to wal_replay, so
    making this one different is probably not so good.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  40. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-09T16:53:44Z

    On Mon, Jan 9, 2017 at 4:14 PM, Peter Eisentraut <
    peter.eisentraut@2ndquadrant.com> wrote:
    
    > > pg_is_xlog_replay_paused        | pg_is_recovery_paused
    >
    > All the other xlog_replay names have been changed to wal_replay, so
    > making this one different is probably not so good.
    >
    
    Oops, forgot about that one. Attached patch with this addressed as well.
    
        Remove 'xlog' references from admin functions.
    
        After 'pg_xlog' has been renamed to 'pg_wal' 'xlog' reference in
    function names is confusing.
        This change renames 'xlog' in function names to 'wal', keeping old
        function names as aliases.
    
        Following functions have been renamed:
    
        Name                            |   Replaced by
        --------------------------------|-------------------------------
        pg_current_xlog_flush_location  | pg_current_wal_flush_location
        pg_current_xlog_insert_location | pg_current_wal_insert_location
        pg_current_xlog_location        | pg_current_wal_location
        pg_is_xlog_replay_paused        | pg_is_wal_replay_paused
        pg_last_xlog_receive_location   | pg_last_wal_receive_location
        pg_last_xlog_replay_location    | pg_last_wal_replay_location
        pg_switch_xlog                  | pg_switch_wal
        pg_xlog_location_diff           | pg_wal_location_diff
        pg_xlog_replay_pause            | pg_wal_replay_pause
        pg_xlog_replay_resume           | pg_wal_replay_resume
        pg_xlogfile_name                | pg_wal_file_name
        pg_xlogfile_name_offset         | pg_wal_file_name_offset
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  41. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-10T05:24:02Z

    On Tue, Jan 10, 2017 at 1:53 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >
    > On Mon, Jan 9, 2017 at 4:14 PM, Peter Eisentraut
    > <peter.eisentraut@2ndquadrant.com> wrote:
    >>
    >> > pg_is_xlog_replay_paused        | pg_is_recovery_paused
    >>
    >> All the other xlog_replay names have been changed to wal_replay, so
    >> making this one different is probably not so good.
    >
    > Oops, forgot about that one. Attached patch with this addressed as well.
    
    -                errhint("pg_xlogfile_name_offset() cannot be executed
    during recovery.")));
    +                errhint(
    +                    "pg_wal_file_name_offset() cannot be executed
    during recovery.")));
    I am not sure that there is any need to reformat this error hint.
    
    Your patch includes useless diff noise in pg_proc.h. By that I mean
    the lines of pg_start_backup, pg_stop_backup, etc.
    
    +/*  Next OID: 6016 */
    +
    I don't think you need that.
    
    src/test/perl/PostgresNode.pm has added recently a new method called
    lsn() that uses some of the WAL position functions. Their update is
    necessary as well for this patch.
    
    As there are two school of thoughts on this thread, keeping your patch
    with the compatibility table is the best move for now. Even if we end
    up by having a version without aliases, that will be just code to
    remove in the final version.
    -- 
    Michael
    
    
    
  42. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Fujii Masao <masao.fujii@gmail.com> — 2017-01-10T09:28:57Z

    On Wed, Jan 4, 2017 at 4:32 PM, Andres Freund <andres@anarazel.de> wrote:
    > Hi,
    >
    > On 2017-01-03 10:37:08 -0500, Stephen Frost wrote:
    >> * Vladimir Rusinov (vrusinov@google.com) wrote:
    >> > I think I +1 on this.
    >> > I've did a github search on these function names and there is a lot of code
    >> > that use them. E.g. there is 8.5k hits for pg_last_xlog_location
    >> > <https://github.com/search?q=pg_last_xlog_replay_location&type=Code&utf8=%E2%9C%93>;
    >> > a lot of them a forks and copy-pastes, but still, that's quite a lot. Let's
    >> > keep the aliases around for couple of versions after which hopefully a lot
    >> > of the code will be updated.
    >>
    >> And there's 12k hits for pg_xlog.
    >
    >> If we do that, we'll just end up with exactly the same question about
    >> removing them and the same amount of code breakage in a few years.  I
    >> don't see how that is really helping anyone.
    >
    > Meh^2.  The cost of having pg_xlog was that people lost their
    > data. Hence their was motivation of changing things. The cost of having
    > some function aliases is, what, a pg_proc line?  If we end up carrying
    > them forever, so what?
    >
    >
    >> If we really feel that this is the only thing between 9.6 and 10 that'll
    >> cause problems for some serious amount of code and we don't expect to
    >> change the function APIs anytime in the near future then perhaps we
    >> could keep aliases, *document* them, and treat them as full functions
    >> just like the regular ones.
    >
    > I think we've been far to cavalier lately about unnecessarily breaking
    > admin and monitoring tools. There's been pg_stat_activity backward
    > incompat changes in most of the last releases. It's a *PAIN* to develop
    > monitoring / admin tools that work with a number of releases.  It's fine
    > to cause that pain if there's some considerable benefit (e.g. not
    > triggering data loss seems like a case for that, as imo is unifying
    > configuration), but I don't see how that justifying breaking things
    > gratuitously.  Just renaming well known functions for a minor bit of
    > cleanliness seems not to survive a cost/benefit analysis.
    
    +1
    
    Regards,
    
    -- 
    Fujii Masao
    
    
    
  43. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-11T17:00:29Z

    On Tue, Jan 10, 2017 at 5:24 AM, Michael Paquier <michael.paquier@gmail.com>
    wrote:
    
    > -                errhint("pg_xlogfile_name_offset() cannot be executed
    > during recovery.")));
    > +                errhint(
    > +                    "pg_wal_file_name_offset() cannot be executed
    > during recovery.")));
    > I am not sure that there is any need to reformat this error hint.
    >
    > Your patch includes useless diff noise in pg_proc.h. By that I mean
    > the lines of pg_start_backup, pg_stop_backup, etc.
    >
    > +/*  Next OID: 6016 */
    > +
    > I don't think you need that.
    >
    
    Reverted all of above.
    
    
    >
    > src/test/perl/PostgresNode.pm has added recently a new method called
    > lsn() that uses some of the WAL position functions. Their update is
    > necessary as well for this patch.
    >
    
    Good catch. Changed those as well.
    
    
    > As there are two school of thoughts on this thread, keeping your patch
    > with the compatibility table is the best move for now. Even if we end
    > up by having a version without aliases, that will be just code to
    > remove in the final version.
    >
    
    Indeed, it is trivial to kill aliases.
    
    New version of the patch attached.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  44. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-12T05:49:22Z

    On Thu, Jan 12, 2017 at 2:00 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > On Tue, Jan 10, 2017 at 5:24 AM, Michael Paquier <michael.paquier@gmail.com>
    > wrote:
    >> As there are two school of thoughts on this thread, keeping your patch
    >> with the compatibility table is the best move for now. Even if we end
    >> up by having a version without aliases, that will be just code to
    >> remove in the final version.
    >
    > Indeed, it is trivial to kill aliases.
    >
    > New version of the patch attached.
    
    The patch still updates a bunch of .po files. Those are normally
    refreshed with the translation updates, so they had better be removed.
    Other than that, the patch looks in good shape to me so switch to
    "Ready for committer".
    
    So, to sum up things on this thread, here are the votes about the use
    of aliases or a pure breakage:
    - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    Vladimir, Simon R, Fujii-san => 8
    If I misunderstood things, please feel free to speak up.
    -- 
    Michael
    
    
    
  45. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Fujii Masao <masao.fujii@gmail.com> — 2017-01-12T05:56:10Z

    On Thu, Jan 12, 2017 at 2:49 PM, Michael Paquier
    <michael.paquier@gmail.com> wrote:
    > On Thu, Jan 12, 2017 at 2:00 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >> On Tue, Jan 10, 2017 at 5:24 AM, Michael Paquier <michael.paquier@gmail.com>
    >> wrote:
    >>> As there are two school of thoughts on this thread, keeping your patch
    >>> with the compatibility table is the best move for now. Even if we end
    >>> up by having a version without aliases, that will be just code to
    >>> remove in the final version.
    >>
    >> Indeed, it is trivial to kill aliases.
    >>
    >> New version of the patch attached.
    >
    > The patch still updates a bunch of .po files. Those are normally
    > refreshed with the translation updates, so they had better be removed.
    > Other than that, the patch looks in good shape to me so switch to
    > "Ready for committer".
    >
    > So, to sum up things on this thread, here are the votes about the use
    > of aliases or a pure breakage:
    > - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    > - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    > Vladimir, Simon R, Fujii-san => 8
    > If I misunderstood things, please feel free to speak up.
    
    To be pricise, I'd like to avoid the renaming of the functions at all rather
    than using aliases.
    
    Regards,
    
    -- 
    Fujii Masao
    
    
    
  46. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-01-12T13:56:33Z

    On 1/12/17 12:49 AM, Michael Paquier wrote:
    > On Thu, Jan 12, 2017 at 2:00 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >> On Tue, Jan 10, 2017 at 5:24 AM, Michael Paquier <michael.paquier@gmail.com>
    >> wrote:
    >>> As there are two school of thoughts on this thread, keeping your patch
    >>> with the compatibility table is the best move for now. Even if we end
    >>> up by having a version without aliases, that will be just code to
    >>> remove in the final version.
    >>
    >> Indeed, it is trivial to kill aliases.
    >>
    >> New version of the patch attached.
    > 
    > The patch still updates a bunch of .po files. Those are normally
    > refreshed with the translation updates, so they had better be removed.
    > Other than that, the patch looks in good shape to me so switch to
    > "Ready for committer".
    > 
    > So, to sum up things on this thread, here are the votes about the use
    > of aliases or a pure breakage:
    > - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    > - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    > Vladimir, Simon R, Fujii-san => 8
    > If I misunderstood things, please feel free to speak up.
    
    I'm also in the "no to aliases" camp.
    
    -- 
    -David
    david@pgmasters.net
    
    
    
  47. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-12T14:33:23Z

    On Thu, Jan 12, 2017 at 8:56 AM, David Steele <david@pgmasters.net> wrote:
    >> So, to sum up things on this thread, here are the votes about the use
    >> of aliases or a pure breakage:
    >> - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    >> - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    >> Vladimir, Simon R, Fujii-san => 8
    >> If I misunderstood things, please feel free to speak up.
    >
    > I'm also in the "no to aliases" camp.
    
    Me too.
    
    I appreciate what people are saying about the pain that is involved
    when we change administration interfaces.  However, I suspect that
    most of that pain falls on tool authors, who are disproportionately
    represented in this forum, and on DBAs, who may not like it much but
    can probably cope with it.  It's not really going to affect
    applications, because applications generally don't care about the
    transaction log directly.  What is really bad is when we break syntax
    that might be used in queries, or in PL/pgsql functions.  That's why
    the 8.3 casting changes were so painful, and why the discussion about
    changing PL/pgsql semantics is so dominated by people who don't want
    to break what's worth now.  When we change things in those areas,
    people who know nothing and care nothing about PostgreSQL other than
    that it's the underlying database have to update their SQL, and that
    hurts adoption.  Anyone who is affected by these proposed changes is
    already deeply invested in PostgreSQL.
    
    Also, I think it is absolutely wrong to suppose that there's no pain
    involved in having these aliases around forever.  I thought the idea
    of stuffing the aliases in a contrib module was a rather good one,
    actually, because then the people who need them can install them
    easily and yet the burden on core to maintain them is largely removed.
    Also, there's still positive pressure for tools that haven't been
    updated to get themselves updated to work without that compatibility
    extension, so eventually the need for it should go away.  I have not
    abandoned all hope of eventually removing contrib/tsearch2 from the
    core distribution.  When we keep things in the core system catalogs,
    they just accumulate forever.  There will not only be old code that
    continues to use the old names; there will be new code that uses the
    old names.  There will be people who ask why we have two copies of the
    function, or aren't sure which one to use.  Somebody will have a
    tab-completion fail that results from an irrelevant decision between
    two names for the same thing.  Individually, these things don't matter
    very much, but over time they lead to a user experience that's full of
    warts and a developer experience that is enslaved to historical
    garbage that takes time and energy away from new feature development.
    
    So, my order of preference is:
    
    1. Rename everything and add an extension to create aliases for the old names.
    2. Rename everything without adding a backward-compatibility extension.
    3. Don't rename anything.
    4. Stomach flu.
    5. Put a second name for everything in pg_proc.h.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  48. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-12T16:00:12Z

    On Thu, Jan 12, 2017 at 5:49 AM, Michael Paquier <michael.paquier@gmail.com>
    wrote:
    
    > The patch still updates a bunch of .po files. Those are normally
    > refreshed with the translation updates, so they had better be removed.
    > Other than that, the patch looks in good shape to me so switch to
    > "Ready for committer".
    >
    
    Gotcha. Excluded these from the new version of the patch. It's actually
    same as above but produced with some git :(exclude) magic.
    
    
    > So, to sum up things on this thread, here are the votes about the use
    > of aliases or a pure breakage:
    > - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    > - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    > Vladimir, Simon R, Fujii-san => 8
    > If I misunderstood things, please feel free to speak up.
    >
    
    Counting amendments and more votes down the thread:
    
    - no aliases: Stephen, Tom, David F, Vik, Bruce M, David Steele, Robert
    Haas => 7
    - yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N, Vladimir,
    Simon R => 7
    - avoid renaming altogether: Fujii-san => 1
    
    Duh. Folks, you are not making it easy. :) Looks like we need one more vote.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  49. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Euler Taveira <euler@timbira.com.br> — 2017-01-12T16:57:20Z

    On 12-01-2017 10:56, David Steele wrote:
    >> So, to sum up things on this thread, here are the votes about the use
    >> of aliases or a pure breakage:
    >> - No to aliases, shake the world: Stephen, Tom, David F, Vik, Bruce M => 5
    >> - Yes to aliases: Michael P, Andres, Peter E., Cynthia S, Jim N,
    >> Vladimir, Simon R, Fujii-san => 8
    >> If I misunderstood things, please feel free to speak up.
    > 
    > I'm also in the "no to aliases" camp.
    > 
    +1. Even if we don't document aliases, one day some applications will
    break when someone decided to clean up this code. Let's do it smoothly.
    As Robert suggested in the other email: extension to create old names.
    
    
    -- 
       Euler Taveira                   Timbira - http://www.timbira.com.br/
       PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento
    
    
    
  50. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-12T18:04:15Z

    On Thu, Jan 12, 2017 at 4:57 PM, Euler Taveira <euler@timbira.com.br> wrote:
    
    > As Robert suggested in the other email: extension to create old names.
    
    
    I don't follow the reasoning for the extension. It seem to have downsides
    of both alternatives combined: we still break people's code, and we add
    even more maintenance burden than just keeping aliases.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  51. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-12T18:12:35Z

    Vladimir Rusinov <vrusinov@google.com> writes:
    > On Thu, Jan 12, 2017 at 4:57 PM, Euler Taveira <euler@timbira.com.br> wrote:
    >> As Robert suggested in the other email: extension to create old names.
    
    > I don't follow the reasoning for the extension. It seem to have downsides
    > of both alternatives combined: we still break people's code, and we add
    > even more maintenance burden than just keeping aliases.
    
    Yeah, I'm not terribly for the extension idea.  Robert cited the precedent
    of contrib/tsearch2, but I think the history of that is a good argument
    against this: tsearch2 is still there 9 years later and there's no
    indication that we'll ever get rid of it.  We can let things rot
    indefinitely in core too.  If we do ever agree to get rid of the aliases,
    stripping them out of pg_proc.h will not be any harder than removing
    a contrib directory would be.
    
    			regards, tom lane
    
    
    
  52. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Jim Nasby <jim.nasby@bluetreble.com> — 2017-01-12T18:29:44Z

    On 1/12/17 10:12 AM, Tom Lane wrote:
    > Yeah, I'm not terribly for the extension idea.  Robert cited the precedent
    > of contrib/tsearch2, but I think the history of that is a good argument
    > against this: tsearch2 is still there 9 years later and there's no
    > indication that we'll ever get rid of it.  We can let things rot
    > indefinitely in core too.  If we do ever agree to get rid of the aliases,
    > stripping them out of pg_proc.h will not be any harder than removing
    > a contrib directory would be.
    
    Is there any burden to carrying tsearch2 around? Have we formally marked 
    it as deprecated?
    
    The way I see it, either one person can spend an hour or whatever 
    creating an extension once, or every postgres install that's using any 
    of these functions now has yet another hurdle to upgrading.
    
    If PGXN was better supported by the community maybe the answer would be 
    to just throw an extension up there. But that's certainly not the case.
    -- 
    Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
    Experts in Analytics, Data Architecture and PostgreSQL
    Data in Trouble? Get it in Treble! http://BlueTreble.com
    855-TREBLE2 (855-873-2532)
    
    
    
  53. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Kevin Grittner <kgrittn@gmail.com> — 2017-01-12T18:38:16Z

    On Thu, Jan 12, 2017 at 12:12 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Vladimir Rusinov <vrusinov@google.com> writes:
    >> On Thu, Jan 12, 2017 at 4:57 PM, Euler Taveira <euler@timbira.com.br> wrote:
    >>> As Robert suggested in the other email: extension to create old names.
    >
    >> I don't follow the reasoning for the extension. It seem to have downsides
    >> of both alternatives combined: we still break people's code, and we add
    >> even more maintenance burden than just keeping aliases.
    >
    > Yeah, I'm not terribly for the extension idea.  Robert cited the precedent
    > of contrib/tsearch2, but I think the history of that is a good argument
    > against this: tsearch2 is still there 9 years later and there's no
    > indication that we'll ever get rid of it.  We can let things rot
    > indefinitely in core too.  If we do ever agree to get rid of the aliases,
    > stripping them out of pg_proc.h will not be any harder than removing
    > a contrib directory would be.
    
    How about just leaving it to someone who cares about the aliases to
    post such an extension at pgxn.org (or anywhere else they like).
    It can be around as long as someone cares enough to maintain it.
    
    I guess that makes my vote -1 on aliases by the project.
    
    --
    Kevin Grittner
    EDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  54. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-12T18:40:50Z

    Jim,
    
    * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    > The way I see it, either one person can spend an hour or whatever
    > creating an extension once, or every postgres install that's using
    > any of these functions now has yet another hurdle to upgrading.
    
    I just don't buy this argument, at all.  These functions names are
    certainly not the only things we're changing with PG10 and serious
    monitoring/backup/administration tools are almost certainly going to
    have quite a bit to adjust to with the new release, and that isn't news
    to anyone who works with PG.
    
    Thanks!
    
    Stephen
    
  55. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-12T18:43:15Z

    On 2017-01-12 13:40:50 -0500, Stephen Frost wrote:
    > Jim,
    > 
    > * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    > > The way I see it, either one person can spend an hour or whatever
    > > creating an extension once, or every postgres install that's using
    > > any of these functions now has yet another hurdle to upgrading.
    > 
    > I just don't buy this argument, at all.  These functions names are
    > certainly not the only things we're changing with PG10 and serious
    > monitoring/backup/administration tools are almost certainly going to
    > have quite a bit to adjust to with the new release, and that isn't news
    > to anyone who works with PG.
    
    By that argument we can just do arbitrary backward incompat changes.  We
    should aspire to be better than we've been in the past, not use that
    past as an excuse for not even trying.
    
    Greetings,
    
    Andres Freund
    
    
    
  56. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-12T18:46:34Z

    Stephen Frost <sfrost@snowman.net> writes:
    > I just don't buy this argument, at all.  These functions names are
    > certainly not the only things we're changing with PG10 and serious
    > monitoring/backup/administration tools are almost certainly going to
    > have quite a bit to adjust to with the new release, and that isn't news
    > to anyone who works with PG.
    
    Hmm --- we've been conducting this argument in a vacuum, but you're right,
    we should consider what else is changing in v10.  If you can point to
    already-committed changes that mean that code using these functions will
    almost certainly need changes anyway for v10, then that would greatly
    weaken the argument for providing aliases.
    
    			regards, tom lane
    
    
    
  57. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-12T18:50:18Z

    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-12 13:40:50 -0500, Stephen Frost wrote:
    > > * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    > > > The way I see it, either one person can spend an hour or whatever
    > > > creating an extension once, or every postgres install that's using
    > > > any of these functions now has yet another hurdle to upgrading.
    > > 
    > > I just don't buy this argument, at all.  These functions names are
    > > certainly not the only things we're changing with PG10 and serious
    > > monitoring/backup/administration tools are almost certainly going to
    > > have quite a bit to adjust to with the new release, and that isn't news
    > > to anyone who works with PG.
    > 
    > By that argument we can just do arbitrary backward incompat changes.  We
    > should aspire to be better than we've been in the past, not use that
    > past as an excuse for not even trying.
    
    When they're changes that are primairly going to affect
    monitoring/backup/administration tools, yes, I do think we can make just
    about arbitrary backward-incompatible changes.
    
    As Robert mentioned, and I agree with, changing things which will impact
    regular application usage of PG is a different story and one we should
    be more cautious about.
    
    Thanks!
    
    Stephen
    
  58. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-12T18:52:36Z

    
    On January 12, 2017 10:50:18 AM PST, Stephen Frost <sfrost@snowman.net> wrote:
    >* Andres Freund (andres@anarazel.de) wrote:
    >> On 2017-01-12 13:40:50 -0500, Stephen Frost wrote:
    >> > * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    >> > > The way I see it, either one person can spend an hour or whatever
    >> > > creating an extension once, or every postgres install that's
    >using
    >> > > any of these functions now has yet another hurdle to upgrading.
    >> > 
    >> > I just don't buy this argument, at all.  These functions names are
    >> > certainly not the only things we're changing with PG10 and serious
    >> > monitoring/backup/administration tools are almost certainly going
    >to
    >> > have quite a bit to adjust to with the new release, and that isn't
    >news
    >> > to anyone who works with PG.
    >> 
    >> By that argument we can just do arbitrary backward incompat changes. 
    >We
    >> should aspire to be better than we've been in the past, not use that
    >> past as an excuse for not even trying.
    >
    >When they're changes that are primairly going to affect
    >monitoring/backup/administration tools, yes, I do think we can make
    >just
    >about arbitrary backward-incompatible changes.
    >
    >As Robert mentioned, and I agree with, changing things which will
    >impact
    >regular application usage of PG is a different story and one we should
    >be more cautious about.
    
    I find it very hard to understand the justification for that, besides that it's strengthening external projects providing monitoring, backup, etc in a compatible way.
    
    Andres
    
    -- 
    Sent from my Android device with K-9 Mail. Please excuse my brevity.
    
    
    
  59. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-12T19:01:21Z

    * Tom Lane (tgl@sss.pgh.pa.us) wrote:
    > Stephen Frost <sfrost@snowman.net> writes:
    > > I just don't buy this argument, at all.  These functions names are
    > > certainly not the only things we're changing with PG10 and serious
    > > monitoring/backup/administration tools are almost certainly going to
    > > have quite a bit to adjust to with the new release, and that isn't news
    > > to anyone who works with PG.
    > 
    > Hmm --- we've been conducting this argument in a vacuum, but you're right,
    > we should consider what else is changing in v10.  If you can point to
    > already-committed changes that mean that code using these functions will
    > almost certainly need changes anyway for v10, then that would greatly
    > weaken the argument for providing aliases.
    
    We changed the pg_xlog directory to be pg_wal, that's certainly going to
    have an impact on monitoring and backup tools.
    
    We've also made changes in, at least, what's reported in
    pg_stat_activity and there's been discussions about changing it further
    (list background workers or not, etc), and in pg_stat_replication (with
    the addition of quorum-based sync rep).  In fact, these kinds of changes
    are almost certainly going to require more work for tool authors to deal
    with than just a simple function name change.
    
    And that's only with a few minutes of looking at the commit log and I
    don't doubt that there's more and that we're going to have even more
    before feature freeze that a serious monitoring tool will have to be
    updated for.
    
    As long as we properly include these changes in the release notes for
    tool authors, I really don't see any of them as a big deal.
    
    Thanks!
    
    Stephen
    
  60. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-12T19:22:51Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > On January 12, 2017 10:50:18 AM PST, Stephen Frost <sfrost@snowman.net> wrote:
    > >* Andres Freund (andres@anarazel.de) wrote:
    > >> On 2017-01-12 13:40:50 -0500, Stephen Frost wrote:
    > >> > * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    > >> > > The way I see it, either one person can spend an hour or whatever
    > >> > > creating an extension once, or every postgres install that's
    > >using
    > >> > > any of these functions now has yet another hurdle to upgrading.
    > >> > 
    > >> > I just don't buy this argument, at all.  These functions names are
    > >> > certainly not the only things we're changing with PG10 and serious
    > >> > monitoring/backup/administration tools are almost certainly going
    > >to
    > >> > have quite a bit to adjust to with the new release, and that isn't
    > >news
    > >> > to anyone who works with PG.
    > >> 
    > >> By that argument we can just do arbitrary backward incompat changes. 
    > >We
    > >> should aspire to be better than we've been in the past, not use that
    > >> past as an excuse for not even trying.
    > >
    > >When they're changes that are primairly going to affect
    > >monitoring/backup/administration tools, yes, I do think we can make
    > >just
    > >about arbitrary backward-incompatible changes.
    > >
    > >As Robert mentioned, and I agree with, changing things which will
    > >impact
    > >regular application usage of PG is a different story and one we should
    > >be more cautious about.
    > 
    > I find it very hard to understand the justification for that, besides that it's strengthening external projects providing monitoring, backup, etc in a compatible way.
    
    That might be understandable if these were entirely arbitrary changes
    (which isn't actually what I'm talking about above), but they aren't.
    These changes aren't being made just for the sake of making them and are
    not entirely arbitrary, as I've already pointed out up-thread.
    
    The point I was making above is that the only reason to not make such
    changes is if they really are entirely arbitrary, but I don't think
    we'd even be having this discussion if that was the case or that we'd
    be split about the question.  We already moved forward with the real
    change here- pg_xlog -> pg_wal, it really astounds me that we're having
    to argue about what is primairly just clean-up from that change, at
    least in my view.
    
    Also, frankly, I don't agree with the notion that this is seriously
    going to "strengthen" external projects any more than the regular set of
    changes that we're making as we move forward.  Changing these functions
    certainly isn't likely to change pgbackrest or barman or check_postgres
    uptake any more than the pg_xlog -> pg_wal rename is going to.  Maybe if
    we *reverted* that change and then didn't make any other changes then
    various hand-written tools would be able to work with PG10 without being
    changed, but we might as well call it PG 9.6.2 then.
    
    Thanks!
    
    Stephen
    
  61. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-13T14:55:06Z

    On 1/12/17 1:40 PM, Stephen Frost wrote:
    > I just don't buy this argument, at all.  These functions names are
    > certainly not the only things we're changing with PG10 and serious
    > monitoring/backup/administration tools are almost certainly going to
    > have quite a bit to adjust to with the new release, and that isn't news
    > to anyone who works with PG.
    
    I in turn don't buy this argument. ;-)
    
    I have checked a variety of WAL-related monitoring scripts,
    graphing/trending scripts, switchover/failover scripts, and the like,
    and of course they all make ample use of a variety of *xlog* functions,
    but as far as I can tell, they don't care about the pg_xlog renaming and
    would continue to work just fine if the functions were not renamed.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  62. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-13T14:56:23Z

    On 1/12/17 1:50 PM, Stephen Frost wrote:
    > When they're changes that are primairly going to affect
    > monitoring/backup/administration tools, yes, I do think we can make just
    > about arbitrary backward-incompatible changes.
    
    I don't agree with that.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  63. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-13T15:00:19Z

    On 1/12/17 2:22 PM, Stephen Frost wrote:
    > The point I was making above is that the only reason to not make such
    > changes is if they really are entirely arbitrary, but I don't think
    > we'd even be having this discussion if that was the case or that we'd
    > be split about the question.  We already moved forward with the real
    > change here- pg_xlog -> pg_wal, it really astounds me that we're having
    > to argue about what is primairly just clean-up from that change, at
    > least in my view.
    
    I don't agree with the reasoning.  The change of the directory name was
    because some people erroneously delete the directory.  There is little
    to no risk that people accidentally delete built-in functions.  It was
    not agreed that because we rename the directory that all other uses of
    "xlog" have to be removed as well.  All those subsequent changes need to
    stand on their own.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  64. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-13T15:18:23Z

    * Peter Eisentraut (peter.eisentraut@2ndquadrant.com) wrote:
    > On 1/12/17 1:40 PM, Stephen Frost wrote:
    > > I just don't buy this argument, at all.  These functions names are
    > > certainly not the only things we're changing with PG10 and serious
    > > monitoring/backup/administration tools are almost certainly going to
    > > have quite a bit to adjust to with the new release, and that isn't news
    > > to anyone who works with PG.
    > 
    > I in turn don't buy this argument. ;-)
    > 
    > I have checked a variety of WAL-related monitoring scripts,
    > graphing/trending scripts, switchover/failover scripts, and the like,
    > and of course they all make ample use of a variety of *xlog* functions,
    > but as far as I can tell, they don't care about the pg_xlog renaming and
    > would continue to work just fine if the functions were not renamed.
    
    The point I was making was that serious montioring systems would have to
    be changed and I stand by that.  Sure, there are simple scripts out
    there that could, individually, continue to work fine using the old
    function names (unless and until we change some behavior of those- which
    I'm sure will end up happening at some point), but the argument being
    presented is that we shouldn't make people have to change and the only
    way to do that would be to revert the pg_xlog -> pg_wal change.
    
    Anything beyond that and we're into arguing about how *much* we should
    ask people to change, and for my 2c, that's barely even useful to
    discuss because once they have to make any change at all then the
    question will come up if it's "worth it" to move to the next version or
    the complaint about PG being too difficult to live with will be raised.
    I'm not terribly worried about such arguments because, put simply, PG10
    is going to have enough awesome features that it's an easy question to
    answer.
    
    The argument being presented here is that users won't mind that we
    changed the name of a critical directory for every PG system in
    existence, but they're going to be upset that we change a few function
    names to go along with that change.  Really?
    
    Certainly, check_postgres is going to have to be changed to address this
    and, unsurprisingly, it's already had to address a variety of major
    version differences that have been introduced over the years.
    
    Thanks!
    
    Stephen
    
  65. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-13T15:33:15Z

    * Peter Eisentraut (peter.eisentraut@2ndquadrant.com) wrote:
    > On 1/12/17 2:22 PM, Stephen Frost wrote:
    > > The point I was making above is that the only reason to not make such
    > > changes is if they really are entirely arbitrary, but I don't think
    > > we'd even be having this discussion if that was the case or that we'd
    > > be split about the question.  We already moved forward with the real
    > > change here- pg_xlog -> pg_wal, it really astounds me that we're having
    > > to argue about what is primairly just clean-up from that change, at
    > > least in my view.
    > 
    > I don't agree with the reasoning.  The change of the directory name was
    > because some people erroneously delete the directory.  There is little
    > to no risk that people accidentally delete built-in functions.  It was
    > not agreed that because we rename the directory that all other uses of
    > "xlog" have to be removed as well.  All those subsequent changes need to
    > stand on their own.
    
    The subsequent discussion about what to call the directory lead to a
    pretty clear winner that a better name is "wal", which fits in pretty
    nicely with things like "wal_level", "wal_sync_method", "wal_log_hints",
    section 19.5 of our documentation.  Try finding 'xlog' or even
    'transaction log' anywhere in our sample postgresql.conf, in fact.
    
    Look at our docs too, we talk about WAL a *great* deal more than we talk
    about 'xlog'.  Almost all utilization of 'xlog' that I see is due to
    some function or program name which was derived from the directory name,
    and half of those end up, confusingly, going back and forth between
    "WAL" and "transaction log" (the description of pg_receivexlog is a
    great example of this).
    
    In the end, while I don't agree that they really need to, it seems
    pretty clear to me that these changes can certainly stand on their own.
    The only reason they were ever called 'xlog' was because of the
    directory name and without that link, there's really no reason to keep
    mis-calling these functions 'xlog' *except* this claim that we don't
    want to break things, even though we're changing the directory name.
    
    Thanks!
    
    Stephen
    
  66. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-13T16:49:57Z

    On Thu, Jan 12, 2017 at 1:12 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Vladimir Rusinov <vrusinov@google.com> writes:
    >> On Thu, Jan 12, 2017 at 4:57 PM, Euler Taveira <euler@timbira.com.br> wrote:
    >>> As Robert suggested in the other email: extension to create old names.
    >
    >> I don't follow the reasoning for the extension. It seem to have downsides
    >> of both alternatives combined: we still break people's code, and we add
    >> even more maintenance burden than just keeping aliases.
    >
    > Yeah, I'm not terribly for the extension idea.  Robert cited the precedent
    > of contrib/tsearch2, but I think the history of that is a good argument
    > against this: tsearch2 is still there 9 years later and there's no
    > indication that we'll ever get rid of it.  We can let things rot
    > indefinitely in core too.  If we do ever agree to get rid of the aliases,
    > stripping them out of pg_proc.h will not be any harder than removing
    > a contrib directory would be.
    
    From a technical point of view, that is pretty much true.  But from a
    user perspective, I don't think it is.  If the old names live in an
    extension, then they will not be there by default.  Tools and scripts
    will break.  If that's a problem for a particular user, they an
    install the extension to unbreak those things, but tool authors will
    probably be motivated to upgrade their tools so that the extension is
    no longer needed.  Therefore, if we eventually drop the extension,
    there will probably be few users relying on it at that point.  On the
    other hand, if we install aliases that are present in every install -
    and that are not even optionally removable - a lot of people are not
    going to bother using the new names at all.  They'll just keep on
    using the old ones so that their tools work with both old and new
    versions, and if we eventually rip the stuff out of pg_proc.h it will
    cause almost as much howling as if we'd done it right at the
    beginning.
    
    In other words, adding an extension is the only option that I see
    which will give tool authors a strong incentive to support the new
    names without making it a hard requirement on day one.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  67. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-13T18:10:00Z

    Attached are two new version of the patch: one keeps aliases, one don't.
    Also, remove stray reference to xlog function in one of the tests.
    
    I've lost vote count. Should we create a form to calculate which one of the
    patches should be commited?
    
    If we decide to go the extension way, perhaps it can be maintained outside
    of core Postgres?
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  68. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Alvaro Herrera <alvherre@2ndquadrant.com> — 2017-01-13T19:13:46Z

    Robert Haas wrote:
    
    > From a technical point of view, that is pretty much true.  But from a
    > user perspective, I don't think it is.  If the old names live in an
    > extension, then they will not be there by default.  Tools and scripts
    > will break.  If that's a problem for a particular user, they an
    > install the extension to unbreak those things, but tool authors will
    > probably be motivated to upgrade their tools so that the extension is
    > no longer needed.  Therefore, if we eventually drop the extension,
    > there will probably be few users relying on it at that point.  On the
    > other hand, if we install aliases that are present in every install -
    > and that are not even optionally removable - a lot of people are not
    > going to bother using the new names at all.  They'll just keep on
    > using the old ones so that their tools work with both old and new
    > versions, and if we eventually rip the stuff out of pg_proc.h it will
    > cause almost as much howling as if we'd done it right at the
    > beginning.
    > 
    > In other words, adding an extension is the only option that I see
    > which will give tool authors a strong incentive to support the new
    > names without making it a hard requirement on day one.
    
    A compatibility extension sounds like a pretty decent idea to me,
    considering this point.  I think breakage without a workaround will
    cause people to defer migration more than they otherwise would; the
    extension gives them an easy way forward while they set up their
    internal code to the new reality, to test the other new things in pg10.
    
    If we keep the extension forever, so what?  It's not like tsearch2
    causes us too much of a maintenance pain.  It's been patched a few
    times, but only to change things that wouldn't need changes in a
    xlog->wal aliases-only module.  Anyway, I would mark the module as
    deprecated with an intent of removing it in half a dozen releases or so.
    
    -- 
    Álvaro Herrera                https://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  69. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Fujii Masao <masao.fujii@gmail.com> — 2017-01-17T03:48:19Z

    On Sat, Jan 14, 2017 at 3:10 AM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > Attached are two new version of the patch: one keeps aliases, one don't.
    > Also, remove stray reference to xlog function in one of the tests.
    >
    > I've lost vote count. Should we create a form to calculate which one of the
    > patches should be commited?
    
    If we do that, we should vote on all the "renaming" stuff, i.e., not only
    function names but also program names like pg_receivexlog, directory names
    like clog, option names like xlogdir option of initdb, return value names of
    the functions like xlog_position in pg_create_physical_replication_slot, etc.
    
    Regards,
    
    -- 
    Fujii Masao
    
    
    
  70. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-17T16:34:41Z

    On 1/13/17 10:18 AM, Stephen Frost wrote:
    > The point I was making was that serious montioring systems would have to
    > be changed and I stand by that.
    
    I don't think my monitoring systems are any less serious than yours.
    
    > Certainly, check_postgres is going to have to be changed to address this
    > and, unsurprisingly, it's already had to address a variety of major
    > version differences that have been introduced over the years.
    
    check_postgres will not need to be changed except for the actions that
    check the disk, which you don't need unless you are using archiving.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  71. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-17T16:44:49Z

    Peter,
    
    * Peter Eisentraut (peter.eisentraut@2ndquadrant.com) wrote:
    > On 1/13/17 10:18 AM, Stephen Frost wrote:
    > > Certainly, check_postgres is going to have to be changed to address this
    > > and, unsurprisingly, it's already had to address a variety of major
    > > version differences that have been introduced over the years.
    > 
    > check_postgres will not need to be changed except for the actions that
    > check the disk, which you don't need unless you are using archiving.
    
    That isn't really the point though, is it?  check_postgres will need to
    be changed because there are actions which check the pg_xlog directory.
    That'll cause a new release, which will be the "release that works with
    PG10."
    
    Perhaps if you're following along with -hackers and know how
    check_postgres works then you'll realize that you might not *have* to
    upgrade your check_postgres installation if only the directory is
    changed and nothing else is, but I've got a pretty hard time seeing that
    as a very common user use-case.
    
    The implication here seems to be that because the older version of
    check_postgres might appear to continue working for *some* set of
    actions (but not all) that we should encouarge users to keep using that
    older version with PG10.  That doesn't make any sense to me and I
    certainly don't agree with it.
    
    Thanks!
    
    Stephen
    
  72. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-17T22:03:20Z

    On Mon, Jan 16, 2017 at 10:48 PM, Fujii Masao <masao.fujii@gmail.com> wrote:
    > If we do that, we should vote on all the "renaming" stuff, i.e., not only
    > function names but also program names like pg_receivexlog, directory names
    > like clog, option names like xlogdir option of initdb, return value names of
    > the functions like xlog_position in pg_create_physical_replication_slot, etc.
    
    Right.  I think a lot of that stuff should also be changed.  If we
    weren't OK with breaking compatibility, why'd we change pg_xlog ->
    pg_wal?  If we're not willing to change other things to match, let's
    revert that change and be done with it.  It's undeniable that there's
    going to be some pain here and I'm not committed to incurring that
    pain, but I don't really understand the the theory that saying that a
    half-renaming will save us pain vs. a more through renaming.  If we
    change some things and not others, people will have to try to remember
    in which cases they now have to say xlog instead of wal and in which
    cases they still have to say xlog and (perhaps) in which cases they
    can choose either.  I think "xlog" is terrible naming; there is no
    universe in which "x" is a reasonable short-hand for either
    "transaction" or "write-ahead".
    
    Q: OK, where is my WAL stored?
    A: pg_wal
    Q: How do I reset it?
    A: pg_resetxlog
    Q: Why is it called pg_resetxlog?
    A: Because we call the transaction log "xlog".
    Q: Evidently you don't.
    A: Well, it used to be called pg_xlog prior to version 10, but then we
    renamed it, but the tool has still got the old name.
    Q: Are you kidding me?
    A: No.
    Q: Do you guys suck at picking names for things?
    A: Yes.
    Q: Wouldn't it at least be better to settle on ONE incomprehensible
    abbreviation for any given concept instead of having TWO DIFFERENT
    ONES?
    A: Hey, look at the time.
    
    If we don't make this all consistent, we'll be having that
    conversation -- or some variant of it -- forever.  There will be
    constant arguments about whether to give in and rename some more
    things.  The people who are now saying that we shouldn't break
    compatibility for this change (as if we haven't already) will be even
    less happy when they keep having to argue against breaking
    compatibility for the same thing a second time.
    
    I'm OK with continuing to use "xlog" as the user-facing name for the
    write-ahead log, and I am OK with switching to wal.  But leaving
    things in the halfway in-between state where they are right now seems
    like a mess.  It conveniences the people who happen to care about the
    names of the parts we haven't renamed yet but not the part we already
    did rename at the price of a permanent inconsistency in naming
    conventions that can't ever eliminate.  Yuck.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  73. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-17T22:10:47Z

    * Robert Haas (robertmhaas@gmail.com) wrote:
    > I'm OK with continuing to use "xlog" as the user-facing name for the
    > write-ahead log, and I am OK with switching to wal.  But leaving
    > things in the halfway in-between state where they are right now seems
    > like a mess.  It conveniences the people who happen to care about the
    > names of the parts we haven't renamed yet but not the part we already
    > did rename at the price of a permanent inconsistency in naming
    > conventions that can't ever eliminate.  Yuck.
    
    I'm more of a '-1' when it comes to keeping everything called "xlog",
    and a '+1' on renaming everything to be WAL, since that's what we
    usually refer to this thing as, but I agree with Robert that only doing
    a half-way renaming is about a -1000.
    
    Thanks!
    
    Stephen
    
  74. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-18T11:15:39Z

    On Tue, Jan 17, 2017 at 10:03 PM, Robert Haas <robertmhaas@gmail.com> wrote:
    
    > Q: OK, where is my WAL stored?
    > A: pg_wal
    > Q: How do I reset it?
    > A: pg_resetxlog
    >
    
    On the topic of binaries, there's going to be another patch renaming them.
    Those will have no aliases as it's trivial to work-around (symlinks, shell
    scripts, etc) and not so trivial to implement in a portable way.
    
    I'm used to workflows with lots of small commits, so I was not able to
    force myself to include all of the renames in one diff.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  75. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-18T12:28:53Z

    On Wed, Jan 18, 2017 at 8:15 PM, Vladimir Rusinov <vrusinov@google.com> wrote:
    > On the topic of binaries, there's going to be another patch renaming them.
    > Those will have no aliases as it's trivial to work-around (symlinks, shell
    > scripts, etc) and not so trivial to implement in a portable way.
    
    On Windows that would be a pain... So let's not use symlinks for binaries.
    
    > I'm used to workflows with lots of small commits, so I was not able to force
    > myself to include all of the renames in one diff.
    
    That's a good habit IMO.
    -- 
    Michael
    
    
    
  76. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-18T15:09:32Z

    On Wed, Jan 18, 2017 at 12:28 PM, Michael Paquier <michael.paquier@gmail.com
    > wrote:
    
    > On Wed, Jan 18, 2017 at 8:15 PM, Vladimir Rusinov <vrusinov@google.com>
    > wrote:
    > > On the topic of binaries, there's going to be another patch renaming
    > them.
    > > Those will have no aliases as it's trivial to work-around (symlinks,
    > shell
    > > scripts, etc) and not so trivial to implement in a portable way.
    >
    > On Windows that would be a pain... So let's not use symlinks for binaries.
    
    
    Just to be clear, I'm not proposing that we use symlinks. Just pointing out
    that workarounds are trivial for the end users.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  77. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Venkata B Nagothi <nag1010@gmail.com> — 2017-01-23T05:06:35Z

    On Sat, Jan 14, 2017 at 5:10 AM, Vladimir Rusinov <vrusinov@google.com>
    wrote:
    
    > Attached are two new version of the patch: one keeps aliases, one don't.
    >
    
    Both the patches (with and without aliases) are not getting applied to the
    latest master. Below is the error -
    
    Perhaps you used the wrong -p or --strip option?
    The text leading up to this was:
    --------------------------
    |diff --git a/src/include/access/xlog_fn.h b/src/include/access/xlog_fn.h
    |index a013d047a2..a46b2f995c 100644
    |--- a/src/include/access/xlog_fn.h
    |+++ b/src/include/access/xlog_fn.h
    --------------------------
    File to patch:
    
    
    Also, remove stray reference to xlog function in one of the tests.
    >
    > I've lost vote count. Should we create a form to calculate which one of
    > the patches should be commited?
    >
    > If we decide to go the extension way, perhaps it can be maintained outside
    > of core Postgres?
    >
    
    My take on having aliases to the functions :
    
    In my opinion as a DBA, I agree with having no-aliases. Having functions
    doing the same thing with two different names could be confusing. I have
    been doing quite a number of PostgreSQL upgrades since few years, i do not
    see, the function name changes as a major issue or a road-blocker in the
    upgrade exercise. If the function name has changed, it has changed. It
    would be a serious thing to consider during the upgrade if there is a
    change in the functionality of a particular function as it needs testing. I
    think, changing of the function names in the scripts and custom-tools has
    to be executed and might take up a bit of extra time.
    
    IMHO, It is not a good idea to keep aliases as this would make the DBAs
    lazier to change the function names on priority in the automated
    scripts/jobs/tools during the upgrades. Especially, in bigger and complex
    environments where-in database environments are handled by different
    multiple groups of DBAs, it could be possible that both *xlog* functions
    and *wal* functions will be used up in the scripts and all of them will be
    working fine and once the *xlog* functions names are completely removed,
    then some of the jobs/scripts start failing.
    
    I would vote for "no-aliases".
    
    Regards,
    Venkata Balaji N
    
    Database Consultant
    
  78. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-23T05:12:47Z

    On Mon, Jan 23, 2017 at 2:06 PM, Venkata B Nagothi <nag1010@gmail.com> wrote:
    >
    > On Sat, Jan 14, 2017 at 5:10 AM, Vladimir Rusinov <vrusinov@google.com>
    > wrote:
    >>
    >> Attached are two new version of the patch: one keeps aliases, one don't.
    >
    >
    > Both the patches (with and without aliases) are not getting applied to the
    > latest master. Below is the error -
    >
    > Perhaps you used the wrong -p or --strip option?
    > The text leading up to this was:
    > --------------------------
    > |diff --git a/src/include/access/xlog_fn.h b/src/include/access/xlog_fn.h
    > |index a013d047a2..a46b2f995c 100644
    > |--- a/src/include/access/xlog_fn.h
    > |+++ b/src/include/access/xlog_fn.h
    > --------------------------
    > File to patch:
    
    xlog_fn.h is not necessary anymore as all the declarations of
    functions defined in pg_proc.h are now generated automatically, so the
    conflict is simple enough to resolve.
    -- 
    Michael
    
    
    
  79. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-23T18:55:26Z

    On 1/17/17 5:03 PM, Robert Haas wrote:
    > Right.  I think a lot of that stuff should also be changed.  If we
    > weren't OK with breaking compatibility, why'd we change pg_xlog ->
    > pg_wal?  If we're not willing to change other things to match, let's
    > revert that change and be done with it.
    
    For the record, I don't like the name "xlog" either.  It would be nice
    if we could have more consistent and intuitive naming.
    
    But I don't see any proposals to actually change all uses of "xlog" to
    "wal".  What about program names, command line options, etc.?  If the
    argument is, we changed one thing, we should change the rest, then let's
    see that.  I think that argument itself is flawed, but if that's what
    we're going with, let's see the whole plan.
    
    Moreover, I see we still have the pg_clog directory.  I thought that was
    supposed to be renamed as well, to avoid confusing it with a "log"
    directory.  Surely, we should at least conclude that original chapter
    before going further.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  80. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-23T18:59:41Z

    Peter,
    
    * Peter Eisentraut (peter.eisentraut@2ndquadrant.com) wrote:
    > On 1/17/17 5:03 PM, Robert Haas wrote:
    > > Right.  I think a lot of that stuff should also be changed.  If we
    > > weren't OK with breaking compatibility, why'd we change pg_xlog ->
    > > pg_wal?  If we're not willing to change other things to match, let's
    > > revert that change and be done with it.
    > 
    > For the record, I don't like the name "xlog" either.  It would be nice
    > if we could have more consistent and intuitive naming.
    > 
    > But I don't see any proposals to actually change all uses of "xlog" to
    > "wal".  What about program names, command line options, etc.?  If the
    > argument is, we changed one thing, we should change the rest, then let's
    > see that.  I think that argument itself is flawed, but if that's what
    > we're going with, let's see the whole plan.
    
    That is the proposal and what Vladimir is working towards, as I
    understand it, but one piece at a time rather than one big huge patch,
    as he's already stated elsewhere on this thread.
    
    I don't have any problem with asking for a summary of the exact set of
    changes that he's planning to make though.  My understanding is that it
    includes changing program names, command line options, etc.
    
    > Moreover, I see we still have the pg_clog directory.  I thought that was
    > supposed to be renamed as well, to avoid confusing it with a "log"
    > directory.  Surely, we should at least conclude that original chapter
    > before going further.
    
    My understanding is that it is planned to be changed also, but it's
    backed up behind the sudden hang-up with making progress on the xlog ->
    WAL changes.
    
    I agree that we could probably just go ahead and switch over to starting
    on the clog changes (there was agreement somewhere about the new name
    for that too), but, well, if I was someone watching all of this
    discussion, I have to admit I probably wouldn't be too excited starting
    on another set of name changes with all of this going on.  Admittedly,
    the clog rename is a lot less user-facing and perhaps we should have
    started with it, but this is where we're at now.
    
    Thanks!
    
    Stephen
    
  81. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-24T04:45:38Z

    On Tue, Jan 24, 2017 at 3:59 AM, Stephen Frost <sfrost@snowman.net> wrote:
    > I agree that we could probably just go ahead and switch over to starting
    > on the clog changes (there was agreement somewhere about the new name
    > for that too), but, well, if I was someone watching all of this
    > discussion, I have to admit I probably wouldn't be too excited starting
    > on another set of name changes with all of this going on.  Admittedly,
    > the clog rename is a lot less user-facing and perhaps we should have
    > started with it, but this is where we're at now.
    
    There are no SQL-level functions and no binaries using the naming clog
    or subtrans, so that's a good anti-complain start.
    -- 
    Michael
    
    
    
  82. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-24T10:53:30Z

    On Mon, Jan 23, 2017 at 6:59 PM, Stephen Frost <sfrost@snowman.net> wrote:
    
    > > For the record, I don't like the name "xlog" either.  It would be nice
    > > if we could have more consistent and intuitive naming.
    > >
    > > But I don't see any proposals to actually change all uses of "xlog" to
    > > "wal".  What about program names, command line options, etc.?  If the
    > > argument is, we changed one thing, we should change the rest, then let's
    > > see that.  I think that argument itself is flawed, but if that's what
    > > we're going with, let's see the whole plan.
    >
    > That is the proposal and what Vladimir is working towards, as I
    > understand it, but one piece at a time rather than one big huge patch,
    > as he's already stated elsewhere on this thread.
    >
    
    Correct. Since fate of this patch is not fully decided I've paused my work
    on other things until this goes in in some form.
    
    
    > I don't have any problem with asking for a summary of the exact set of
    > changes that he's planning to make though.  My understanding is that it
    > includes changing program names, command line options, etc.
    >
    
    Here's what I currently have in mind:
    
    - sql function names (current patch)
    - binaries in bin: pg_receivexlog, pg_xlogdump, pg_resetxlog
    - (maybe) public/exported symbols from libpq,
    e.g. libpqGetCurrentXlogInsertLocation
    - at this time I don't target internal function and filenames, but that
    could also be done if there's desire for this.
    
    I'd like to have most user-visible changed checked in earlier. Stuff like
    internal refactoring can be done pretty much at any point in development
    cycle.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  83. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-24T18:59:08Z

    * Vladimir Rusinov (vrusinov@google.com) wrote:
    > On Mon, Jan 23, 2017 at 6:59 PM, Stephen Frost <sfrost@snowman.net> wrote:
    > > I don't have any problem with asking for a summary of the exact set of
    > > changes that he's planning to make though.  My understanding is that it
    > > includes changing program names, command line options, etc.
    > 
    > Here's what I currently have in mind:
    > 
    > - sql function names (current patch)
    > - binaries in bin: pg_receivexlog, pg_xlogdump, pg_resetxlog
    
    Command-line options for other binaries in bin should also be changed
    (eg: initdb's --xlogdir).
    
    Looking at the other binaries in src/bin:
    
    pg_archivecleanup - seems ok as-is (I'll note that it's Usage mentioned
                        'OLDESTKEPTWALFILE' ...)
    pg_basebackup - --xlog/--xlog-method/--xlogdir
    pgbench - looks fine
    pg_config - looks fine
    pg_controldata - looks fine
    pg_ctl - looks fine
    pgevent - DLL, not a binary, looks ok
    pg_rewind - looks fine
    pg_test_fsync - looks fine
    pg_test_timing - looks fine
    pg_upgrade - looks fine
    psql - looks fine
    
    > - (maybe) public/exported symbols from libpq,
    > e.g. libpqGetCurrentXlogInsertLocation
    
    Hm..?  That function is just a local function in pg_rewind.  I'd be kind
    of surprised if we actually had anything in libpq that needed changing
    due to this and I don't see anything there in a quick look.
    
    > - at this time I don't target internal function and filenames, but that
    > could also be done if there's desire for this.
    
    No, I don't think that'll be necessary.
    
    Thanks!
    
    Stephen
    
  84. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-24T21:47:29Z

    On Mon, Jan 23, 2017 at 1:55 PM, Peter Eisentraut
    <peter.eisentraut@2ndquadrant.com> wrote:
    > For the record, I don't like the name "xlog" either.  It would be nice
    > if we could have more consistent and intuitive naming.
    
    Great!
    
    > But I don't see any proposals to actually change all uses of "xlog" to
    > "wal".  What about program names, command line options, etc.?  If the
    > argument is, we changed one thing, we should change the rest, then let's
    > see that.  I think that argument itself is flawed, but if that's what
    > we're going with, let's see the whole plan.
    
    I'm happy to go change every last bit of it.  I was expecting after I
    committed the initial rename that somebody would provide a follow-on
    patch to do the rest of it in short order.  Instead, months went by
    and we still don't have a complete patch.  But I don't see why that
    has to take more than a day's work, probably just a few hours.  I'd
    like to do that and move on.
    
    > Moreover, I see we still have the pg_clog directory.  I thought that was
    > supposed to be renamed as well, to avoid confusing it with a "log"
    > directory.  Surely, we should at least conclude that original chapter
    > before going further.
    
    I'm not excited about starting to change pg_clog before we finish with
    xlog -> wal.  Then we just have two half-done things, IMO.  But I'm
    also not the only one with a commit bit.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  85. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T17:21:08Z

    On Tue, Jan 24, 2017 at 4:47 PM, Robert Haas <robertmhaas@gmail.com> wrote:
    >> But I don't see any proposals to actually change all uses of "xlog" to
    >> "wal".  What about program names, command line options, etc.?  If the
    >> argument is, we changed one thing, we should change the rest, then let's
    >> see that.  I think that argument itself is flawed, but if that's what
    >> we're going with, let's see the whole plan.
    >
    > I'm happy to go change every last bit of it.  I was expecting after I
    > committed the initial rename that somebody would provide a follow-on
    > patch to do the rest of it in short order.  Instead, months went by
    > and we still don't have a complete patch.  But I don't see why that
    > has to take more than a day's work, probably just a few hours.  I'd
    > like to do that and move on.
    
    And here are patches for that.
    
    0001 renames everything that contains "xlog" in pg_proc.h to refer to "wal".
    
    0002 renames programs whose names contains "xlog".
    
    0003 renames the dtrace probes whose names contain "xlog".
    
    0004 renames command line options which contain "xlog".
    
    There are probably a few more things that could be done afterwards to
    clean up other odds and ends, but I think this gets the vast bulk of
    the user-visible references to xlog.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
  86. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Alvaro Herrera <alvherre@2ndquadrant.com> — 2017-01-26T17:27:45Z

    Robert Haas wrote:
    
    > 0002 renames programs whose names contains "xlog".
    
    There have been complaints that pg_receivexlog's name is not consistent
    with pg_recvlogical, and I seem to recall there were some votes for
    renaming pg_receivexlog to match.  We could make it "pg_recvwal" now.
    
    -- 
    Álvaro Herrera                https://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  87. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T17:32:38Z

    On Thu, Jan 26, 2017 at 12:27 PM, Alvaro Herrera
    <alvherre@2ndquadrant.com> wrote:
    > Robert Haas wrote:
    >
    >> 0002 renames programs whose names contains "xlog".
    >
    > There have been complaints that pg_receivexlog's name is not consistent
    > with pg_recvlogical, and I seem to recall there were some votes for
    > renaming pg_receivexlog to match.  We could make it "pg_recvwal" now.
    
    Or prw.  :-)
    
    Personally, I generally push to avoid abbreviations like receive ->
    recv.  Yeah, it's a few extra characters of typing, but you can use
    tab completion so it's not really a big deal I think.  And the problem
    with abbreviating things is that people then have to remember whether
    it was abbreviated and in exactly which way.  "Wait, was it recv or
    rcv this time?"  Moreover, some of the abbreviations we've used are
    potentially opaque to non-English-speakers, or in some cases even to
    English speakers.  So I would prefer not to go there.  But if the
    consensus is otherwise, so be it.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  88. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-26T17:41:33Z

    Robert Haas <robertmhaas@gmail.com> writes:
    > On Thu, Jan 26, 2017 at 12:27 PM, Alvaro Herrera
    > <alvherre@2ndquadrant.com> wrote:
    >> There have been complaints that pg_receivexlog's name is not consistent
    >> with pg_recvlogical, and I seem to recall there were some votes for
    >> renaming pg_receivexlog to match.  We could make it "pg_recvwal" now.
    
    > ... I would prefer not to go there.
    
    I agree.  "pg_recvlogical" was a badly chosen name; let's not double
    down on the error.
    
    What I think might be worth considering is inserting underscores,
    eg "pg_receive_wal", anywhere that we are running the abbreviation
    directly against another word.  We won't get another chance.
    
    			regards, tom lane
    
    
    
  89. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-26T17:58:52Z

    * Tom Lane (tgl@sss.pgh.pa.us) wrote:
    > Robert Haas <robertmhaas@gmail.com> writes:
    > > On Thu, Jan 26, 2017 at 12:27 PM, Alvaro Herrera
    > > <alvherre@2ndquadrant.com> wrote:
    > >> There have been complaints that pg_receivexlog's name is not consistent
    > >> with pg_recvlogical, and I seem to recall there were some votes for
    > >> renaming pg_receivexlog to match.  We could make it "pg_recvwal" now.
    > 
    > > ... I would prefer not to go there.
    > 
    > I agree.  "pg_recvlogical" was a badly chosen name; let's not double
    > down on the error.
    > 
    > What I think might be worth considering is inserting underscores,
    > eg "pg_receive_wal", anywhere that we are running the abbreviation
    > directly against another word.  We won't get another chance.
    
    Wouldn't that make it 'pg_recv_wal'?  Or were you referring to the 'wal'
    as being the abbreviation?  Or did you mean underscores between words in
    general?
    
    If we want to switch to using underscores to seperate words, then that
    implies a whole lot of *additional* renaming that I'm not sure I can
    really get behind...
    
    initdb
    pg_archivecleanup
    pg_basebackup
    pgbench
    pg_controldata
    pgevent (eh, not really a binary, but it's in src/bin)
    pg_dumpall
    pg_isready
    
    All of those, to me at least seem fine, and I'd further be fine with
    "pg_receivewal".
    
    I haven't got any great answers wrt pg_recvlogical, though I don't
    particullarly like the existing name, but that's more because I have
    to ask myself how the heck one can receive a "logical"..
    
    Then again 'pg_controldata' only works if you realize it's really
    "pg_print_pg_control" or something.  It's hardly controlling any data.
    
    Thanks!
    
    Stephen
    
  90. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T18:09:45Z

    On Thu, Jan 26, 2017 at 12:41 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Robert Haas <robertmhaas@gmail.com> writes:
    >> On Thu, Jan 26, 2017 at 12:27 PM, Alvaro Herrera
    >> <alvherre@2ndquadrant.com> wrote:
    >>> There have been complaints that pg_receivexlog's name is not consistent
    >>> with pg_recvlogical, and I seem to recall there were some votes for
    >>> renaming pg_receivexlog to match.  We could make it "pg_recvwal" now.
    >
    >> ... I would prefer not to go there.
    >
    > I agree.  "pg_recvlogical" was a badly chosen name; let's not double
    > down on the error.
    >
    > What I think might be worth considering is inserting underscores,
    > eg "pg_receive_wal", anywhere that we are running the abbreviation
    > directly against another word.  We won't get another chance.
    
    Yeah, I thought about that, too, but it doesn't really seem worth it.
    If we had pg_receive_wal and pg_receive_logical, they'd be nicely
    consistent with each other, but inconsistent with practically every
    other utility we have: pg_basebackup, pg_archivecleanup,
    pg_controldata, etc.  I'm not prepared to endorse renaming all of that
    stuff just to add underscores, and frankly I don't think the style
    pg_foobarbaz is really a problem.  It's a lot easier to remember "the
    only underscore is after the initial pg" than it is to remember
    exactly how each word was abbreviated in each context.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  91. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-26T18:10:55Z

    Stephen Frost <sfrost@snowman.net> writes:
    > * Tom Lane (tgl@sss.pgh.pa.us) wrote:
    >> What I think might be worth considering is inserting underscores,
    >> eg "pg_receive_wal", anywhere that we are running the abbreviation
    >> directly against another word.  We won't get another chance.
    
    > Wouldn't that make it 'pg_recv_wal'?  Or were you referring to the 'wal'
    > as being the abbreviation?
    
    The latter.  As far as the programs go, that would be
    
    pg_receive_wal
    pg_reset_wal
    pg_wal_dump
    
    The other cases you mention are, for the most part, words that we're
    running together ("db" is the only exception) so they're not committing
    double sins against readability.  Anyway, I'm not suggesting that we
    should rename anything this patch isn't touching already.
    
    			regards, tom lane
    
    PS: I'm trying hard not to open the can of worms labeled "pg_dump_wal".
    
    
    
  92. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-26T18:14:59Z

    Robert Haas <robertmhaas@gmail.com> writes:
    > Yeah, I thought about that, too, but it doesn't really seem worth it.
    > If we had pg_receive_wal and pg_receive_logical, they'd be nicely
    > consistent with each other, but inconsistent with practically every
    > other utility we have: pg_basebackup, pg_archivecleanup,
    > pg_controldata, etc.
    
    Mmm, good point.  I was looking at pg_test_fsync and pg_test_timing,
    but those are the only exceptions, and they're only quasi-user-facing
    anyway.
    
    			regards, tom lane
    
    
    
  93. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T18:21:28Z

    On 2017-01-24 16:47:29 -0500, Robert Haas wrote:
    > I'm happy to go change every last bit of it.
    
    I quite regret not aggressively opining against the renaming of pg_xlog
    to pg_wal. I think the few users deleting their data don't weigh against
    renaming a bunch of tools and function for some sense of
    consistency. This will cause pain for a couple years - maybe it'll be
    worth it 6-7 releases down the line, but I doubt before that.  But then
    the original discussion was about renaming pg_xlog, not about a general
    s/xlog/$something/.
    
    - Andres
    
    
    
  94. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-26T18:26:10Z

    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-24 16:47:29 -0500, Robert Haas wrote:
    > > I'm happy to go change every last bit of it.
    > 
    > I quite regret not aggressively opining against the renaming of pg_xlog
    > to pg_wal. I think the few users deleting their data don't weigh against
    > renaming a bunch of tools and function for some sense of
    > consistency. This will cause pain for a couple years - maybe it'll be
    > worth it 6-7 releases down the line, but I doubt before that.  But then
    > the original discussion was about renaming pg_xlog, not about a general
    > s/xlog/$something/.
    
    For my 2c, I'm actually quite happy that we're finally going to start
    reducing the confusion between xlog and WAL.
    
    Let's not forget to go update the documentation to be sensible and
    consistent as we're making these mechanical changes to the program
    names.
    
    Thanks!
    
    Stephen
    
  95. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T19:05:43Z

    On Thu, Jan 26, 2017 at 1:21 PM, Andres Freund <andres@anarazel.de> wrote:
    > On 2017-01-24 16:47:29 -0500, Robert Haas wrote:
    >> I'm happy to go change every last bit of it.
    >
    > I quite regret not aggressively opining against the renaming of pg_xlog
    > to pg_wal. I think the few users deleting their data don't weigh against
    > renaming a bunch of tools and function for some sense of
    > consistency. This will cause pain for a couple years - maybe it'll be
    > worth it 6-7 releases down the line, but I doubt before that.  But then
    > the original discussion was about renaming pg_xlog, not about a general
    > s/xlog/$something/.
    
    I completely understand that position.  I have always been doubtful of
    the value of renaming pg_xlog to pg_wal, and I'm not any more
    dedicated to the idea now than I was when I committed that patch.  But
    there was overwhelming support for it, consensus on a level rarely
    seen here.
    
    I do not think it can be right to rename the directory and not
    anything else.  I stand by what I wrote in
    
    https://www.postgresql.org/message-id/CA+TgmobeHP2qbtMvYxG2x8Pm_9utjRya-rom5XL4QuyA26c1Gg@mail.gmail.com
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  96. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T19:13:39Z

    On 2017-01-26 14:05:43 -0500, Robert Haas wrote:
    > I completely understand that position.  I have always been doubtful of
    > the value of renaming pg_xlog to pg_wal, and I'm not any more
    > dedicated to the idea now than I was when I committed that patch.  But
    > there was overwhelming support for it, consensus on a level rarely
    > seen here.
    
    I think that consistency was based on the change being a narrow
    proposition, not a license to run around and change a lot of stuff
    including the names of binary.
    
    
    > I do not think it can be right to rename the directory and not
    > anything else.  I stand by what I wrote in
    > 
    > https://www.postgresql.org/message-id/CA+TgmobeHP2qbtMvYxG2x8Pm_9utjRya-rom5XL4QuyA26c1Gg@mail.gmail.com
    
    I'm tempted to quote Emerson ;).  I don't think the naming of pg_xlog
    vs. pg_wal doesn't actually have that large an impact, to change the
    dynamics of the wal vs xlog dichotomy.  Sure it's nothing you'd do in a
    new program, but neither is it very bad.
    
    Andres
    
    
    
  97. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David G. Johnston <david.g.johnston@gmail.com> — 2017-01-26T19:23:24Z

    On Thu, Jan 26, 2017 at 12:13 PM, Andres Freund <andres@anarazel.de> wrote:
    
    > On 2017-01-26 14:05:43 -0500, Robert Haas wrote:
    > > I completely understand that position.  I have always been doubtful of
    > > the value of renaming pg_xlog to pg_wal, and I'm not any more
    > > dedicated to the idea now than I was when I committed that patch.  But
    > > there was overwhelming support for it, consensus on a level rarely
    > > seen here.
    >
    > I think that consistency was based on the change being a narrow
    > proposition, not a license to run around and change a lot of stuff
    > including the names of binary.
    >
    >
    ​Whether the voters recognized that fact at the time I would have to concur
    that if we are going to change from xlog to wal we​ should be all-in.  If
    you want to vote to reject putting the whole camel in the tent I would say
    its a vote for reverting the change that put the camel's nose in there in
    the first place.
    
    https://en.wikipedia.org/wiki/Camel's_nose
    
    
    > > I do not think it can be right to rename the directory and not
    > > anything else.  I stand by what I wrote in
    > >
    > > https://www.postgresql.org/message-id/CA+TgmobeHP2qbtMvYxG2x8Pm_
    > 9utjRya-rom5XL4QuyA26c1Gg@mail.gmail.com
    >
    > I'm tempted to quote Emerson ;).  I don't think the naming of pg_xlog
    > vs. pg_wal doesn't actually have that large an impact, to change the
    > dynamics of the wal vs xlog dichotomy.  Sure it's nothing you'd do in a
    > new program, but neither is it very bad.
    >
    
    ​Once I learned what "write ahead log" was it wasn't that big a deal to
    understand that this particular historical implementation detail ​means I
    have to associate xlog with it.  Causing wide-spread pain to lower the
    comprehension bar doesn't seems like a simple win here.  I have no real
    feel for how wide-spread that would be, though.  I personally wouldn't mind
    it being consistent but I am not representative of the larger user base.
    
    David J.
    
  98. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T19:24:30Z

    On 2017-01-26 12:23:24 -0700, David G. Johnston wrote:
    > On Thu, Jan 26, 2017 at 12:13 PM, Andres Freund <andres@anarazel.de> wrote:
    > 
    > > On 2017-01-26 14:05:43 -0500, Robert Haas wrote:
    > > > I completely understand that position.  I have always been doubtful of
    > > > the value of renaming pg_xlog to pg_wal, and I'm not any more
    > > > dedicated to the idea now than I was when I committed that patch.  But
    > > > there was overwhelming support for it, consensus on a level rarely
    > > > seen here.
    > >
    > > I think that consistency was based on the change being a narrow
    > > proposition, not a license to run around and change a lot of stuff
    > > including the names of binary.
    > >
    > >
    > ​Whether the voters recognized that fact at the time I would have to concur
    > that if we are going to change from xlog to wal we​ should be all-in.  If
    > you want to vote to reject putting the whole camel in the tent I would say
    > its a vote for reverting the change that put the camel's nose in there in
    > the first place.
    
    WTF.
    
    
    
  99. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T19:26:36Z

    On Thu, Jan 26, 2017 at 2:13 PM, Andres Freund <andres@anarazel.de> wrote:
    > On 2017-01-26 14:05:43 -0500, Robert Haas wrote:
    >> I completely understand that position.  I have always been doubtful of
    >> the value of renaming pg_xlog to pg_wal, and I'm not any more
    >> dedicated to the idea now than I was when I committed that patch.  But
    >> there was overwhelming support for it, consensus on a level rarely
    >> seen here.
    >
    > I think that consistency was based on the change being a narrow
    > proposition, not a license to run around and change a lot of stuff
    > including the names of binary.
    
    I'm not so sure about that.  There are a lot of people who have
    supported the idea of making this consistent on THIS thread.  It's not
    clear how much of a majority there is, but it's certainly no worse
    than 50-50.  It's got far more affirmative votes than most patches
    that go in though, I will grant, also far more negative votes.
    
    >> I do not think it can be right to rename the directory and not
    >> anything else.  I stand by what I wrote in
    >>
    >> https://www.postgresql.org/message-id/CA+TgmobeHP2qbtMvYxG2x8Pm_9utjRya-rom5XL4QuyA26c1Gg@mail.gmail.com
    >
    > I'm tempted to quote Emerson ;).  I don't think the naming of pg_xlog
    > vs. pg_wal doesn't actually have that large an impact, to change the
    > dynamics of the wal vs xlog dichotomy.  Sure it's nothing you'd do in a
    > new program, but neither is it very bad.
    
    Gee, I can't imagine what Emerson quote you might be thinking about.  :-)
    
    I think it's just never going to work to imagine that we can
    indefinitely go on having a pg_resetxlog binary to reset a thing that
    is no longer called xlog.  Sure, for a few years that will seem like
    it makes sense, but if we didn't change it now, eventually there would
    be a push to do it later.  And if that one gets shut down, there will
    eventually be another push.  We'll repeatedly relitigate this whole
    debate, and maybe eventually the result will be one or two more things
    get changed ... and then later we'll do it again for what's left.  I
    am not entirely excited about the backward-compatibility pain we're
    incurring here, but I think if we don't do it all at once it's just
    going to get spread out over time.  Maybe it in a universe where
    PostgreSQL was controlled by a small number of people acting as one
    you could hold the line, but in the actual universe people just keep
    calling a vote on this sort of thing every two or three until they
    win.  I don't think there's anything you or I or anyone else can say
    or do that will prevent that from happening, so I'd as soon just be
    done with it.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  100. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T19:28:01Z

    On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de> wrote:
    >> Whether the voters recognized that fact at the time I would have to concur
    >> that if we are going to change from xlog to wal we should be all-in.  If
    >> you want to vote to reject putting the whole camel in the tent I would say
    >> its a vote for reverting the change that put the camel's nose in there in
    >> the first place.
    >
    > WTF.
    
    I think that response is unwarranted.  I happen to agree entirely with
    his position.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  101. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T19:37:07Z

    On 2017-01-26 14:28:01 -0500, Robert Haas wrote:
    > On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de> wrote:
    > >> Whether the voters recognized that fact at the time I would have to concur
    > >> that if we are going to change from xlog to wal we should be all-in.  If
    > >> you want to vote to reject putting the whole camel in the tent I would say
    > >> its a vote for reverting the change that put the camel's nose in there in
    > >> the first place.
    > >
    > > WTF.
    > 
    > I think that response is unwarranted.  I happen to agree entirely with
    > his position.
    
    I don't. Considering intent imo is important. David (and you?) is
    basically saying "screw it, you voted for that person, you aren't
    allowed to have an opinion anymore", and that's way outside of what I
    consider acceptable.  So, because you think it doesn't make sense to
    view renaming pg_xlog vs pg_wal as separate from a global s/xlog/wal/,
    nobody else can have that position.  And on top of that David's
    underlying that argument with a metaphor that basically implies the
    other party is getting screwed over.  Sorry, that's not the way I want
    decisions to be made here.
    
    Andres
    
    
    
  102. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-01-26T19:43:14Z

    Robert Haas <robertmhaas@gmail.com> writes:
    > On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de> wrote:
    >>> Whether the voters recognized that fact at the time I would have to concur
    >>> that if we are going to change from xlog to wal we should be all-in.  If
    >>> you want to vote to reject putting the whole camel in the tent I would say
    >>> its a vote for reverting the change that put the camel's nose in there in
    >>> the first place.
    
    >> WTF.
    
    > I think that response is unwarranted.  I happen to agree entirely with
    > his position.
    
    Me three.  If we're changing this at all, we should try to eliminate
    "xlog" from user-visible names and docs altogether.  I was okay with the
    proposal to have some redundant names in place for awhile, and I'm equally
    okay with not having any; but not with being permanently schizophrenic
    on the point.
    
    			regards, tom lane
    
    
    
  103. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David G. Johnston <david.g.johnston@gmail.com> — 2017-01-26T20:07:12Z

    On Thu, Jan 26, 2017 at 12:37 PM, Andres Freund <andres@anarazel.de> wrote:
    
    > On 2017-01-26 14:28:01 -0500, Robert Haas wrote:
    > > On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de>
    > wrote:
    > > >> Whether the voters recognized that fact at the time I would have to
    > concur
    > > >> that if we are going to change from xlog to wal we should be all-in.
    > If
    > > >> you want to vote to reject putting the whole camel in the tent I
    > would say
    > > >> its a vote for reverting the change that put the camel's nose in
    > there in
    > > >> the first place.
    > > >
    > > > WTF.
    > >
    > > I think that response is unwarranted.  I happen to agree entirely with
    > > his position.
    >
    > I don't. Considering intent imo is important. David (and you?) is
    > basically saying "screw it, you voted for that person, you aren't
    > allowed to have an opinion anymore", and that's way outside of what I
    > consider acceptable.  So, because you think it doesn't make sense to
    > view renaming pg_xlog vs pg_wal as separate from a global s/xlog/wal/,
    > nobody else can have that position.  And on top of that David's
    > underlying that argument with a metaphor that basically implies the
    > other party is getting screwed over.  Sorry, that's not the way I want
    > decisions to be made here.
    >
    
    We can think or assume all we want about what people knew or did not know
    when the prior consensus to commit the directory change was reached.  At
    this point it doesn't matter.  The limited point I was trying to make is
    that "the small change (i.e., the camel's nose) has been made (i.e., is now
    in the tent)".  Yet here we are talking about the rest of the  camel.  We
    have three options: go all-in, leave the status-quo, undo the previous
    action.
    
    The past decision is immaterial and any knowledge/experience/opinions that
    it may have entailed can now, on an individual basis, be neatly wrapped up
    into a vote on one of those options.  No need to make assumptions about
    how/why consensus on the previous decision was reached.  And, to be fair,
    it is not an unreasonable assumption for Robert to make that having voted
    for the small action that most of the well-informed persons on this list
    were aware and implicitly understood that the underlying intent was not the
    directory but rather removing "xlog" from our vocabulary and replacing it
    with the more accurate "wal".  In that vein assumed consensus makes sense.
    
    I didn't give as much credence to the "status quo" option in my original
    response as I probably should have - because, frankly, I find it
    unappealing.  I do accept that it is a valid position to hold, though.
    
    David J.
    
  104. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Joshua D. Drake <jd@commandprompt.com> — 2017-01-26T20:13:09Z

    -Hackers,
    
     From the field. I do not care what you chose, I care that:
    
    1. It is consistent
    2. It is readable/understandable
    3. It is documented
    4. It is done wholesale (because of usability)
    
    That's it. So whatever meets that criteria, let's go for it. That may 
    mean that certain commands look a little off but with the goal of 
    consistency that is o.k.. It becomes explainable.
    
    JD
    
    -- 
    Command Prompt, Inc.                  http://the.postgres.company/
                             +1-503-667-4564
    PostgreSQL Centered full stack support, consulting and development.
    Everyone appreciates your honesty, until you are honest with them.
    
    
    
  105. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-01-26T21:55:37Z

    On Thu, Jan 26, 2017 at 2:37 PM, Andres Freund <andres@anarazel.de> wrote:
    > On 2017-01-26 14:28:01 -0500, Robert Haas wrote:
    >> On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de> wrote:
    >> >> Whether the voters recognized that fact at the time I would have to concur
    >> >> that if we are going to change from xlog to wal we should be all-in.  If
    >> >> you want to vote to reject putting the whole camel in the tent I would say
    >> >> its a vote for reverting the change that put the camel's nose in there in
    >> >> the first place.
    >> >
    >> > WTF.
    >>
    >> I think that response is unwarranted.  I happen to agree entirely with
    >> his position.
    >
    > I don't. Considering intent imo is important. David (and you?) is
    > basically saying "screw it, you voted for that person, you aren't
    > allowed to have an opinion anymore", and that's way outside of what I
    > consider acceptable.  So, because you think it doesn't make sense to
    > view renaming pg_xlog vs pg_wal as separate from a global s/xlog/wal/,
    > nobody else can have that position.  And on top of that David's
    > underlying that argument with a metaphor that basically implies the
    > other party is getting screwed over.  Sorry, that's not the way I want
    > decisions to be made here.
    
    I'm not saying that people aren't allowed to have an opinion any more.
    I'm saying that when somebody has an opinion that is different than
    yours, you should politely disagree with it rather than saying "WTF",
    which just as a reminder expands to "What The Fuck".  Frankly, I think
    WTF is generally not a particularly useful contribution to most
    discussions, but at the very least I think it should be used with some
    kind of context.  Sending an email that says "WTF" and nothing else
    conveys nothing other than that you don't respect the author of the
    email to which you are replying, and David's response was not so
    outlandish as to deserve that.  You might as well send an email that
    says "go dire in a fire".
    
    The substantive issue here is whether we should go forward with this
    change, back out the change we already did, or leave things as they
    are.  Tom, David, and I seem to be in lock step on at least the
    following conclusion: halfway in between is bad.  So I have every
    intention of continuing to push very hard for us to go either forward
    or backward.  I hope to do that politely and respectfully, but I am
    not prepared to give up on that basic point unless there are a WHOLE
    LOT of contrary votes, and that is just not where we are at present.
    While a variety of opinions have been expressed on the patch
    originally posted and while many of those people took subtly different
    positions which I'm unable to summarize concisely, there was ZERO
    pushback against my email volunteering to go make all of this
    consistent and pushing for it to be made consistent until you showed
    up to complain.  Now there is one person objecting and several people
    in favor, and I think it is pretty fair to say that many of the people
    who were arguing for Vladimir's original patch are still in favor of
    proceeding.  Even Peter, who wasn't super-excited about Vladimir's
    patch in isolation, conceded that the xlog terminology sucked and
    asked for a complete patch set.  I don't think he's unequivocally in
    favor of this, but he seemed to be willing to sit still for it.  After
    waiting two days for further opinions, I went and wrote the patches as
    promised.
    
    And I think that's all pretty reasonable.  I don't consider this a
    done deal yet.  I don't consider your -1 irrelevant.  But I don't
    think it's fair to present this as if I am somehow running roughshod
    over community process, either.  If a large crew of people show up to
    insist that we should rename only the directories and nothing else, I
    guess I'll have to live with that.  But I think that's a bad decision
    that will never survive the passage of time, and there seem to be
    several people who agree with me.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  106. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-26T22:07:57Z

    * Robert Haas (robertmhaas@gmail.com) wrote:
    > And I think that's all pretty reasonable.  I don't consider this a
    > done deal yet.  I don't consider your -1 irrelevant.  But I don't
    > think it's fair to present this as if I am somehow running roughshod
    > over community process, either.  If a large crew of people show up to
    > insist that we should rename only the directories and nothing else, I
    > guess I'll have to live with that.  But I think that's a bad decision
    > that will never survive the passage of time, and there seem to be
    > several people who agree with me.
    
    +1 (to the above, and the rest of Robert's comments on that email).
    
    For my 2c, I'm also in the crowd of forward or back, but don't leave it
    half-done.  My preference is certainly to move forward with these
    changes, but I understand the process and if there's enough agreement
    that we just shouldn't make these changes, then we really shouldn't make
    any of them.
    
    Thanks!
    
    Stephen
    
  107. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-01-26T22:18:26Z

    On 1/26/17 5:07 PM, Stephen Frost wrote:
    > * Robert Haas (robertmhaas@gmail.com) wrote:
    >> And I think that's all pretty reasonable.  I don't consider this a
    >> done deal yet.  I don't consider your -1 irrelevant.  But I don't
    >> think it's fair to present this as if I am somehow running roughshod
    >> over community process, either.  If a large crew of people show up to
    >> insist that we should rename only the directories and nothing else, I
    >> guess I'll have to live with that.  But I think that's a bad decision
    >> that will never survive the passage of time, and there seem to be
    >> several people who agree with me.
    > 
    > +1 (to the above, and the rest of Robert's comments on that email).
    > 
    > For my 2c, I'm also in the crowd of forward or back, but don't leave it
    > half-done.  My preference is certainly to move forward with these
    > changes, but I understand the process and if there's enough agreement
    > that we just shouldn't make these changes, then we really shouldn't make
    > any of them.
    
    +1 for forward or back.  I prefer forward but would take back over the
    state we're in now.
    
    -- 
    -David
    david@pgmasters.net
    
    
  108. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T22:28:33Z

    On 2017-01-26 16:55:37 -0500, Robert Haas wrote:
    > On Thu, Jan 26, 2017 at 2:37 PM, Andres Freund <andres@anarazel.de> wrote:
    > > On 2017-01-26 14:28:01 -0500, Robert Haas wrote:
    > >> On Thu, Jan 26, 2017 at 2:24 PM, Andres Freund <andres@anarazel.de> wrote:
    > >> >> Whether the voters recognized that fact at the time I would have to concur
    > >> >> that if we are going to change from xlog to wal we should be all-in.  If
    > >> >> you want to vote to reject putting the whole camel in the tent I would say
    > >> >> its a vote for reverting the change that put the camel's nose in there in
    > >> >> the first place.
    > >> >
    > >> > WTF.
    > >>
    > >> I think that response is unwarranted.  I happen to agree entirely with
    > >> his position.
    > >
    > > I don't. Considering intent imo is important. David (and you?) is
    > > basically saying "screw it, you voted for that person, you aren't
    > > allowed to have an opinion anymore", and that's way outside of what I
    > > consider acceptable.  So, because you think it doesn't make sense to
    > > view renaming pg_xlog vs pg_wal as separate from a global s/xlog/wal/,
    > > nobody else can have that position.  And on top of that David's
    > > underlying that argument with a metaphor that basically implies the
    > > other party is getting screwed over.  Sorry, that's not the way I want
    > > decisions to be made here.
    >
    > I'm not saying that people aren't allowed to have an opinion any more.
    > I'm saying that when somebody has an opinion that is different than
    > yours, you should politely disagree with it rather than saying "WTF",
    > which just as a reminder expands to "What The Fuck".  Frankly, I think
    > WTF is generally not a particularly useful contribution to most
    > discussions, but at the very least I think it should be used with some
    > kind of context.  Sending an email that says "WTF" and nothing else
    > conveys nothing other than that you don't respect the author of the
    > email to which you are replying, and David's response was not so
    > outlandish as to deserve that.  You might as well send an email that
    > says "go dire in a fire".
    
    The WTF wasn't about David wanting to go all in or not, but the way he
    framed the general discussion.  And I do find it outlandish enough to
    deserve that.  To me, especially with that methaphor and link, it still
    reads as "you voted for it, even if phrased a lot more narrowly, so you
    now get to eat all of it". *Especially* as it's a reply to me saying
    that I'm concerned about my tepid yes to s/pg_xlog/pg_wal/ being used
    for a larger change.
    
    Using the normal ~concensus type of process for a mildly controversial
    breaking change is fine with me.  I *personally* don't think it's worth
    changing all this without taking more care about backward compat than
    we're apparently willing to do.  I'm ok with loosing that argument.  I
    just don't think the previous concensus for a narrower change can be
    used for the wider one.
    
    Andres
    
    
    
  109. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David G. Johnston <david.g.johnston@gmail.com> — 2017-01-26T22:45:15Z

    On Thu, Jan 26, 2017 at 3:28 PM, Andres Freund <andres@anarazel.de> wrote:
    
    > I *personally* don't think it's worth
    > changing all this without taking more care about backward compat than
    > we're apparently willing to do.  I'm ok with loosing that argument.  I
    > just don't think the previous concensus for a narrower change can be
    > used for the wider one
    > ​.
    >
    
    ​It would probably help others if you could brain dump a bit as to the
    benefit of the status-quo compared to both the 9.6 behavior and the all-in
    one.
    
    Honestly, the reference to the camel sticking their nose in a tent was
    supposed to be taken humorously, the serious explanation that it meant to
    convey was already very well presented by Robert.  The only reason I added
    the wiki link was to give those who would have no clue about the metaphor a
    chance at understanding it.
    
    I actually took your response as:  "why the f**k is he talking about
    camels?" and started laughing...
    
    Dave
    
  110. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-26T23:19:04Z

    On 2017-01-26 15:45:15 -0700, David G. Johnston wrote:
    > On Thu, Jan 26, 2017 at 3:28 PM, Andres Freund <andres@anarazel.de> wrote:
    >
    > > I *personally* don't think it's worth
    > > changing all this without taking more care about backward compat than
    > > we're apparently willing to do.  I'm ok with loosing that argument.  I
    > > just don't think the previous concensus for a narrower change can be
    > > used for the wider one
    > > ​.
    > >
    >
    > ​It would probably help others if you could brain dump a bit as to the
    > benefit of the status-quo compared to both the 9.6 behavior and the all-in
    > one.
    
    Well, I think I've lost that argument, so I'm not sure how much effort
    we should spent on litigating my opinion on it.  But here we go:
    
    As I said somewhere upthread (when discussing the function names), I
    think we're playing it too fast and loose with unnecessary changes.
    
    We decided s/pg_xlog/pg_wal/ was necessary because people lost their
    data, and we couldn't come up with a reasonable way to change it without
    the name. The tradeoff is dataloss vs. dealing with directory renaming
    in a few lowlevel tools.  So we decided to change the name.  It seems
    breakage was unavoidable.
    
    For me the renaming of functions, binaries, etc, is different because
    the benefit is long-term avoidance of a bit of confusion, with the
    shorter term price being tool breakages and confusion because
    documentation/guides/... for different versions don't apply anymore, and
    the search terms don't help anymore.  But we're still changing this,
    even though breakage seems avoidable.
    
    
    And that fits into the bigger topic of us doing minor cleanups without a
    lot of concern for backward compatibility, e.g. like us whacking things
    around in pg_stat_activity for most of the last releases - nearly all of
    those could have been done in a compatible manner, without even smelling
    that badly.
    
    I hear these complaints about postgres most frequently: 1) replication
    sucks. 2) way too slow on analytics queries. 3) existing admin tools
    suck. 4) self written admin tools (required due to 3)) constantly break.
    
    There's a lot being done on 1) and 2). There's very little in-core
    progress about 3). We're getting worse on 4).
    
    
    > I actually took your response as: "why the f**k is he talking about
    > camels?" and started laughing...
    
    That's good then, and let's raise a $beverage_of_choice tonight to the
    fallability of e-mail conversation ;)
    
    
    Andres
    
    
    
  111. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David G. Johnston <david.g.johnston@gmail.com> — 2017-01-26T23:58:39Z

    On Thu, Jan 26, 2017 at 4:19 PM, Andres Freund <andres@anarazel.de> wrote:
    
    >
    > We decided s/pg_xlog/pg_wal/ was necessary because people lost their
    > data, and we couldn't come up with a reasonable way to change it without
    > the name. The tradeoff is dataloss vs. dealing with directory renaming
    > in a few lowlevel tools.  So we decided to change the name.  It seems
    > breakage was unavoidable.
    >
    > For me the renaming of functions, binaries, etc, is different because
    > the benefit is long-term avoidance of a bit of confusion, with the
    > shorter term price being tool breakages and confusion because
    > documentation/guides/... for different versions don't apply anymore, and
    > the search terms don't help anymore.  But we're still changing this,
    > even though breakage seems avoidable.
    >
    
    Well stated and compelling.
    ​
    
    >
    > And that fits into the bigger topic of us doing minor cleanups without a
    > lot of concern for backward compatibility, e.g. like us whacking things
    > around in pg_stat_activity for most of the last releases - nearly all of
    > those could have been done in a compatible manner, without even smelling
    > that badly.
    >
    > I hear these complaints about postgres most frequently: 1) replication
    > sucks. 2) way too slow on analytics queries. 3) existing admin tools
    > suck. 4) self written admin tools (required due to 3)) constantly break.
    >
    > There's a lot being done on 1) and 2). There's very little in-core
    > progress about 3). We're getting worse on 4).
    >
    
    ​I would posit, broadly, and without any evidence, that changes like we are
    discussing here, will go toward helping on 3 since (hopefully) as
    PostgreSQL becomes a more appealing option in the marketplace more quality
    developers will be drawn toward using their skills to improve its
    ecosystem.  Mandating uniformity in areas like this speaks toward
    professionalism.
    
    Given that "there's a lot being done on #1" it would seem that right now is
    an excellent time to make these changes - so that the new guides and tools
    that leverage those enhancements can use the WAL terminology and have its
    presence be consistently present throughout the system.
    
    If there was a reasonably short horizon for features or capabilities that
    make this kind of renaming breaking easier to accommodate I would say we
    could probably wait for it to be completed first.  But AFAIK there isn't
    anything in the works that would allow individual users to easily enable a
    backward-compatibility mode for the mid-level API that we are largely
    touching here.
    
    It may be that this is a straw that breaks the camel's back for some users
    of PostgreSQL who are fed up with #4 ... I don't know ... but I'm
    reasonably confident that new users a couple of years from now would have a
    better experience with our product with these changes in place.  Its an
    aggressive play for growth - and that entails risk and upsetting those
    invested in the status-quo (which are are already doing per your #1).
    
    David J.
    
  112. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-27T00:01:54Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > I hear these complaints about postgres most frequently: 1) replication
    > sucks. 2) way too slow on analytics queries. 3) existing admin tools
    > suck. 4) self written admin tools (required due to 3)) constantly break.
    > 
    > There's a lot being done on 1) and 2). There's very little in-core
    > progress about 3). We're getting worse on 4).
    
    I certainly hear some of these complaints also, and I'd love it if '3'
    were something that the project was focused on, but, well, I really
    don't see pgAdmin ever being in core, and 99% of the time that I'm
    talking to end users, that's really what they're looking for (or, well,
    something like it).  I don't recall, off-hand at least, ever running
    into a user complaining that their pgAdmin-like admin tool broke.
    
    I have doubts that we could even get something like check_postgres or
    another monitoring type of tool into core, though it would be sooooo
    nice to have tight integration between montioring and the core code.
    That would require some kind of pluggable system which could support the
    montioring-of-the-day and an easy way to extend it and a way to set up
    what should be monitored and what shouldn't along with something to
    actually gather that info while the system is running (eg: a background
    worker of some kind), or at least, those are my general thoughts.
    
    Maybe we'll get to the point where we'd have a fully-baked, featureful
    backup solution that works with large-scale systems in core; I've at
    least got some hopes of that happening, but not any particular timeline
    or expectation of it happening soon.
    
    Having a good way to do logging of different levels to different
    locations would also be really nice, because our current logging
    situation is really rather terrible.
    
    > > I actually took your response as: "why the f**k is he talking about
    > > camels?" and started laughing...
    > 
    > That's good then, and let's raise a $beverage_of_choice tonight to the
    > fallability of e-mail conversation ;)
    
    Hah, now that I can certainly agree with..
    
    Thanks!
    
    Stephen
    
  113. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-27T00:09:24Z

    On 2017-01-26 19:01:54 -0500, Stephen Frost wrote:
    > Andres,
    > 
    > * Andres Freund (andres@anarazel.de) wrote:
    > > I hear these complaints about postgres most frequently: 1) replication
    > > sucks. 2) way too slow on analytics queries. 3) existing admin tools
    > > suck. 4) self written admin tools (required due to 3)) constantly break.
    > > 
    > > There's a lot being done on 1) and 2). There's very little in-core
    > > progress about 3). We're getting worse on 4).
    > 
    > I certainly hear some of these complaints also, and I'd love it if '3'
    > were something that the project was focused on, but, well, I really
    > don't see pgAdmin ever being in core, and 99% of the time that I'm
    > talking to end users, that's really what they're looking for (or, well,
    > something like it).  I don't recall, off-hand at least, ever running
    > into a user complaining that their pgAdmin-like admin tool broke.
    
    For me it's it's not a pgadmin alike (or rather a more featureful
    version) that's breaking the camel's back.  By far the biggest one I
    hear is auto-HA.  There's no in-core support, and pretty much all of the
    stuff out there is immature as hell. And even if it weren't people for
    good reason don't trust such core aspects to $random_project.  Good,
    easy to set up, monitoring is another thing - and I don't thing
    check_postgres is a significant portion of that, it doesn't have much in
    the way of guidelines, and actually pointing people to where problems
    are.
    
    Greetings,
    
    Andres Freund
    
    
    
  114. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-27T00:16:41Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-26 19:01:54 -0500, Stephen Frost wrote:
    > > * Andres Freund (andres@anarazel.de) wrote:
    > > > I hear these complaints about postgres most frequently: 1) replication
    > > > sucks. 2) way too slow on analytics queries. 3) existing admin tools
    > > > suck. 4) self written admin tools (required due to 3)) constantly break.
    > > > 
    > > > There's a lot being done on 1) and 2). There's very little in-core
    > > > progress about 3). We're getting worse on 4).
    > > 
    > > I certainly hear some of these complaints also, and I'd love it if '3'
    > > were something that the project was focused on, but, well, I really
    > > don't see pgAdmin ever being in core, and 99% of the time that I'm
    > > talking to end users, that's really what they're looking for (or, well,
    > > something like it).  I don't recall, off-hand at least, ever running
    > > into a user complaining that their pgAdmin-like admin tool broke.
    > 
    > For me it's it's not a pgadmin alike (or rather a more featureful
    > version) that's breaking the camel's back.  By far the biggest one I
    > hear is auto-HA.  There's no in-core support, and pretty much all of the
    > stuff out there is immature as hell.
    
    Oh, that's not what I tend to think of as 'admin tool'.  I completely
    agree with you on #1 and also that we need something better for HA.
    
    > And even if it weren't people for
    > good reason don't trust such core aspects to $random_project.  Good,
    > easy to set up, monitoring is another thing - and I don't thing
    > check_postgres is a significant portion of that, it doesn't have much in
    > the way of guidelines, and actually pointing people to where problems
    > are.
    
    My comment with check_postgres was more of a 'it seems unlikely we would
    get in something as simple as this', not to suggest in any way that it's
    the end-all, be-all of monitoring.
    
    And now to, unashamedly, push my own agenda- any ideas about something
    that would help with any of this that could be accomplished over a
    summer by a student?  Even if you don't want to mentor, having a good
    description, what skills are needed, the difficulty level, and the
    expected outcomes might allow someone else to mentor...
    
    Thanks!
    
    Stephen
    
  115. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-27T02:23:18Z

    On Fri, Jan 27, 2017 at 2:21 AM, Robert Haas <robertmhaas@gmail.com> wrote:
    > On Tue, Jan 24, 2017 at 4:47 PM, Robert Haas <robertmhaas@gmail.com> wrote:
    >>> But I don't see any proposals to actually change all uses of "xlog" to
    >>> "wal".  What about program names, command line options, etc.?  If the
    >>> argument is, we changed one thing, we should change the rest, then let's
    >>> see that.  I think that argument itself is flawed, but if that's what
    >>> we're going with, let's see the whole plan.
    >>
    >> I'm happy to go change every last bit of it.  I was expecting after I
    >> committed the initial rename that somebody would provide a follow-on
    >> patch to do the rest of it in short order.  Instead, months went by
    >> and we still don't have a complete patch.  But I don't see why that
    >> has to take more than a day's work, probably just a few hours.  I'd
    >> like to do that and move on.
    >
    > And here are patches for that.
    > 0001 renames everything that contains "xlog" in pg_proc.h to refer to "wal".
    > 0002 renames programs whose names contains "xlog".
    > 0003 renames the dtrace probes whose names contain "xlog".
    > 0004 renames command line options which contain "xlog".
    >
    > There are probably a few more things that could be done afterwards to
    > clean up other odds and ends, but I think this gets the vast bulk of
    > the user-visible references to xlog.
    
    Thanks for doing this work. Jumping on the train, here is a review for
    those patches. All of them are very mechanical changes. Just:
    -<!ENTITY pgxlogdump         SYSTEM "pg_xlogdump.sgml">
    +<!ENTITY pgwaldump         SYSTEM "pg_waldump.sgml">
     <!ENTITY postgres           SYSTEM "postgres-ref.sgml">
    A nit about the number of spaces here.
    
    In protocol.sgml:
          <varlistentry>
          <term>
           <literal>xlogpos</literal> (<type>text</type>)
          </term>
          <listitem>
          <para>
           Current xlog flush location. Useful to get a known location in the
           transaction log where streaming can start.
          </para>
          </listitem>
          </varlistentry>
    You want to say WAL here instead of xlog.
    
    In storage.sgml, similar thing:
      <row>
       <entry>pd_lsn</entry>
       <entry>PageXLogRecPtr</entry>
       <entry>8 bytes</entry>
       <entry>LSN: next byte after last byte of xlog record for last change
       to this page</entry>
      </row>
    s/xlog/WAL/
    
    In pg_standby.c:
    pg_standby.c:   printf("  %s [OPTION]... ARCHIVELOCATION NEXTWALFILE
    XLOGFILEPATH [RESTARTWALFILE]\n", progname);
    s/XLOGFILEPATH/WALFILEPATH/.
    
    All the other references to "xlog" are in the code comments, for the
    user-facing changes your set of patches is enough.
    -- 
    Michael
    
    
    
  116. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-27T23:03:34Z

    On 1/26/17 2:05 PM, Robert Haas wrote:
    > I do not think it can be right to rename the directory and not
    > anything else.
    
    I think this is the root of the confusion.
    
    A lot of people apparently consented to renaming pg_xlog with the
    understanding that that's it, whereas other people understood it as
    consensus for renaming everything.
    
    You really have (at least) three options here:
    
    1. Rename nothing
    2. Rename directory only
    3. Rename everything
    
    and you need to count the votes of each pair separately.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  117. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-27T23:05:03Z

    On 1/26/17 1:10 PM, Tom Lane wrote:
    > pg_reset_wal
    
    It's really more pg_reset_controldata, isn't it?
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  118. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Peter Eisentraut <peter.eisentraut@2ndquadrant.com> — 2017-01-27T23:06:11Z

    On 1/24/17 4:47 PM, Robert Haas wrote:
    > I'm not excited about starting to change pg_clog before we finish with
    > xlog -> wal.  Then we just have two half-done things, IMO.  But I'm
    > also not the only one with a commit bit.
    
    I think that depends on which way you slice the overall mission.  You
    appear to think the mission is to have everything named consistently.  I
    thought the mission was to have no directories named *log*.
    
    -- 
    Peter Eisentraut              http://www.2ndQuadrant.com/
    PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
    
    
    
  119. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-27T23:10:19Z

    On Sat, Jan 28, 2017 at 8:06 AM, Peter Eisentraut
    <peter.eisentraut@2ndquadrant.com> wrote:
    > On 1/24/17 4:47 PM, Robert Haas wrote:
    >> I'm not excited about starting to change pg_clog before we finish with
    >> xlog -> wal.  Then we just have two half-done things, IMO.  But I'm
    >> also not the only one with a commit bit.
    >
    > I think that depends on which way you slice the overall mission.  You
    > appear to think the mission is to have everything named consistently.  I
    > thought the mission was to have no directories named *log*.
    
    Those are two different missions. Deciding what to do for the renaming
    of pg_xlog does not prevent pg_clog and pg_subtrans to be renamed as
    no functions and no binaries use those terms.
    -- 
    Michael
    
    
    
  120. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-27T23:13:38Z

    On 2017-01-27 18:06:11 -0500, Peter Eisentraut wrote:
    > On 1/24/17 4:47 PM, Robert Haas wrote:
    > > I'm not excited about starting to change pg_clog before we finish with
    > > xlog -> wal.  Then we just have two half-done things, IMO.  But I'm
    > > also not the only one with a commit bit.
    > 
    > I think that depends on which way you slice the overall mission.  You
    > appear to think the mission is to have everything named consistently.  I
    > thought the mission was to have no directories named *log*.
    
    +1
    
    
    
  121. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-27T23:47:03Z

    On Sat, Jan 28, 2017 at 8:03 AM, Peter Eisentraut
    <peter.eisentraut@2ndquadrant.com> wrote:
    > On 1/26/17 2:05 PM, Robert Haas wrote:
    >> I do not think it can be right to rename the directory and not
    >> anything else.
    >
    > I think this is the root of the confusion.
    >
    > A lot of people apparently consented to renaming pg_xlog with the
    > understanding that that's it, whereas other people understood it as
    > consensus for renaming everything.
    >
    > You really have (at least) three options here:
    >
    > 1. Rename nothing
    > 2. Rename directory only
    > 3. Rename everything
    >
    > and you need to count the votes of each pair separately.
    
    4. Rename everything with aliases.
    
    I would vote for 4., or 3. for consistency if 4. is not an eligible choice.
    -- 
    Michael
    
    
    
  122. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-01-28T03:43:12Z

    On 1/27/17 6:47 PM, Michael Paquier wrote:
    > On Sat, Jan 28, 2017 at 8:03 AM, Peter Eisentraut
    > <peter.eisentraut@2ndquadrant.com> wrote:
    >> On 1/26/17 2:05 PM, Robert Haas wrote:
    >>> I do not think it can be right to rename the directory and not
    >>> anything else.
    >>
    >> I think this is the root of the confusion.
    >>
    >> A lot of people apparently consented to renaming pg_xlog with the
    >> understanding that that's it, whereas other people understood it as
    >> consensus for renaming everything.
    >>
    >> You really have (at least) three options here:
    >>
    >> 1. Rename nothing
    >> 2. Rename directory only
    >> 3. Rename everything
    >>
    >> and you need to count the votes of each pair separately.
    >
    > 4. Rename everything with aliases.
    >
    > I would vote for 4., or 3. for consistency if 4. is not an eligible choice.
    
    I vote for 3.
    
    The problem I have with aliases is that they would need to be done 
    across the board.  At the least, we would need function aliases, 
    symlinks for the binaries (which would rneed to be done by the 
    packagers), aliases for the command line options, and lots of notations 
    in the documentation.
    
    All of this would need to be preserved more or less indefinitely, 
    because if we can't decide on a break now it's not likely to happen later.
    
    -- 
    -David
    david@pgmasters.net
    
    
    
  123. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-29T23:39:21Z

    On Sat, Jan 28, 2017 at 12:43 PM, David Steele <david@pgmasters.net> wrote:
    > The problem I have with aliases is that they would need to be done across
    > the board.  At the least, we would need function aliases, symlinks for the
    > binaries (which would rneed to be done by the packagers), aliases for the
    > command line options, and lots of notations in the documentation.
    
    I was not precise enough here, I am fine with only the function
    aliases, because they just have as cost an extra line in pg_proc.h and
    because binary-level aliases on Windows are a pain.
    
    > All of this would need to be preserved more or less indefinitely, because if
    > we can't decide on a break now it's not likely to happen later.
    
    That's true as well.
    -- 
    Michael
    
    
    
  124. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-01-29T23:45:30Z

    On 2017-01-28 08:47:03 +0900, Michael Paquier wrote:
    > On Sat, Jan 28, 2017 at 8:03 AM, Peter Eisentraut
    > <peter.eisentraut@2ndquadrant.com> wrote:
    > > On 1/26/17 2:05 PM, Robert Haas wrote:
    > >> I do not think it can be right to rename the directory and not
    > >> anything else.
    > >
    > > I think this is the root of the confusion.
    > >
    > > A lot of people apparently consented to renaming pg_xlog with the
    > > understanding that that's it, whereas other people understood it as
    > > consensus for renaming everything.
    > >
    > > You really have (at least) three options here:
    > >
    > > 1. Rename nothing
    > > 2. Rename directory only
    > > 3. Rename everything
    > >
    > > and you need to count the votes of each pair separately.
    > 
    > 4. Rename everything with aliases.
    > 
    > I would vote for 4., or 3. for consistency if 4. is not an eligible choice.
    
    2, 4, 1, 3
    
    
    
  125. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-01-30T04:44:09Z

    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-01-28 08:47:03 +0900, Michael Paquier wrote:
    > > On Sat, Jan 28, 2017 at 8:03 AM, Peter Eisentraut
    > > <peter.eisentraut@2ndquadrant.com> wrote:
    > > > On 1/26/17 2:05 PM, Robert Haas wrote:
    > > >> I do not think it can be right to rename the directory and not
    > > >> anything else.
    > > >
    > > > I think this is the root of the confusion.
    > > >
    > > > A lot of people apparently consented to renaming pg_xlog with the
    > > > understanding that that's it, whereas other people understood it as
    > > > consensus for renaming everything.
    > > >
    > > > You really have (at least) three options here:
    > > >
    > > > 1. Rename nothing
    > > > 2. Rename directory only
    > > > 3. Rename everything
    > > >
    > > > and you need to count the votes of each pair separately.
    > > 
    > > 4. Rename everything with aliases.
    > > 
    > > I would vote for 4., or 3. for consistency if 4. is not an eligible choice.
    > 
    > 2, 4, 1, 3
    
    For me, it's: 3, 4, 1, 2.
    
    I tend to agree with the other discussion, which points out that aliases
    for everything isn't really practical..
    
    Of course, I'd also like to drop things like pg_user and pg_shadow one
    day...  Never thought they'd last anywhere near this long when I first
    wrote those views, 12 years ago...
    
    Thanks!
    
    Stephen
    
  126. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Vladimir Rusinov <vrusinov@google.com> — 2017-01-30T11:01:29Z

    On Fri, Jan 27, 2017 at 11:03 PM, Peter Eisentraut <
    peter.eisentraut@2ndquadrant.com> wrote:
    
    > 1. Rename nothing
    > 2. Rename directory only
    > 3. Rename everything
    >
    
    3 or 1 (with a slight preference for 3).
    
    Not sure if my vote counts, but for me as ex-DBA consistency mattered *a
    lot*.
    This is one of the reasons PostgreSQL is actually nicer to work with than
    many other databases. I remember 'wal' vs 'xlog' was actually one of a very
    few confusing things. I think it is important to stick to just one term,
    whether it be wal or xlog. I'd prefer wal since it's a term used in many
    other systems. 'xlog' may be confused with likes of binary log in MySQL
    which is not what it is.
    
    Now, I've rebased my patches to rename functions (with and without aliases)
    on top of current master, but there's probably no point of posting them now
    given there are patches above that rename other things as well.
    
    -- 
    Vladimir Rusinov
    Storage SRE, Google Ireland
    
    Google Ireland Ltd.,Gordon House, Barrow Street, Dublin 4, Ireland
    Registered in Dublin, Ireland
    Registration Number: 368047
    
  127. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-01-31T04:44:23Z

    On Mon, Jan 30, 2017 at 8:01 PM, Vladimir Rusinov <vrusinov@google.com> wrote:
    >
    > On Fri, Jan 27, 2017 at 11:03 PM, Peter Eisentraut
    > <peter.eisentraut@2ndquadrant.com> wrote:
    >>
    >> 1. Rename nothing
    >> 2. Rename directory only
    >> 3. Rename everything
    >
    >
    > 3 or 1 (with a slight preference for 3).
    >
    > Not sure if my vote counts, but for me as ex-DBA consistency mattered a lot.
    
    Any voice counts :)
    
    > This is one of the reasons PostgreSQL is actually nicer to work with than
    > many other databases. I remember 'wal' vs 'xlog' was actually one of a very
    > few confusing things. I think it is important to stick to just one term,
    > whether it be wal or xlog. I'd prefer wal since it's a term used in many
    > other systems. 'xlog' may be confused with likes of binary log in MySQL
    > which is not what it is.
    
    The first time I worked on Postgres, I was not able to do the mapping
    between both terms as well.
    
    > Now, I've rebased my patches to rename functions (with and without aliases)
    > on top of current master, but there's probably no point of posting them now
    > given there are patches above that rename other things as well.
    
    OK, I have moved this patch to CF 2017-03, let's make the discussion
    continue with more votes coming in.
    -- 
    Michael
    
    
    
  128. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Daniel Verite <daniel@manitou-mail.org> — 2017-02-02T23:50:32Z

    	Peter Eisentraut wrote:
    
    > You really have (at least) three options here:
    > 
    > 1. Rename nothing
    > 2. Rename directory only
    > 3. Rename everything
    
    I vote for 1) as I believe the renaming will create more confusion
    than it's worth, not even considering the renaming of functions
    and views.
    
    What if we look at the change from the pessimistic angle?
    An example of confusion that the change would create:
    a lot of users currently choose pg_wal for the destination
    directory of their archive command. Less-informed users
    that set up archiving and/or log shipping in PG10 based on
    advice online from previous versions will be fairly
    confused about the missing pg_xlog, and the fact that the
    pg_wal directory they're supposed to create already exists.
    
    Also googling for pg_wal, I'm finding food for thought like this
    IBM technote:
    http://www-01.ibm.com/support/docview.wss?uid=isg3T1015637
    which recommends to 
    "Remove all files under /var/lib/pgsql/9.0/data/pg_wal/"
    and also calls that directory the "write-ahead log directory"
    which is quite confusing because apparently it's the destination of
    their archive command.
    
    This brings the question: what about the people who will delete
    their pg_wal (ex-pg_xlog) when they face a disk-full condition and
    they mix up in their mind the archive directory and the WAL directory?
    It's hard to guess how many could make that mistake but I don't see
    why it would be less probable than confusing pg_xlog and pg_log.
    At least the contents of the latter directories look totally
    different, contrary to the wal directory versus wal archive.
    
    Also, what about the users who are helped currently by
    the fact that "pg_xlog" is associated at the top of google results
    to good articles that explain what it is, why it fills up and what
    to do about it? By burying the name "pg_xlog" we're also loosing that
    connection, and in the worst case making worse the problem we
    wanted to help with.
    
    There's also the disruption in existing backup scripts that directly
    reference pg_xlog. Obviously these scripts are critical, and there's
    something weird in breaking that intentionally. The motivation of the
    breakage is likely to be felt as frivolous and unfair to those people who
    are adversely impacted by the change, even if the part of not
    reading the release notes is their fault.
    
    
    Best regards,
    -- 
    Daniel Vérité
    PostgreSQL-powered mailer: http://www.manitou-mail.org
    Twitter: @DanielVerite
    
    
    
  129. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-02-03T00:03:00Z

    On Fri, Feb 3, 2017 at 8:50 AM, Daniel Verite <daniel@manitou-mail.org> wrote:
    > What if we look at the change from the pessimistic angle?
    > An example of confusion that the change would create:
    > a lot of users currently choose pg_wal for the destination
    > directory of their archive command.
    
    Really? I find that surprising to say "a lot". Perhaps there are some,
    but first I would not suspect that there are many people to use this
    repository name, and even less crazy enough to store them directly in
    PGDATA itself. And of course that's not on a different partition :)
    
    > Also googling for pg_wal, I'm finding food for thought like this
    > IBM technote:
    > http://www-01.ibm.com/support/docview.wss?uid=isg3T1015637
    > which recommends to
    > "Remove all files under /var/lib/pgsql/9.0/data/pg_wal/"
    > and also calls that directory the "write-ahead log directory"
    > which is quite confusing because apparently it's the destination of
    > their archive command.
    
    Well this product of IBM is one.
    
    > There's also the disruption in existing backup scripts that directly
    > reference pg_xlog. Obviously these scripts are critical, and there's
    > something weird in breaking that intentionally. The motivation of the
    > breakage is likely to be felt as frivolous and unfair to those people who
    > are adversely impacted by the change, even if the part of not
    > reading the release notes is their fault.
    
    Those are not complicated to fix because they are hard failures.
    Sufficient tests need to be done so as backup scripts don't show in
    red on live systems before deploying them. The original reason to do
    the rename is that there are folks as well thinking that removing
    pg_xlog is fine on full disk because, you know, it contains just
    *logs* so they are not critical for the system.
    -- 
    Michael
    
    
    
  130. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-03T10:21:28Z

    Daniel,
    
    * Daniel Verite (daniel@manitou-mail.org) wrote:
    > What if we look at the change from the pessimistic angle?
    > An example of confusion that the change would create:
    > a lot of users currently choose pg_wal for the destination
    > directory of their archive command. Less-informed users
    > that set up archiving and/or log shipping in PG10 based on
    > advice online from previous versions will be fairly
    > confused about the missing pg_xlog, and the fact that the
    > pg_wal directory they're supposed to create already exists.
    
    One would hope that they would realize that's not going to work
    when they set up PG10.  If they aren't paying attention sufficient
    to realize that then it seems entirely likely that they would feel
    equally safe removing the contents of a directory named 'pg_xlog'.
    
    > Also googling for pg_wal, I'm finding food for thought like this
    > IBM technote:
    > http://www-01.ibm.com/support/docview.wss?uid=isg3T1015637
    > which recommends to 
    > "Remove all files under /var/lib/pgsql/9.0/data/pg_wal/"
    > and also calls that directory the "write-ahead log directory"
    > which is quite confusing because apparently it's the destination of
    > their archive command.
    
    It's certainly unfortunate that people have thought that they can create
    arbitrary directories under the PG data directory.  That's never going
    to be safe, witness that we've created new directories under PGDATA in
    the last few releases and I don't see any reason why that would change
    moving forward.  Perhaps we should check for the existance of such a
    directory during pg_upgrade and throw an error, and we should go back
    and do the same for other directories which have been added over
    releases, but I'm not sure I can see an argument for doing much more
    than that.
    
    > This brings the question: what about the people who will delete
    > their pg_wal (ex-pg_xlog) when they face a disk-full condition and
    > they mix up in their mind the archive directory and the WAL directory?
    
    In my experience, at least, that's less likely to happen than someone
    nuke'ing pg_xlog.
    
    > It's hard to guess how many could make that mistake but I don't see
    > why it would be less probable than confusing pg_xlog and pg_log.
    
    Based on my experience, at least, that seems quite a bit less likely to
    happen.
    
    > At least the contents of the latter directories look totally
    > different, contrary to the wal directory versus wal archive.
    
    Sadly, that doesn't seem to have always made much of a difference.
    
    > Also, what about the users who are helped currently by
    > the fact that "pg_xlog" is associated at the top of google results
    > to good articles that explain what it is, why it fills up and what
    > to do about it? By burying the name "pg_xlog" we're also loosing that
    > connection, and in the worst case making worse the problem we
    > wanted to help with.
    
    We'll have new articles about pg_wal which will be picked up by Google
    also.  I'm not quite sure how we would be making the problem worse
    though- previously when it filled, a group of users believed it to be a
    log directory which could be wiped out.  With the new name, it's at
    least clearer that it's not simple a directory of not-necessary log
    files.
    
    > There's also the disruption in existing backup scripts that directly
    > reference pg_xlog. Obviously these scripts are critical, and there's
    > something weird in breaking that intentionally. The motivation of the
    > breakage is likely to be felt as frivolous and unfair to those people who
    > are adversely impacted by the change, even if the part of not
    > reading the release notes is their fault.
    
    While these scripts are critical, they're also likely to not be safe,
    which is the unfortunate reality.  If they're well written then they'll
    break cleanly, quickly, and be easily fixed.
    
    We will break things across major version upgrades.  That's part of
    the reason that we have major version upgrades, and why we support
    released versions for years with bug fixes.
    
    Thanks!
    
    Stephen
    
  131. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-02-03T21:39:08Z

    On Fri, Feb 3, 2017 at 5:21 AM, Stephen Frost <sfrost@snowman.net> wrote:
    > Daniel,
    >
    > * Daniel Verite (daniel@manitou-mail.org) wrote:
    >> What if we look at the change from the pessimistic angle?
    >> An example of confusion that the change would create:
    >> a lot of users currently choose pg_wal for the destination
    >> directory of their archive command. Less-informed users
    >> that set up archiving and/or log shipping in PG10 based on
    >> advice online from previous versions will be fairly
    >> confused about the missing pg_xlog, and the fact that the
    >> pg_wal directory they're supposed to create already exists.
    >
    > One would hope that they would realize that's not going to work
    > when they set up PG10.  If they aren't paying attention sufficient
    > to realize that then it seems entirely likely that they would feel
    > equally safe removing the contents of a directory named 'pg_xlog'.
    
    So... somebody want to tally up the votes here?
    
    And... was this discussed at the FOSDEM developer meeting?
    
    (Please say yes.)
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  132. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Kevin Grittner <kgrittn@gmail.com> — 2017-02-03T23:01:34Z

    On Thu, Jan 26, 2017 at 3:55 PM, Robert Haas <robertmhaas@gmail.com> wrote:
    
    > The substantive issue here is whether we should go forward with this
    > change, back out the change we already did, or leave things as they
    > are.  Tom, David, and I seem to be in lock step on at least the
    > following conclusion: halfway in between is bad.
    
    I agree.
    
    > So I have every
    > intention of continuing to push very hard for us to go either forward
    > or backward.
    
    +1
    
    Given the number of times I've known of people deleting files from
    pg_xlog because the name made the contents seem unimportant, I
    think finishing the job is better.
    
    --
    Kevin Grittner
    EDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  133. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-02-06T04:24:04Z

    On Sat, Feb 4, 2017 at 6:39 AM, Robert Haas <robertmhaas@gmail.com> wrote:
    > On Fri, Feb 3, 2017 at 5:21 AM, Stephen Frost <sfrost@snowman.net> wrote:
    >> Daniel,
    >>
    >> * Daniel Verite (daniel@manitou-mail.org) wrote:
    >>> What if we look at the change from the pessimistic angle?
    >>> An example of confusion that the change would create:
    >>> a lot of users currently choose pg_wal for the destination
    >>> directory of their archive command. Less-informed users
    >>> that set up archiving and/or log shipping in PG10 based on
    >>> advice online from previous versions will be fairly
    >>> confused about the missing pg_xlog, and the fact that the
    >>> pg_wal directory they're supposed to create already exists.
    >>
    >> One would hope that they would realize that's not going to work
    >> when they set up PG10.  If they aren't paying attention sufficient
    >> to realize that then it seems entirely likely that they would feel
    >> equally safe removing the contents of a directory named 'pg_xlog'.
    >
    > So... somebody want to tally up the votes here?
    
    Here is what I have, 6 votes clearly stated:
    1. Rename nothing: Daniel,
    2. Rename directory only: Andres
    3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    aliases for functions, I could live without at this point...)
    
    > And... was this discussed at the FOSDEM developer meeting?
    >
    > (Please say yes.)
    
    Looking only at the minutes, the answer is no:
    https://wiki.postgresql.org/wiki/FOSDEM/PGDay_2017_Developer_Meeting
    -- 
    Michael
    
    
    
  134. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Kevin Grittner <kgrittn@gmail.com> — 2017-02-06T14:16:04Z

    On Sun, Feb 5, 2017 at 10:24 PM, Michael Paquier
    <michael.paquier@gmail.com> wrote:
    
    >> So... somebody want to tally up the votes here?
    >
    > Here is what I have, 6 votes clearly stated:
    > 1. Rename nothing: Daniel,
    > 2. Rename directory only: Andres
    > 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    > aliases for functions, I could live without at this point...)
    
    I vote for 3 as well, with 1 as the only sane alternative.
    
    -- 
    Kevin Grittner
    
    
    
  135. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Fujii Masao <masao.fujii@gmail.com> — 2017-02-06T14:42:58Z

    On Mon, Feb 6, 2017 at 1:24 PM, Michael Paquier
    <michael.paquier@gmail.com> wrote:
    > On Sat, Feb 4, 2017 at 6:39 AM, Robert Haas <robertmhaas@gmail.com> wrote:
    >> On Fri, Feb 3, 2017 at 5:21 AM, Stephen Frost <sfrost@snowman.net> wrote:
    >>> Daniel,
    >>>
    >>> * Daniel Verite (daniel@manitou-mail.org) wrote:
    >>>> What if we look at the change from the pessimistic angle?
    >>>> An example of confusion that the change would create:
    >>>> a lot of users currently choose pg_wal for the destination
    >>>> directory of their archive command. Less-informed users
    >>>> that set up archiving and/or log shipping in PG10 based on
    >>>> advice online from previous versions will be fairly
    >>>> confused about the missing pg_xlog, and the fact that the
    >>>> pg_wal directory they're supposed to create already exists.
    >>>
    >>> One would hope that they would realize that's not going to work
    >>> when they set up PG10.  If they aren't paying attention sufficient
    >>> to realize that then it seems entirely likely that they would feel
    >>> equally safe removing the contents of a directory named 'pg_xlog'.
    >>
    >> So... somebody want to tally up the votes here?
    >
    > Here is what I have, 6 votes clearly stated:
    > 1. Rename nothing: Daniel,
    > 2. Rename directory only: Andres
    > 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    > aliases for functions, I could live without at this point...)
    
    I vote for 1.
    I still wonder how much the renaming of pg_xlog actually helps very careless
    people who remove pg_xlog becase its name includes "log". I'm afraid that
    they would make another serious mistake (e.g., remove pg_wal because it has
    many files and it occupies large amount of disk space) even after renaming
    to pg_wal. The crazy idea, making initdb create the empty file with the name
    "DONT_REMOVE_pg_xlog_IF_YOU_DONT_WANT_TO_LOSE_YOUR_IMPORTANT_DATA"
    in $PGDATA seems more helpful. Anyway I'm afraid that the renaming would
    cause more pain than gain.
    
    Regards,
    
    -- 
    Fujii Masao
    
    
    
  136. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Magnus Hagander <magnus@hagander.net> — 2017-02-06T17:29:20Z

    On Mon, Feb 6, 2017 at 5:24 AM, Michael Paquier <michael.paquier@gmail.com>
    wrote:
    
    > On Sat, Feb 4, 2017 at 6:39 AM, Robert Haas <robertmhaas@gmail.com> wrote:
    > > On Fri, Feb 3, 2017 at 5:21 AM, Stephen Frost <sfrost@snowman.net>
    > wrote:
    > >> Daniel,
    > >>
    > >> * Daniel Verite (daniel@manitou-mail.org) wrote:
    > >>> What if we look at the change from the pessimistic angle?
    > >>> An example of confusion that the change would create:
    > >>> a lot of users currently choose pg_wal for the destination
    > >>> directory of their archive command. Less-informed users
    > >>> that set up archiving and/or log shipping in PG10 based on
    > >>> advice online from previous versions will be fairly
    > >>> confused about the missing pg_xlog, and the fact that the
    > >>> pg_wal directory they're supposed to create already exists.
    > >>
    > >> One would hope that they would realize that's not going to work
    > >> when they set up PG10.  If they aren't paying attention sufficient
    > >> to realize that then it seems entirely likely that they would feel
    > >> equally safe removing the contents of a directory named 'pg_xlog'.
    > >
    > > So... somebody want to tally up the votes here?
    >
    > Here is what I have, 6 votes clearly stated:
    > 1. Rename nothing: Daniel,
    > 2. Rename directory only: Andres
    > 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    > aliases for functions, I could live without at this point...)
    >
    
    Put my vote down for 2.
    
    
    
    > > And... was this discussed at the FOSDEM developer meeting?
    > >
    > > (Please say yes.)
    >
    > Looking only at the minutes, the answer is no:
    > https://wiki.postgresql.org/wiki/FOSDEM/PGDay_2017_Developer_Meeting
    
    
    
    We discussed discussing it :) And came to the conclusion that we did not
    have enough of a quorum to actually make any decision on it complete, so we
    figured it's better if everybody just chime in individually.
    
    
    -- 
     Magnus Hagander
     Me: http://www.hagander.net/
     Work: http://www.redpill-linpro.com/
    
  137. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-02-09T18:55:39Z

    On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net> wrote:
    >> Here is what I have, 6 votes clearly stated:
    >> 1. Rename nothing: Daniel,
    >> 2. Rename directory only: Andres
    >> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    >> aliases for functions, I could live without at this point...)
    >
    > Put my vote down for 2.
    
    I think there is a very strong consensus for going either forward and
    renaming everything or going backward and renaming nothing.  That
    position has been endorsed by me, David Johnston, Tom Lane, Stephen
    Frost, Kevin Grittner, Vladimir Rusinov, David Steele, probably
    Michael Paquier, and possibly JD.  The only people who have explicitly
    voted against that position are Andres and Magnus, who prefer renaming
    only the directory.  I think that's approximately a 7-2 vote in favor
    of not leaving things as they are (#2).
    
    The vote on whether to go forward (#3) or backward (#1) is closer.
    All of the people mentioned above as wanting consistency - except for
    JD whose actual vote wasn't entirely clear - indicated a preference
    for #3 over #1, but a number of them prefer it only weakly.  Moreover,
    Fujii Masao and Daniel Verite prefer #1.  But I still think that the
    vote is in favor of #3.  There are 7 clear votes for that position and
    no more than 2 votes for any other position.  Even regarding every
    vote that isn't for #3 as a vote for #1, which is probably not
    entirely accurate, it's still 7-4 in favor of #3.
    
    Looking back at older emails before things came quite so sharply into
    focus, I found various other opinions.  But I don't think they change
    the overall picture very much.  Cynthia Shang seemed to favor a more
    limited renaming, but her point was that we have lots of internal
    stuff that uses the xlog terminology, which isn't quite the same
    question as whether the user-visible stuff should all match.  David
    Fetter favored not adding aliases when we did the renaming, but didn't
    clearly spell out that he favored the renaming.  Similarly, Euler
    Taveira favored aliases in an extension, but likewise didn't clearly
    spell out his position on the renaming itself.  (I would tend to count
    those as votes in favor of the renaming itself but you could argue
    that.)  Bruce Momjian wanted to go forward to keep things clean.
    Simon Riggs wanted to leave things as they are, but the reason given
    was not so much about the merits of the issue but about not wanting to
    spend more time on it.  You can come up with different counts
    depending on exactly how you interpret what all of those people said,
    but not even the least favorable allocation of those votes ends up
    with anything other than #3 as the most popular option.
    
    Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    jump in now with another opinion but I think this thread's gone on
    long enough.  We're going to take some backward-compatibility pain
    here as a result of these changes and some people are going to be
    unhappy about that, but I think we've allowed enough time for people
    to weigh in with opinions and this seems to be where we're at.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  138. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-02-09T19:08:14Z

    Robert Haas <robertmhaas@gmail.com> writes:
    > On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net> wrote:
    >>> Here is what I have, 6 votes clearly stated:
    >>> 1. Rename nothing: Daniel,
    >>> 2. Rename directory only: Andres
    >>> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    >>> aliases for functions, I could live without at this point...)
    
    > [ vote-counting ]
    
    > Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    > jump in now with another opinion but I think this thread's gone on
    > long enough.
    
    Agreed, let's just get it done.
    
    Although this doesn't really settle whether we ought to do 3a (with
    backwards-compatibility function aliases in core) or 3b (without 'em).
    Do people want to re-vote, understanding that those are the remaining
    choices?
    
    			regards, tom lane
    
    
    
  139. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David G. Johnston <david.g.johnston@gmail.com> — 2017-02-09T19:14:07Z

    On Thu, Feb 9, 2017 at 12:08 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    
    > Robert Haas <robertmhaas@gmail.com> writes:
    > > On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net>
    > wrote:
    > >>> Here is what I have, 6 votes clearly stated:
    > >>> 1. Rename nothing: Daniel,
    > >>> 2. Rename directory only: Andres
    > >>> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    > >>> aliases for functions, I could live without at this point...)
    >
    > > [ vote-counting ]
    >
    > > Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    > > jump in now with another opinion but I think this thread's gone on
    > > long enough.
    >
    > Agreed, let's just get it done.
    >
    > Although this doesn't really settle whether we ought to do 3a (with
    > backwards-compatibility function aliases in core) or 3b (without 'em).
    > Do people want to re-vote, understanding that those are the remaining
    > choices?
    >
    
    ​I wouldn't oppose:
    
    CREATE EXTENSION give_me_my_xlog_back;
    
    but my prior thoughts lead me toward not including such functions in the
    bootstrap catalog.
    
    David J.
    
  140. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-02-09T19:19:51Z

    On 2/9/17 2:14 PM, David G. Johnston wrote:
    > On Thu, Feb 9, 2017 at 12:08 PM, Tom Lane <tgl@sss.pgh.pa.us
    > <mailto:tgl@sss.pgh.pa.us>>wrote:
    > 
    >     Robert Haas <robertmhaas@gmail.com <mailto:robertmhaas@gmail.com>>
    >     writes:
    >     > On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net <mailto:magnus@hagander.net>> wrote:
    >     >>> Here is what I have, 6 votes clearly stated:
    >     >>> 1. Rename nothing: Daniel,
    >     >>> 2. Rename directory only: Andres
    >     >>> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    >     >>> aliases for functions, I could live without at this point...)
    > 
    >     > [ vote-counting ]
    > 
    >     > Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    >     > jump in now with another opinion but I think this thread's gone on
    >     > long enough.
    > 
    >     Agreed, let's just get it done.
    > 
    >     Although this doesn't really settle whether we ought to do 3a (with
    >     backwards-compatibility function aliases in core) or 3b (without 'em).
    >     Do people want to re-vote, understanding that those are the remaining
    >     choices?
    
    -1 on aliases in core (so to be clear my vote is for 3b).
    
    > ​I wouldn't oppose:
    > 
    > CREATE EXTENSION give_me_my_xlog_back;
    > 
    > but my prior thoughts lead me toward not including such functions in the
    > bootstrap catalog.
    
    I'm not very excited about an extension, can we just provide a link to a
    script in the release notes, or simply note that wrappers can be created?
    
    -- 
    -David
    david@pgmasters.net
    
    
    
  141. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-02-09T19:25:33Z

    On 2017-02-09 14:08:14 -0500, Tom Lane wrote:
    > Robert Haas <robertmhaas@gmail.com> writes:
    > > On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net> wrote:
    > >>> Here is what I have, 6 votes clearly stated:
    > >>> 1. Rename nothing: Daniel,
    > >>> 2. Rename directory only: Andres
    > >>> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    > >>> aliases for functions, I could live without at this point...)
    > 
    > > [ vote-counting ]
    > 
    > > Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    > > jump in now with another opinion but I think this thread's gone on
    > > long enough.
    > 
    > Agreed, let's just get it done.
    > 
    > Although this doesn't really settle whether we ought to do 3a (with
    > backwards-compatibility function aliases in core) or 3b (without 'em).
    > Do people want to re-vote, understanding that those are the remaining
    > choices?
    
    3a)
    
    
    
  142. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-02-09T19:40:27Z

    On Thu, Feb 9, 2017 at 2:08 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Robert Haas <robertmhaas@gmail.com> writes:
    >> On Mon, Feb 6, 2017 at 12:29 PM, Magnus Hagander <magnus@hagander.net> wrote:
    >>>> Here is what I have, 6 votes clearly stated:
    >>>> 1. Rename nothing: Daniel,
    >>>> 2. Rename directory only: Andres
    >>>> 3. Rename everything: Stephen, Vladimir, David S, Michael P (with
    >>>> aliases for functions, I could live without at this point...)
    >
    >> [ vote-counting ]
    >
    >> Therefore, I plan to go ahead and do #3.  Somebody's probably going to
    >> jump in now with another opinion but I think this thread's gone on
    >> long enough.
    >
    > Agreed, let's just get it done.
    >
    > Although this doesn't really settle whether we ought to do 3a (with
    > backwards-compatibility function aliases in core) or 3b (without 'em).
    > Do people want to re-vote, understanding that those are the remaining
    > choices?
    
    I prefer (3c) put them in an extension and let people that need 'em
    install 'em, but not have them available by default.  If the only
    choices are (3a) and (3b) then I guess I pick (3b), but I think an
    extension doesn't cost much and will ease the migration pain for users
    so I'm in favor of it.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  143. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-02-09T19:44:01Z

    Robert Haas <robertmhaas@gmail.com> writes:
    > On Thu, Feb 9, 2017 at 2:08 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    >> Although this doesn't really settle whether we ought to do 3a (with
    >> backwards-compatibility function aliases in core) or 3b (without 'em).
    >> Do people want to re-vote, understanding that those are the remaining
    >> choices?
    
    > I prefer (3c) put them in an extension and let people that need 'em
    > install 'em, but not have them available by default.
    
    As far as the core code is concerned, 3b and 3c are the same thing.
    IOW, somebody can write the extension later.
    
    			regards, tom lane
    
    
    
  144. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Kevin Grittner <kgrittn@gmail.com> — 2017-02-09T20:33:05Z

    On Thu, Feb 9, 2017 at 1:44 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Robert Haas <robertmhaas@gmail.com> writes:
    >> On Thu, Feb 9, 2017 at 2:08 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    >>> Although this doesn't really settle whether we ought to do 3a (with
    >>> backwards-compatibility function aliases in core) or 3b (without 'em).
    >>> Do people want to re-vote, understanding that those are the remaining
    >>> choices?
    >
    >> I prefer (3c) put them in an extension and let people that need 'em
    >> install 'em, but not have them available by default.
    >
    > As far as the core code is concerned, 3b and 3c are the same thing.
    
    I think so, too, if we're talking about an extension in core.
    
    My vote is for 3b.  If someone wants to write the alias extension and
    make it available outside of core, fine -- though they don't need anyone's
    vote to do so.
    
    -- 
    Kevin Grittner
    
    
    
  145. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Josh Berkus <josh@berkus.org> — 2017-02-09T20:37:49Z

    On 02/09/2017 11:08 AM, Tom Lane wrote:
    > Agreed, let's just get it done.
    > 
    > Although this doesn't really settle whether we ought to do 3a (with
    > backwards-compatibility function aliases in core) or 3b (without 'em).
    > Do people want to re-vote, understanding that those are the remaining
    > choices?
    
    Does 3a) mean keeping the aliases more-or-less forever?
    
    If not, I vote for 3b.  If we're going to need to break stuff, let's
    just do it.
    
    If we can keep the aliases for 6-10 years, then I see no reason not to
    have them (3a).  They're not exactly likely to conflict with user-chosen
    names.
    
    -- 
    Josh Berkus
    Containers & Databases Oh My!
    
    
    
  146. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-09T20:42:47Z

    * Josh Berkus (josh@berkus.org) wrote:
    > On 02/09/2017 11:08 AM, Tom Lane wrote:
    > > Agreed, let's just get it done.
    > > 
    > > Although this doesn't really settle whether we ought to do 3a (with
    > > backwards-compatibility function aliases in core) or 3b (without 'em).
    > > Do people want to re-vote, understanding that those are the remaining
    > > choices?
    > 
    > Does 3a) mean keeping the aliases more-or-less forever?
    > 
    > If not, I vote for 3b.  If we're going to need to break stuff, let's
    > just do it.
    > 
    > If we can keep the aliases for 6-10 years, then I see no reason not to
    > have them (3a).  They're not exactly likely to conflict with user-chosen
    > names.
    
    When we remove pg_shadow, then I'll be willing to agree that maybe we
    can start having things in PG for a couple releases that are just for
    backwards-compatibility and will actually be removed later.
    
    History has shown that's next to impossible, however.
    
    Thanks!
    
    Stephen
    
  147. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Josh Berkus <josh@berkus.org> — 2017-02-09T20:49:37Z

    On 02/09/2017 12:42 PM, Stephen Frost wrote:
    > * Josh Berkus (josh@berkus.org) wrote:
    >> On 02/09/2017 11:08 AM, Tom Lane wrote:
    >>> Agreed, let's just get it done.
    >>>
    >>> Although this doesn't really settle whether we ought to do 3a (with
    >>> backwards-compatibility function aliases in core) or 3b (without 'em).
    >>> Do people want to re-vote, understanding that those are the remaining
    >>> choices?
    >>
    >> Does 3a) mean keeping the aliases more-or-less forever?
    >>
    >> If not, I vote for 3b.  If we're going to need to break stuff, let's
    >> just do it.
    >>
    >> If we can keep the aliases for 6-10 years, then I see no reason not to
    >> have them (3a).  They're not exactly likely to conflict with user-chosen
    >> names.
    > 
    > When we remove pg_shadow, then I'll be willing to agree that maybe we
    > can start having things in PG for a couple releases that are just for
    > backwards-compatibility and will actually be removed later.
    > 
    > History has shown that's next to impossible, however.
    
    That's why I said 6-10 years.  If we're doing 3a, realistically we're
    supporting it until PostgreSQL 16, at least, and more likely 20.  I'm OK
    with that.
    
    What I'm voting against is the idea that we'll have aliases in core, but
    remove them in two releases.  Either that's unrealistic, or it's just
    prolonging the pain.
    
    -- 
    Josh Berkus
    Containers & Databases Oh My!
    
    
    
  148. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-09T20:53:47Z

    * Josh Berkus (josh@berkus.org) wrote:
    > On 02/09/2017 12:42 PM, Stephen Frost wrote:
    > > * Josh Berkus (josh@berkus.org) wrote:
    > >> On 02/09/2017 11:08 AM, Tom Lane wrote:
    > >>> Agreed, let's just get it done.
    > >>>
    > >>> Although this doesn't really settle whether we ought to do 3a (with
    > >>> backwards-compatibility function aliases in core) or 3b (without 'em).
    > >>> Do people want to re-vote, understanding that those are the remaining
    > >>> choices?
    > >>
    > >> Does 3a) mean keeping the aliases more-or-less forever?
    > >>
    > >> If not, I vote for 3b.  If we're going to need to break stuff, let's
    > >> just do it.
    > >>
    > >> If we can keep the aliases for 6-10 years, then I see no reason not to
    > >> have them (3a).  They're not exactly likely to conflict with user-chosen
    > >> names.
    > > 
    > > When we remove pg_shadow, then I'll be willing to agree that maybe we
    > > can start having things in PG for a couple releases that are just for
    > > backwards-compatibility and will actually be removed later.
    > > 
    > > History has shown that's next to impossible, however.
    > 
    > That's why I said 6-10 years.  If we're doing 3a, realistically we're
    > supporting it until PostgreSQL 16, at least, and more likely 20.  I'm OK
    > with that.
    
    Uh, to be clear, I think it's an entirely bad thing that we've had those
    views and various other cruft hang around for over 10 years.
    
    And removing them today will probably still have people crying about how
    pgAdmin3 and other things still use them.
    
    > What I'm voting against is the idea that we'll have aliases in core, but
    > remove them in two releases.  Either that's unrealistic, or it's just
    > prolonging the pain.
    
    Waiting 10+ years doesn't make the pain go away when it comes to
    removing things like that.
    
    Let's not go there.
    
    Thanks!
    
    Stephen
    
  149. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-02-09T20:57:35Z

    On 2017-02-09 15:53:47 -0500, Stephen Frost wrote:
    > * Josh Berkus (josh@berkus.org) wrote:
    > > What I'm voting against is the idea that we'll have aliases in core, but
    > > remove them in two releases.  Either that's unrealistic, or it's just
    > > prolonging the pain.
    > 
    > Waiting 10+ years doesn't make the pain go away when it comes to
    > removing things like that.
    
    That's ridiculous. I think we can fairly argue whether backward compat
    is worth it, but claiming that migrations to something new aren't easier
    if there's a number of versions that support both the old and the new
    names/syntax/whatnot is obviously wrong.
    
    
    
  150. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Josh Berkus <josh@berkus.org> — 2017-02-09T21:03:41Z

    On 02/09/2017 12:53 PM, Stephen Frost wrote:
    > * Josh Berkus (josh@berkus.org) wrote:
    >> On 02/09/2017 12:42 PM, Stephen Frost wrote:
    >>> * Josh Berkus (josh@berkus.org) wrote:
    >>>> On 02/09/2017 11:08 AM, Tom Lane wrote:
    >>>>> Agreed, let's just get it done.
    >>>>>
    >>>>> Although this doesn't really settle whether we ought to do 3a (with
    >>>>> backwards-compatibility function aliases in core) or 3b (without 'em).
    >>>>> Do people want to re-vote, understanding that those are the remaining
    >>>>> choices?
    >>>>
    >>>> Does 3a) mean keeping the aliases more-or-less forever?
    >>>>
    >>>> If not, I vote for 3b.  If we're going to need to break stuff, let's
    >>>> just do it.
    >>>>
    >>>> If we can keep the aliases for 6-10 years, then I see no reason not to
    >>>> have them (3a).  They're not exactly likely to conflict with user-chosen
    >>>> names.
    >>>
    >>> When we remove pg_shadow, then I'll be willing to agree that maybe we
    >>> can start having things in PG for a couple releases that are just for
    >>> backwards-compatibility and will actually be removed later.
    >>>
    >>> History has shown that's next to impossible, however.
    >>
    >> That's why I said 6-10 years.  If we're doing 3a, realistically we're
    >> supporting it until PostgreSQL 16, at least, and more likely 20.  I'm OK
    >> with that.
    > 
    > Uh, to be clear, I think it's an entirely bad thing that we've had those
    > views and various other cruft hang around for over 10 years.
    > 
    > And removing them today will probably still have people crying about how
    > pgAdmin3 and other things still use them.
    > 
    >> What I'm voting against is the idea that we'll have aliases in core, but
    >> remove them in two releases.  Either that's unrealistic, or it's just
    >> prolonging the pain.
    > 
    > Waiting 10+ years doesn't make the pain go away when it comes to
    > removing things like that.
    
    Sure it does.  That's two whole generations of client tools.  For
    example, at that point, pgAdmin3 won't reliably run on any supported
    platform, so it won't be a problem if we break it.
    
    If we clearly mark the old function names as deprecated aliases, client
    tools will gradually move to the new names.
    
    Counter-argument: moving the directory is going to break many tools
    anyway, so why bother with function aliases?
    
    -- 
    Josh Berkus
    Containers & Databases Oh My!
    
    
    
  151. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-09T21:04:01Z

    Andres,
    
    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-02-09 15:53:47 -0500, Stephen Frost wrote:
    > > * Josh Berkus (josh@berkus.org) wrote:
    > > > What I'm voting against is the idea that we'll have aliases in core, but
    > > > remove them in two releases.  Either that's unrealistic, or it's just
    > > > prolonging the pain.
    > > 
    > > Waiting 10+ years doesn't make the pain go away when it comes to
    > > removing things like that.
    > 
    > That's ridiculous. I think we can fairly argue whether backward compat
    > is worth it, but claiming that migrations to something new aren't easier
    > if there's a number of versions that support both the old and the new
    > names/syntax/whatnot is obviously wrong.
    
    We do provide a number of years of overlap- 5 years in fact.  I believe
    that's an entirely good thing and gives our users a chance to manage
    their upgrade paths from one major release to the next.
    
    Increasing that overlap to 10 or 15 years, however, doesn't make a
    hill-of-beans worth of difference, in my opinion.  Either they're
    tracking the releases that we're doing and making changes and adapting
    as we change things, or they aren't and won't ever unless they're forced
    to, instead preferring to make us carry the burden of maintenance on the
    backwards-compat pieces.
    
    Thanks!
    
    Stephen
    
  152. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    David Steele <david@pgmasters.net> — 2017-02-09T21:05:47Z

    On 2/9/17 4:03 PM, Josh Berkus wrote:
    
    > Counter-argument: moving the directory is going to break many tools
    > anyway, so why bother with function aliases?
    
    +1.
    
    -- 
    -David
    david@pgmasters.net
    
    
    
  153. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-09T21:07:08Z

    * Josh Berkus (josh@berkus.org) wrote:
    > On 02/09/2017 12:53 PM, Stephen Frost wrote:
    > > Waiting 10+ years doesn't make the pain go away when it comes to
    > > removing things like that.
    > 
    > Sure it does.  That's two whole generations of client tools.  For
    > example, at that point, pgAdmin3 won't reliably run on any supported
    > platform, so it won't be a problem if we break it.
    
    That's not true if OpenSCG has their way as they're continuing to
    maintain it, from my understanding.
    
    And, I'm sorry, but counting on projects to essentially die off to be
    the point where we can drop certain bits of backwards-compatibility just
    isn't a winning strategy.
    
    > If we clearly mark the old function names as deprecated aliases, client
    > tools will gradually move to the new names.
    
    No, they won't.  They haven't.  Look at pg_shadow- it was clearly marked
    as deprecated in *8.1*.
    
    > Counter-argument: moving the directory is going to break many tools
    > anyway, so why bother with function aliases?
    
    You're going to have to explain exactly the argument you're making
    there, because I don't see the point you're trying to get at with that
    question.
    
    Thanks!
    
    Stephen
    
  154. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-02-09T21:08:46Z

    On 2017-02-09 13:03:41 -0800, Josh Berkus wrote:
    > Counter-argument: moving the directory is going to break many tools
    > anyway, so why bother with function aliases?
    
    There's not actually that many tools affected by renaming pg_xlog,
    i.e. there are tools that aren't affected by the rename at all, but do
    calle *xlog* functions.
    
    
    
  155. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Tom Lane <tgl@sss.pgh.pa.us> — 2017-02-09T21:24:49Z

    Stephen Frost <sfrost@snowman.net> writes:
    > * Josh Berkus (josh@berkus.org) wrote:
    >> If we clearly mark the old function names as deprecated aliases, client
    >> tools will gradually move to the new names.
    
    > No, they won't.  They haven't.  Look at pg_shadow- it was clearly marked
    > as deprecated in *8.1*.
    
    Back in 8.1 we didn't have extensions.  Now that we do, I think the
    terms of discussion are a bit different.  In particular, if we relegate
    the aliases to an extension, the pain of getting/installing that extension
    will provide a forcing function encouraging users to fix their code so
    they don't need it anymore.
    
    Also, our experience with contrib/tsearch2 suggests that the extension
    shouldn't be part of contrib, because we have zero track record of getting
    rid of stuff in contrib, no matter how dead it is.
    
    So I'm entirely happy with somebody who feels a need for this developing
    an extension that we don't ship with the core system, and maintaining it
    for as long as they continue to feel the need for it.  We couldn't stop
    that from happening anyway.  But let's not buy into maintaining it as
    part of the core distribution.  We don't have a mechanism for getting
    rid of stuff once it's in the distro.
    
    			regards, tom lane
    
    
    
  156. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Robert Haas <robertmhaas@gmail.com> — 2017-02-09T21:39:38Z

    On Thu, Feb 9, 2017 at 4:24 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > Also, our experience with contrib/tsearch2 suggests that the extension
    > shouldn't be part of contrib, because we have zero track record of getting
    > rid of stuff in contrib, no matter how dead it is.
    
    Let's nuke tsearch2 to remove this adverse precedent, and then add the
    new thing.
    
    Anybody who still wants tsearch2 can go get it from an old version, or
    somebody can maintain a fork on github.
    
    -- 
    Robert Haas
    EnterpriseDB: http://www.enterprisedb.com
    The Enterprise PostgreSQL Company
    
    
    
  157. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-10T00:19:21Z

    * Robert Haas (robertmhaas@gmail.com) wrote:
    > On Thu, Feb 9, 2017 at 4:24 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > > Also, our experience with contrib/tsearch2 suggests that the extension
    > > shouldn't be part of contrib, because we have zero track record of getting
    > > rid of stuff in contrib, no matter how dead it is.
    > 
    > Let's nuke tsearch2 to remove this adverse precedent, and then add the
    > new thing.
    > 
    > Anybody who still wants tsearch2 can go get it from an old version, or
    > somebody can maintain a fork on github.
    
    Works for me.  I'd love to nuke pg_shadow and all the other
    not-really-maintained backwards-compat things from when roles were
    added too.
    
    Thanks!
    
    Stephen
    
  158. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-02-10T00:37:01Z

    On 2017-02-09 19:19:21 -0500, Stephen Frost wrote:
    > * Robert Haas (robertmhaas@gmail.com) wrote:
    > > On Thu, Feb 9, 2017 at 4:24 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > > > Also, our experience with contrib/tsearch2 suggests that the extension
    > > > shouldn't be part of contrib, because we have zero track record of getting
    > > > rid of stuff in contrib, no matter how dead it is.
    > > 
    > > Let's nuke tsearch2 to remove this adverse precedent, and then add the
    > > new thing.
    > > 
    > > Anybody who still wants tsearch2 can go get it from an old version, or
    > > somebody can maintain a fork on github.
    > 
    > Works for me.
    
    +1
    
    
    > I'd love to nuke pg_shadow and all the other
    > not-really-maintained backwards-compat things from when roles were
    > added too.
    
    Not sure if it's worth the work to rip out and such, but I'm mildly
    supportive of this one too.  Depends a bit on what all the other things
    are ;)
    
    Andres
    
    
    
  159. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-10T01:02:54Z

    * Andres Freund (andres@anarazel.de) wrote:
    > On 2017-02-09 19:19:21 -0500, Stephen Frost wrote:
    > > I'd love to nuke pg_shadow and all the other
    > > not-really-maintained backwards-compat things from when roles were
    > > added too.
    > 
    > Not sure if it's worth the work to rip out and such, but I'm mildly
    > supportive of this one too.  Depends a bit on what all the other things
    > are ;)
    
    Reviewing 7762619e95272974f90a38d8d85aafbe0e94add5 where roles were
    added, I find:
    
    pg_user   - use pg_roles instead, which actually includes all of the role
                attributes, unlike pg_user
    
    pg_shadow - use pg_authid instead, which, again, actually includes all
                of the role attributes, unlike pg_shadow.
    
    pg_group  - use pg_auth_members instead, which includes the info about
                the admin option and the grantor
    
    I don't think we should remove things like CREATE USER, that's a
    perfectly reasonable and maintained interface, unlike the above views,
    which missed out on things like the 'createrole' role attribute.
    
    Thanks!
    
    Stephen
    
  160. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Jim Nasby <jim.nasby@bluetreble.com> — 2017-02-10T01:03:51Z

    On 2/9/17 6:37 PM, Andres Freund wrote:
    >>> Anybody who still wants tsearch2 can go get it from an old version, or
    >>> somebody can maintain a fork on github.
    >> Works for me.
    > +1
    
    +1
    
    >> I'd love to nuke pg_shadow and all the other
    >> not-really-maintained backwards-compat things from when roles were
    >> added too.
    > Not sure if it's worth the work to rip out and such, but I'm mildly
    > supportive of this one too.  Depends a bit on what all the other things
    > are ;)
    
    The problem with pg_shadow is unless you specifically looked at it in 
    the docs after 8.1, you had no idea it was deprecated. I don't really 
    think of it as deprecated.
    
    As someone mentioned, forcing a user to install an extension makes the 
    deprecation visible. Another option would be to have the backend spit 
    out a WARNING the first time you access anything that's deprecated. Both 
    of those are pertinent reminders to people that they need to change 
    their tools.
    -- 
    Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
    Experts in Analytics, Data Architecture and PostgreSQL
    Data in Trouble? Get it in Treble! http://BlueTreble.com
    855-TREBLE2 (855-873-2532)
    
    
    
  161. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-10T01:16:47Z

    Jim,
    
    * Jim Nasby (Jim.Nasby@BlueTreble.com) wrote:
    > On 2/9/17 6:37 PM, Andres Freund wrote:
    > >>I'd love to nuke pg_shadow and all the other
    > >>not-really-maintained backwards-compat things from when roles were
    > >>added too.
    > >Not sure if it's worth the work to rip out and such, but I'm mildly
    > >supportive of this one too.  Depends a bit on what all the other things
    > >are ;)
    > 
    > The problem with pg_shadow is unless you specifically looked at it
    > in the docs after 8.1, you had no idea it was deprecated. I don't
    > really think of it as deprecated.
    
    It's not even maintained properly, I hardly see how it couldn't be
    anything but deprecated, and the docs certainly are the right place, if
    anywhere, to say that something is deprecated.
    
    > As someone mentioned, forcing a user to install an extension makes
    > the deprecation visible. Another option would be to have the backend
    > spit out a WARNING the first time you access anything that's
    > deprecated. Both of those are pertinent reminders to people that
    > they need to change their tools.
    
    Ugh.  Please, no.  Hacking up the backend to recognize that a given
    query is referring to a deprecated view and then throwing a warning on
    it is just plain ugly.
    
    Let's go one step further, and throw an ERROR if someone tries to query
    these views instead.
    
    Thanks!
    
    Stephen
    
  162. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Michael Paquier <michael.paquier@gmail.com> — 2017-02-10T01:19:56Z

    On Fri, Feb 10, 2017 at 10:16 AM, Stephen Frost <sfrost@snowman.net> wrote:
    >> As someone mentioned, forcing a user to install an extension makes
    >> the deprecation visible. Another option would be to have the backend
    >> spit out a WARNING the first time you access anything that's
    >> deprecated. Both of those are pertinent reminders to people that
    >> they need to change their tools.
    >
    > Ugh.  Please, no.  Hacking up the backend to recognize that a given
    > query is referring to a deprecated view and then throwing a warning on
    > it is just plain ugly.
    >
    > Let's go one step further, and throw an ERROR if someone tries to query
    > these views instead.
    
    FWIW, I am of the opinion to just nuke them as the "soft of"
    deprecation period has been very long. Applications should have
    switched to pg_authid and pg_roles long ago already.
    -- 
    Michael
    
    
    
  163. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Andres Freund <andres@anarazel.de> — 2017-02-10T01:22:41Z

    On 2017-02-09 20:02:54 -0500, Stephen Frost wrote:
    > * Andres Freund (andres@anarazel.de) wrote:
    > > On 2017-02-09 19:19:21 -0500, Stephen Frost wrote:
    > > > I'd love to nuke pg_shadow and all the other
    > > > not-really-maintained backwards-compat things from when roles were
    > > > added too.
    > > 
    > > Not sure if it's worth the work to rip out and such, but I'm mildly
    > > supportive of this one too.  Depends a bit on what all the other things
    > > are ;)
    > 
    > Reviewing 7762619e95272974f90a38d8d85aafbe0e94add5 where roles were
    > added, I find:
    > 
    > pg_user   - use pg_roles instead, which actually includes all of the role
    >             attributes, unlike pg_user
    
    Hm, I presume this is the most used one.
    
    
    > pg_group  - use pg_auth_members instead, which includes the info about
    >             the admin option and the grantor
    
    then this.
    
    > pg_shadow - use pg_authid instead, which, again, actually includes all
    >             of the role attributes, unlike pg_shadow.
    
    That's probably fine.
    
    
    I'm fine with dropping now, alternatively we could, and that seems like
    it'd institute a good practice, name them to be removed in 10+1 in the
    10 release notes. "Upcoming removal of deprecated features" or such. And
    schedule stuff for that regularly.  Like e.g. dropping psql support for
    < 9.0 (randomly chosen version), pg_dump support for very old versions,
    etc, ...
    While not everyone will be saved by that (by virtue of not reading /
    reacting) it helps those that actually read the notes.  Obviously
    there'd still some incompatibilities that do not go through that
    mechanism.
    
    
    > I don't think we should remove things like CREATE USER, that's a
    > perfectly reasonable and maintained interface, unlike the above views,
    > which missed out on things like the 'createrole' role attribute.
    
    Yea, that'd be a bad plan.
    
    
    Greetings,
    
    Andres Freund
    
    
    
  164. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Josh Berkus <josh@berkus.org> — 2017-02-10T01:25:52Z

    On 02/09/2017 05:19 PM, Michael Paquier wrote:
    > On Fri, Feb 10, 2017 at 10:16 AM, Stephen Frost <sfrost@snowman.net> wrote:
    >>> As someone mentioned, forcing a user to install an extension makes
    >>> the deprecation visible. Another option would be to have the backend
    >>> spit out a WARNING the first time you access anything that's
    >>> deprecated. Both of those are pertinent reminders to people that
    >>> they need to change their tools.
    >>
    >> Ugh.  Please, no.  Hacking up the backend to recognize that a given
    >> query is referring to a deprecated view and then throwing a warning on
    >> it is just plain ugly.
    >>
    >> Let's go one step further, and throw an ERROR if someone tries to query
    >> these views instead.
    > 
    > FWIW, I am of the opinion to just nuke them as the "soft of"
    > deprecation period has been very long. Applications should have
    > switched to pg_authid and pg_roles long ago already.
    > 
    
    We will definitely break a lot of client code by removing these -- I
    know that, deprecated or not, a lot of infrequently-updated
    driver/orm/GUI code still refers to pg_shadow/pg_user.
    
    I think Postgres 10 is the right time to break that code (I mean, we
    have to do it someday, and we're already telling people about breakage
    in 10), but be aware that there will be shouting and carrying on.
    
    -1 on a warning.  Very little code today which references the deprecated
    code is interactive, so who's going to see the warning?
    
    -- 
    Josh Berkus
    Containers & Databases Oh My!
    
    
    
  165. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Stephen Frost <sfrost@snowman.net> — 2017-02-10T01:33:46Z

    * Josh Berkus (josh@berkus.org) wrote:
    > On 02/09/2017 05:19 PM, Michael Paquier wrote:
    > > On Fri, Feb 10, 2017 at 10:16 AM, Stephen Frost <sfrost@snowman.net> wrote:
    > >>> As someone mentioned, forcing a user to install an extension makes
    > >>> the deprecation visible. Another option would be to have the backend
    > >>> spit out a WARNING the first time you access anything that's
    > >>> deprecated. Both of those are pertinent reminders to people that
    > >>> they need to change their tools.
    > >>
    > >> Ugh.  Please, no.  Hacking up the backend to recognize that a given
    > >> query is referring to a deprecated view and then throwing a warning on
    > >> it is just plain ugly.
    > >>
    > >> Let's go one step further, and throw an ERROR if someone tries to query
    > >> these views instead.
    > > 
    > > FWIW, I am of the opinion to just nuke them as the "soft of"
    > > deprecation period has been very long. Applications should have
    > > switched to pg_authid and pg_roles long ago already.
    > 
    > We will definitely break a lot of client code by removing these -- I
    > know that, deprecated or not, a lot of infrequently-updated
    > driver/orm/GUI code still refers to pg_shadow/pg_user.
    
    Any that we're aware of, I'd suggest we reach out to the maintainers of
    and let them know.
    
    > I think Postgres 10 is the right time to break that code (I mean, we
    > have to do it someday, and we're already telling people about breakage
    > in 10), but be aware that there will be shouting and carrying on.
    
    Agreed.
    
    > -1 on a warning.  Very little code today which references the deprecated
    > code is interactive, so who's going to see the warning?
    
    Indeed, I was thinking of this also.  The warnings would just end up in
    the server logs, amongst tons of often not-terribly-interesting
    information that far too many users ignore already, and those that don't
    probably actually read the release notes.
    
    Thanks!
    
    Stephen
    
  166. Re: [PATCH] Rename pg_switch_xlog to pg_switch_wal

    Bruce Momjian <bruce@momjian.us> — 2017-02-22T22:18:42Z

    On Fri, Feb  3, 2017 at 05:21:28AM -0500, Stephen Frost wrote:
    > > Also googling for pg_wal, I'm finding food for thought like this
    > > IBM technote:
    > > http://www-01.ibm.com/support/docview.wss?uid=isg3T1015637
    > > which recommends to 
    > > "Remove all files under /var/lib/pgsql/9.0/data/pg_wal/"
    > > and also calls that directory the "write-ahead log directory"
    > > which is quite confusing because apparently it's the destination of
    > > their archive command.
    > 
    > It's certainly unfortunate that people have thought that they can create
    > arbitrary directories under the PG data directory.  That's never going
    > to be safe, witness that we've created new directories under PGDATA in
    > the last few releases and I don't see any reason why that would change
    > moving forward.  Perhaps we should check for the existance of such a
    > directory during pg_upgrade and throw an error, and we should go back
    > and do the same for other directories which have been added over
    > releases, but I'm not sure I can see an argument for doing much more
    > than that.
    
    Actually, pg_upgrade already checks for some odd directories stored
    inside of PGDATA:
    
    	WARNING:  new data directory should not be inside the
    	old data directory, e.g. %s\n", old_cluster_pgdata);
    
    	WARNING:  user-defined tablespace locations should
    	not be inside the data directory, e.g. %s\n", old_tablespace_dir);
    
    -- 
      Bruce Momjian  <bruce@momjian.us>        http://momjian.us
      EnterpriseDB                             http://enterprisedb.com
    
    + As you are, so once was I.  As I am, so you will be. +
    +                      Ancient Roman grave inscription +