fix(fs/s3): fix stream writing support with Object Lock enabled (#6190)
This commit is contained in:
parent
4fb34ffee9
commit
854ae0f65e
@ -22,6 +22,7 @@
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-s3": "^3.54.0",
|
||||
"@aws-sdk/lib-storage": "^3.54.0",
|
||||
"@aws-sdk/middleware-apply-body-checksum": "^3.58.0",
|
||||
"@aws-sdk/node-http-handler": "^3.54.0",
|
||||
"@marsaud/smb2": "^0.18.0",
|
||||
"@sindresorhus/df": "^3.1.1",
|
||||
|
@ -14,6 +14,7 @@ import {
|
||||
} from '@aws-sdk/client-s3'
|
||||
import { Upload } from '@aws-sdk/lib-storage'
|
||||
import { NodeHttpHandler } from '@aws-sdk/node-http-handler'
|
||||
import { getApplyMd5BodyChecksumPlugin } from '@aws-sdk/middleware-apply-body-checksum'
|
||||
import assert from 'assert'
|
||||
import { Agent as HttpAgent } from 'http'
|
||||
import { Agent as HttpsAgent } from 'https'
|
||||
@ -75,6 +76,11 @@ export default class S3Handler extends RemoteHandlerAbstract {
|
||||
}),
|
||||
})
|
||||
|
||||
// Workaround for https://github.com/aws/aws-sdk-js-v3/issues/2673
|
||||
this._s3.middlewareStack.use(
|
||||
getApplyMd5BodyChecksumPlugin(this._s3.config)
|
||||
)
|
||||
|
||||
const parts = split(path)
|
||||
this._bucket = parts.shift()
|
||||
this._dir = join(...parts)
|
||||
|
@ -16,6 +16,7 @@
|
||||
|
||||
- [VM/Host Console] Fix support of older versions of XCP-ng/XS, please not that HTTP proxies are note supported in that case [#6191](https://github.com/vatesfr/xen-orchestra/pull/6191)
|
||||
- Fix HTTP proxy support to connect to pools (introduced in XO 5.69.0) [#6204](https://github.com/vatesfr/xen-orchestra/pull/6204)
|
||||
- [Backup] Fix failure when sending a backup (Full/Delta/Metadata) to S3 with Object Lock enabled (PR [#6190](https://github.com/vatesfr/xen-orchestra/pull/6190))
|
||||
|
||||
### Packages to release
|
||||
|
||||
@ -38,6 +39,10 @@
|
||||
- @vates/event-listeners-manager major
|
||||
- xen-api minor
|
||||
- xo-vmdk-to-vhd minor
|
||||
- @xen-orchestra/fs patch
|
||||
- @xen-orchestra/proxy patch
|
||||
- @xen-orchestra/backups patch
|
||||
- xo-server minor
|
||||
- xo-web minor
|
||||
- vhd-cli patch
|
||||
- @xen-orchestra/backups-cli patch
|
||||
|
10
yarn.lock
10
yarn.lock
@ -464,6 +464,16 @@
|
||||
"@aws-sdk/util-utf8-node" "3.55.0"
|
||||
tslib "^2.3.1"
|
||||
|
||||
"@aws-sdk/middleware-apply-body-checksum@^3.58.0":
|
||||
version "3.58.0"
|
||||
resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-apply-body-checksum/-/middleware-apply-body-checksum-3.58.0.tgz#f14b9c96f3cc9e567b49184ebda96db84317811f"
|
||||
integrity sha512-sAdY2IbFFgCdhBdiY7CamlShgZrFuli1eVJF60yndqSyVM5hUvOg4fNsMqXWCSqJ83151T3yf/j7G78yfoSt9g==
|
||||
dependencies:
|
||||
"@aws-sdk/is-array-buffer" "3.55.0"
|
||||
"@aws-sdk/protocol-http" "3.58.0"
|
||||
"@aws-sdk/types" "3.55.0"
|
||||
tslib "^2.3.1"
|
||||
|
||||
"@aws-sdk/middleware-bucket-endpoint@3.58.0":
|
||||
version "3.58.0"
|
||||
resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-bucket-endpoint/-/middleware-bucket-endpoint-3.58.0.tgz#cec84100ff776862e3bbd4bd596a1e869ad81e5e"
|
||||
|
Loading…
Reference in New Issue
Block a user