memory leak
jaman99 opened this issue · 1 comments
jaman99 commented
var myvideo=req.files.myvideo[0].originalname;
var ext = path.extname(''+myvideo+'');
const gcsname =Date.now()+ext;
console.log('Hello wold ');
console.log(gcsname);
const file = bucket.file(gcsname);
const stream = file.createWriteStream({
metadata: {
contentType: req.files.myvideo[0].mimetype
},
resumable: false
});
stream.on('error', (err) => {
req.files.myvideo[0].cloudStorageError = err;
req.videocheck=false;
console.log('Error function hit.....');
mystreamendfun();
next(err);
});
stream.on('finish', () => {
req.files.myvideo.cloudStorageObjectimg = gcsname;
file.makePublic().then(() => {
req.files.myvideo[0].cloudStoragePublicUrlimg =getPublicUrl(gcsname);
req.videocheck=true;
console.log('Finish function hit.....');
mystreamendfun();
next();
});
});
stream.end(req.files.myvideo[0].buffer);
fhinkel commented
Hi @jaman99 , thank you for the detailed bug report. Unfortunately, this issue tracker has limited visibility and scope - basically, it's just for reporting issues with the samples contained here and is only watched by the folks who work on these samples.
We are happy to help you move this bug to venues where it'll get the attention of the appropriate product teams.
- StackOverflow's Google Cloud storage tag is most appropriate for design and general troubleshooting. You can read more about community support here.
- Google Cloud's public issue tracker is most appropriate for bugs and unexpected behavior.
- Google Cloud Support is most appropriate if you have an existing support contract with Google.
I'm going to close this issue because the folks who own this repo have no actionable way to resolve it directly, but please let us know if there's anything we can do to help!