-
Notifications
You must be signed in to change notification settings - Fork 285
New issue
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
putFile, res.resume()? #259
Comments
Indeed @knox/owners Is there an api of sorts or documentation on what the For example, I'm trying to catch the case where a putFile operation actually failed to store the file. If I naively say |
There seems to be no documentation on Can somebody please improve the documentation on this function |
after that message I ended up inspecting the response manually. @mrjackdavis it's an object with many fields. I encourage you to take several minutes and try to understand mostly what's in it. I ended up simply checking the |
That should help people who are having issues with It would be amazing if it was properly documented |
@mrjackdavis indeed. There's a wiki here https://github.com/LearnBoost/knox/wiki like to take a shot given the aws docs? The material isn't fresh in my mind like yours ;) |
It's just the standard Node.js/io.js http response object. The docs don't belong here; they already exist in io.js. |
@domenic that's good to know. I didn't see that information in the readme though |
Yeah, it's kind of assumed that people working in Node.js environments know how the Node.js HTTP response class works. I guess we could link to it but I mean should we also link to the docs for Number in case people get confused what the type of statusCode is? |
I doubt people will need to know what the type of statusCode is. But really, |
@domenic if 3 persons have had confusion and bothered to actually participate on this issue I believe a link to the docs for the res object are warranted. What's most important to a new knox user is to understand that the response is from AWS and that they should peruse those docs to understand how to interact with AWS. Yes the onus lies on Knox. |
Lets add all these confused people on that list: #198 |
In other words: http.IncomingMessage which implements stream.Readable and there it has a resume. https://nodejs.org/api/stream.html#stream_readable_resume
getReadableStreamSomehow()
.resume();
.on('end', () => {
console.log('Reached the end, but did not read anything.');
}); |
I prefer the putFile syntax, however I just am not sure what the docs mean by always do something with res or at least call
res.resume()
. I'm checking the data within res, but is there a method I should call to end or what exactly does res.resume() do?Thank you
The text was updated successfully, but these errors were encountered: