1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2024-12-14 10:13:05 +02:00
pgbackrest/lib/pgBackRest/Storage
David Steele 7d8068f27b Don't decode manifest data when it is generated on a remote.
Decoding a manifest from the JSON provided by C to the hash required by Perl is an expensive process.  If manifest() was called on a remote it was being decoded into a hash and then immediately re-encoded into JSON for transmission over the protocol layer.

Instead, provide a function for the remote to get the raw JSON which can be transmitted as is and decoded in the calling process instead.

This makes remote manifest calls as fast as they were before 2.16, but local calls must still pay the decoding penalty and are therefore slower.  This will continue to be true until the Perl storage interface is retired at the end of the C migration.

Note that for reasonable numbers of tables there is no detectable difference.  The case in question involved 250K tables with a 10 minute decode time (which was being doubled) on a fast workstation.
2019-09-03 12:30:45 -04:00
..
Base.pm Add Perl interface to C storage layer. 2019-06-26 08:24:58 -04:00
Helper.pm Add Perl interface to C storage layer. 2019-06-26 08:24:58 -04:00
Storage.pm Don't decode manifest data when it is generated on a remote. 2019-09-03 12:30:45 -04:00
StorageRead.pm Add Perl interface to C storage layer. 2019-06-26 08:24:58 -04:00
StorageWrite.pm Add Perl interface to C storage layer. 2019-06-26 08:24:58 -04:00