When uploading a file, eg:
var stream = file.createWriteStream();
stream.on('error', function(err) {
uploadedFile.cloudStorageError = err;
checkNext();
});
stream.on('complete', function() {
next();
});
stream.end(buffer);
Is the correct event complete or finish. The docs say complete, but a user reported an issue with using complete and that finish was the one that worked for him. In my testing, both work with gcloud 0.20.0.