[
https://issues.apache.org/jira/browse/HADOOP-3485?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602398#action_12602398
]
Chuang Liu commented on HADOOP-3485:
------------------------------------
Hi:
Is it possible to use struct fuse_file_info * to pass file handler created in
fuse 'create' call to the following I/O calls like FUSE "write"? In this way,
you do not need close the file in fuse "create()" and reopen it in the
following fuse "write()" call.
For example, for a linux 'cp' command, The fuse call sequence is like the
following:
static int create (const char *, mode_t, struct fuse_file_info *) ;
static int write (const char *, const char *, size_t, off_t,struct
fuse_file_info *)
static int flush(...)
static int release(...)
The data in struct fuse_file_info* is passed along the call sequence.
Therefore, we could use it to store hadoop file handler or whatever info needed
for following I/O info. Thanks.
Chuang
> implement writes
> ----------------
>
> Key: HADOOP-3485
> URL: https://issues.apache.org/jira/browse/HADOOP-3485
> Project: Hadoop Core
> Issue Type: New Feature
> Components: contrib/fuse-dfs
> Reporter: Pete Wyckoff
> Priority: Minor
> Original Estimate: 48h
> Remaining Estimate: 48h
>
> Doesn't support writes because fuse protocol first creates the file then
> closes it and re-opens it to start writing to it. So, (until hadoop-1700), we
> need a work around.
> One way to do this is to open the file with overwrite flag on the second
> open. For security, would only want to do this for zero length files (could
> even check the creation ts too, but because of clock skew, that may be
> harder).
> Doug, Craig, Nicholas - Comments?
> -- pete
> ps since mostly already implemented, this should be a very quick patch
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.