We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'm facing problem in two cases.
In above two cases i'm getting lambda function response null without any error. And this error throws until l'm not deploying lambda function again.
Below is my code. ` const fileKeys = await this.listFileKeys(); const archive = archiver("zip"); const passThroughStream = new stream.PassThrough(); const { uploadId } = await createMultipartUpload(this.bucketName, this.destinationKey, this.aclType);
for (const file of fileKeys) { const downloadStream = await createDownloadStream(this.bucketName, file); const name = `${file.split(this.sourcePath + "/").pop()}`; archive.append(downloadStream, { name }); } archive.pipe(passThroughStream); archive.finalize(); const buffer = await streamToBuffer(passThroughStream); const chunkSize = 5 * 1024 * 1024; // 5 MB chunks const parts = []; for (let i = 0; i < Math.ceil(buffer.length / chunkSize); i++) { const start = i * chunkSize; const end = Math.min((i + 1) * chunkSize, buffer.length); const chunk = Buffer.from(buffer.subarray(start, end)); const { ETag } = await uploadPart(this.bucketName, this.destinationKey, uploadId, chunk, i + 1); parts.push({ ETag, PartNumber: i + 1 }); } await completeMultipartUpload(this.bucketName, this.destinationKey, uploadId, parts); logger.logDebug(`Completed multipart upload to S3. Destination key: ${this.destinationKey}`); return { status: true, errorMessage: "", destination_key: this.destinationKey };
` Any help is appriciated.
The text was updated successfully, but these errors were encountered:
Greetings. I am having exactly the same problem. Have you found any solution to this that you can share with me?
Edit: I had to modify the code a bit and increase the memory, before 512MB was not enough.
Sorry, something went wrong.
No branches or pull requests
I'm facing problem in two cases.
In above two cases i'm getting lambda function response null without any error. And this error throws until l'm not deploying lambda function again.
Below is my code.
` const fileKeys = await this.listFileKeys();
const archive = archiver("zip");
const passThroughStream = new stream.PassThrough();
const { uploadId } = await createMultipartUpload(this.bucketName, this.destinationKey, this.aclType);
`
Any help is appriciated.
The text was updated successfully, but these errors were encountered: