mirror of
https://github.com/pgbackrest/pgbackrest.git
synced 2025-01-18 04:58:51 +02:00
Allow hashSize() to run on remote storage.
Apparently we never needed to run this function remotely. It will be needed by the backup checksum delta feature, so implement it now. Contributed by Cynthia Shang.
This commit is contained in:
parent
052e483057
commit
b6b2c915b2
@ -68,6 +68,14 @@
|
||||
<p>Add helper for repository storage.</p>
|
||||
</release-item>
|
||||
|
||||
<release-item>
|
||||
<release-item-contributor-list>
|
||||
<release-item-contributor id="cynthia.shang"/>
|
||||
</release-item-contributor-list>
|
||||
|
||||
<p>Allow <code>hashSize()</code> to run on remote storage.</p>
|
||||
</release-item>
|
||||
|
||||
<release-item>
|
||||
<release-item-contributor-list>
|
||||
<release-item-contributor id="cynthia.shang"/>
|
||||
|
@ -55,6 +55,8 @@ use constant OP_STORAGE_CIPHER_PASS_USER => 'storageC
|
||||
push @EXPORT, qw(OP_STORAGE_CIPHER_PASS_USER);
|
||||
use constant OP_STORAGE_EXISTS => 'storageExists';
|
||||
push @EXPORT, qw(OP_STORAGE_EXISTS);
|
||||
use constant OP_STORAGE_HASH_SIZE => 'storageHashSize';
|
||||
push @EXPORT, qw(OP_STORAGE_HASH_SIZE);
|
||||
use constant OP_STORAGE_LIST => 'storageList';
|
||||
push @EXPORT, qw(OP_STORAGE_LIST);
|
||||
use constant OP_STORAGE_MANIFEST => 'storageManifest';
|
||||
|
@ -120,6 +120,7 @@ sub init
|
||||
&OP_STORAGE_MANIFEST => sub {$oStorage->manifest(@{shift()})},
|
||||
&OP_STORAGE_MOVE => sub {$oStorage->move(@{shift()})},
|
||||
&OP_STORAGE_PATH_GET => sub {$oStorage->pathGet(@{shift()})},
|
||||
&OP_STORAGE_HASH_SIZE => sub {$oStorage->hashSize(@{shift()})},
|
||||
|
||||
# Info commands
|
||||
&OP_INFO_STANZA_LIST => sub {$oInfo->stanzaList(@{shift()})},
|
||||
|
@ -80,6 +80,38 @@ sub exists
|
||||
);
|
||||
}
|
||||
|
||||
####################################################################################################################################
|
||||
# hashSize
|
||||
####################################################################################################################################
|
||||
sub hashSize
|
||||
{
|
||||
my $self = shift;
|
||||
|
||||
# Assign function parameters, defaults, and log debug info
|
||||
my
|
||||
(
|
||||
$strOperation,
|
||||
$strPathExp,
|
||||
$rhParam,
|
||||
) =
|
||||
logDebugParam
|
||||
(
|
||||
__PACKAGE__ . '->hashSize', \@_,
|
||||
{name => 'strPathExp'},
|
||||
{name => 'rhParam', required => false},
|
||||
);
|
||||
|
||||
my ($strHash, $lSize) = $self->{oProtocol}->cmdExecute(OP_STORAGE_HASH_SIZE, [$strPathExp, $rhParam]);
|
||||
|
||||
# Return from function and log return values if any
|
||||
return logDebugReturn
|
||||
(
|
||||
$strOperation,
|
||||
{name => 'strHash', value => $strHash},
|
||||
{name => 'lSize', value => $lSize}
|
||||
);
|
||||
}
|
||||
|
||||
####################################################################################################################################
|
||||
# list
|
||||
####################################################################################################################################
|
||||
|
@ -130,11 +130,13 @@ sub hashSize
|
||||
(
|
||||
$strOperation,
|
||||
$xFileExp,
|
||||
$bIgnoreMissing,
|
||||
) =
|
||||
logDebugParam
|
||||
(
|
||||
__PACKAGE__ . '->hashSize', \@_,
|
||||
{name => 'xFileExp'},
|
||||
{name => 'bIgnoreMissing', optional => true, default => false},
|
||||
);
|
||||
|
||||
# Set operation variables
|
||||
@ -142,7 +144,9 @@ sub hashSize
|
||||
my $lSize;
|
||||
|
||||
# Is this an IO object or a file expression?
|
||||
my $oFileIo = defined($xFileExp) ? (ref($xFileExp) ? $xFileExp : $self->openRead($self->pathGet($xFileExp))) : undef;
|
||||
my $oFileIo =
|
||||
defined($xFileExp) ? (ref($xFileExp) ? $xFileExp :
|
||||
$self->openRead($self->pathGet($xFileExp), {bIgnoreMissing => $bIgnoreMissing})) : undef;
|
||||
|
||||
if (defined($oFileIo))
|
||||
{
|
||||
|
@ -13372,6 +13372,8 @@ static const EmbeddedModule embeddedModule[] =
|
||||
"push @EXPORT, qw(OP_STORAGE_CIPHER_PASS_USER);\n"
|
||||
"use constant OP_STORAGE_EXISTS => 'storageExists';\n"
|
||||
"push @EXPORT, qw(OP_STORAGE_EXISTS);\n"
|
||||
"use constant OP_STORAGE_HASH_SIZE => 'storageHashSize';\n"
|
||||
"push @EXPORT, qw(OP_STORAGE_HASH_SIZE);\n"
|
||||
"use constant OP_STORAGE_LIST => 'storageList';\n"
|
||||
"push @EXPORT, qw(OP_STORAGE_LIST);\n"
|
||||
"use constant OP_STORAGE_MANIFEST => 'storageManifest';\n"
|
||||
@ -14597,6 +14599,7 @@ static const EmbeddedModule embeddedModule[] =
|
||||
"&OP_STORAGE_MANIFEST => sub {$oStorage->manifest(@{shift()})},\n"
|
||||
"&OP_STORAGE_MOVE => sub {$oStorage->move(@{shift()})},\n"
|
||||
"&OP_STORAGE_PATH_GET => sub {$oStorage->pathGet(@{shift()})},\n"
|
||||
"&OP_STORAGE_HASH_SIZE => sub {$oStorage->hashSize(@{shift()})},\n"
|
||||
"\n\n"
|
||||
"&OP_INFO_STANZA_LIST => sub {$oInfo->stanzaList(@{shift()})},\n"
|
||||
"\n\n"
|
||||
@ -15074,6 +15077,33 @@ static const EmbeddedModule embeddedModule[] =
|
||||
");\n"
|
||||
"}\n"
|
||||
"\n\n\n\n"
|
||||
"sub hashSize\n"
|
||||
"{\n"
|
||||
"my $self = shift;\n"
|
||||
"\n\n"
|
||||
"my\n"
|
||||
"(\n"
|
||||
"$strOperation,\n"
|
||||
"$strPathExp,\n"
|
||||
"$rhParam,\n"
|
||||
") =\n"
|
||||
"logDebugParam\n"
|
||||
"(\n"
|
||||
"__PACKAGE__ . '->hashSize', \\@_,\n"
|
||||
"{name => 'strPathExp'},\n"
|
||||
"{name => 'rhParam', required => false},\n"
|
||||
");\n"
|
||||
"\n"
|
||||
"my ($strHash, $lSize) = $self->{oProtocol}->cmdExecute(OP_STORAGE_HASH_SIZE, [$strPathExp, $rhParam]);\n"
|
||||
"\n\n"
|
||||
"return logDebugReturn\n"
|
||||
"(\n"
|
||||
"$strOperation,\n"
|
||||
"{name => 'strHash', value => $strHash},\n"
|
||||
"{name => 'lSize', value => $lSize}\n"
|
||||
");\n"
|
||||
"}\n"
|
||||
"\n\n\n\n"
|
||||
"sub list\n"
|
||||
"{\n"
|
||||
"my $self = shift;\n"
|
||||
@ -18363,17 +18393,21 @@ static const EmbeddedModule embeddedModule[] =
|
||||
"(\n"
|
||||
"$strOperation,\n"
|
||||
"$xFileExp,\n"
|
||||
"$bIgnoreMissing,\n"
|
||||
") =\n"
|
||||
"logDebugParam\n"
|
||||
"(\n"
|
||||
"__PACKAGE__ . '->hashSize', \\@_,\n"
|
||||
"{name => 'xFileExp'},\n"
|
||||
"{name => 'bIgnoreMissing', optional => true, default => false},\n"
|
||||
");\n"
|
||||
"\n\n"
|
||||
"my $strHash;\n"
|
||||
"my $lSize;\n"
|
||||
"\n\n"
|
||||
"my $oFileIo = defined($xFileExp) ? (ref($xFileExp) ? $xFileExp : $self->openRead($self->pathGet($xFileExp))) : undef;\n"
|
||||
"my $oFileIo =\n"
|
||||
"defined($xFileExp) ? (ref($xFileExp) ? $xFileExp :\n"
|
||||
"$self->openRead($self->pathGet($xFileExp), {bIgnoreMissing => $bIgnoreMissing})) : undef;\n"
|
||||
"\n"
|
||||
"if (defined($oFileIo))\n"
|
||||
"{\n"
|
||||
|
@ -93,8 +93,8 @@ P00 DEBUG: Archive::Common::walSegmentFind=>: strWalFileName = [undef]
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.4-1, strChecksum = [undef], strCipherPass = [undef], strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = ceb021d9bb41f220511e413b095d2b0d89fec113
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openWrite(): bAtomic = true, bPathCreate = true, lTimestamp = [undef], rhyFilter = [undef], strCipherPass = [undef], strGroup = [undef], strMode = <0640>, strUser = [undef], xFileExp = <REPO:ARCHIVE>/9.4-1/000000010000000100000001-ceb021d9bb41f220511e413b095d2b0d89fec113.gz
|
||||
|
@ -87,8 +87,8 @@ P00 DEBUG: Protocol::Helper::protocolGet: found cached protocol
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.4-1, strChecksum = [undef], strCipherPass = <redacted>, strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = ceb021d9bb41f220511e413b095d2b0d89fec113
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Protocol::Storage::Remote->openWrite(): rhParam = [hash], strFileExp = <REPO:ARCHIVE>/9.4-1/000000010000000100000001-ceb021d9bb41f220511e413b095d2b0d89fec113.gz
|
||||
|
@ -209,8 +209,8 @@ P00 DEBUG: Archive::Common::walSegmentFind=>: strWalFileName = [undef]
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = [undef], strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openWrite(): bAtomic = true, bPathCreate = true, lTimestamp = [undef], rhyFilter = [undef], strCipherPass = [undef], strGroup = [undef], strMode = <0640>, strUser = [undef], xFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000001-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
@ -464,8 +464,8 @@ P00 DEBUG: Archive::Common::walSegmentFind=>: strWalFileName = [undef]
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = [undef], strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openWrite(): bAtomic = true, bPathCreate = true, lTimestamp = [undef], rhyFilter = [undef], strCipherPass = [undef], strGroup = [undef], strMode = <0640>, strUser = [undef], xFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000002-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
|
@ -223,8 +223,8 @@ P00 DEBUG: Protocol::Helper::protocolGet: found cached protocol
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = <redacted>, strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Protocol::Storage::Remote->openWrite(): rhParam = [hash], strFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000001-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
@ -322,8 +322,8 @@ P00 DEBUG: Protocol::Helper::protocolGet: found cached protocol
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = <redacted>, strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Protocol::Storage::Remote->openWrite(): rhParam = [hash], strFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000002-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
|
@ -209,8 +209,8 @@ P00 DEBUG: Archive::Common::walSegmentFind=>: strWalFileName = [undef]
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = [undef], strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000001
|
||||
P00 DEBUG: Storage::Local->openWrite(): bAtomic = true, bPathCreate = true, lTimestamp = [undef], rhyFilter = [undef], strCipherPass = [undef], strGroup = [undef], strMode = <0640>, strUser = [undef], xFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000001-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
@ -439,8 +439,8 @@ P00 DEBUG: Archive::Common::walSegmentFind=>: strWalFileName = [undef]
|
||||
P00 DEBUG: Archive::Push::File::archivePushCheck=>: strArchiveId = 9.3-1, strChecksum = [undef], strCipherPass = [undef], strWarning = [undef]
|
||||
P00 DEBUG: Storage::Posix::Driver->new(): bFileSync = <true>, bPathSync = <true>
|
||||
P00 DEBUG: Storage::Local->new(): bAllowTemp = <true>, hRule = [undef], lBufferMax = 4194304, oDriver = [object], strCipherPassUser = [undef], strCipherType = [undef], strDefaultFileMode = <0640>, strDefaultPathMode = <0750>, strPathBase = [TEST_PATH]/db-master/db/base, strTempExtension = pgbackrest.tmp
|
||||
P00 DEBUG: Storage::Local->hashSize(): xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize(): bIgnoreMissing = <false>, xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = false, rhyFilter = [undef], strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->hashSize=>: lSize = 16777216, strHash = 488ba4b8b98acc510bce86b8f16e3c1ed9886a29
|
||||
P00 DEBUG: Storage::Local->openRead(): bIgnoreMissing = <false>, rhyFilter = ({rxyParam => ({iLevel => 3}), strClass => pgBackRest::Storage::Filter::Gzip}), strCipherPass = [undef], xFileExp = [TEST_PATH]/db-master/db/base/pg_xlog/000000010000000100000002
|
||||
P00 DEBUG: Storage::Local->openWrite(): bAtomic = true, bPathCreate = true, lTimestamp = [undef], rhyFilter = [undef], strCipherPass = [undef], strGroup = [undef], strMode = <0640>, strUser = [undef], xFileExp = <REPO:ARCHIVE>/9.3-1/000000010000000100000002-488ba4b8b98acc510bce86b8f16e3c1ed9886a29.gz
|
||||
|
@ -283,6 +283,9 @@ sub run
|
||||
$self->testResult(
|
||||
sub {$self->storageLocal()->hashSize($strFile)},
|
||||
qw{(} . cryptoHashOne('sha1', $strFileContent) . ', ' . $iFileSize . qw{)}, ' check hash/size');
|
||||
$self->testResult(
|
||||
sub {$self->storageLocal()->hashSize(BOGUS, {bIgnoreMissing => true})}, "([undef], [undef])",
|
||||
' check missing hash/size');
|
||||
}
|
||||
|
||||
################################################################################################################################
|
||||
|
Loading…
Reference in New Issue
Block a user