← All changes
|
includes/sdk/s3/Aws/S3/Crypto/S3EncryptionClientV2.php
+2
-1
1.2.2
→
1.4.2
View file →
| @@ -4,8 +4,9 @@ | ||
| 4 | 4 | |
| 5 | 5 | use Dudlewebs\WPMCS\s3\Aws\Crypto\DecryptionTraitV2; |
| 6 | 6 | use Dudlewebs\WPMCS\s3\Aws\Exception\CryptoException; |
| 7 | 7 | use Dudlewebs\WPMCS\s3\Aws\HashingStream; |
| 8 | +use Dudlewebs\WPMCS\s3\Aws\MetricsBuilder; | |
| 8 | 9 | use Dudlewebs\WPMCS\s3\Aws\PhpHash; |
| 9 | 10 | use Dudlewebs\WPMCS\s3\Aws\Crypto\AbstractCryptoClientV2; |
| 10 | 11 | use Dudlewebs\WPMCS\s3\Aws\Crypto\EncryptionTraitV2; |
| 11 | 12 | use Dudlewebs\WPMCS\s3\Aws\Crypto\MetadataEnvelope; |
| @@ -99,12 +100,12 @@ | ||
| 99 | 100 | * files for metadata storage. |
| 100 | 101 | */ |
| 101 | 102 | public function __construct(S3Client $client, $instructionFileSuffix = null) |
| 102 | 103 | { |
| 103 | - $this->appendUserAgent($client, 'feat/s3-encrypt/' . self::CRYPTO_VERSION); | |
| 104 | 104 | $this->client = $client; |
| 105 | 105 | $this->instructionFileSuffix = $instructionFileSuffix; |
| 106 | 106 | $this->legacyWarningCount = 0; |
| 107 | + MetricsBuilder::appendMetricsCaptureMiddleware($this->client->getHandlerList(), MetricsBuilder::S3_CRYPTO_V2); | |
| 107 | 108 | } |
| 108 | 109 | private static function getDefaultStrategy() |
| 109 | 110 | { |
| 110 | 111 | return new HeadersMetadataStrategy(); |