Note: I'm specifically asking about v0.8 streams right now - I have too
much code in v0.8 streams to re-write for the new v0.10 streams just yet.

I'm looking for a way that I can fsync a WriteStream before it is
fs.close()d. I thought I could just use {end: false} and watch for the end
of the read stream, fsync(ws.fd), then close the stream in the callback.
But the stream might have a queue of data waiting to be written (the _queue
entry in the ws) so I could fsync too soon.

Then I thought I could subclass WriteStream and overload the end() method,
but doing that suffers from the same queue problem, and I can't add an
fs.fsync into the queue because the WriteStream flush() method doesn't
support it.

Not sure what else to try now.

Thoughts?

-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to