[jira] [Commented] (HDFS-1788) FsShell ls: Show symlinks properties

2011-06-17 Thread Bochun Bai (JIRA)

[ 
https://issues.apache.org/jira/browse/HDFS-1788?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13050906#comment-13050906
 ] 

Bochun Bai commented on HDFS-1788:
--

Waiting for HADOOP-7360 is a good idea.
And cat/tail commands is not working, this is the motivation I involved.

I feel sorry about not knowing the assignee is still working on this.
It has been assigned for 50 days, and no more progress published.
Next time I will contact before started, thanks daryn.

 FsShell ls: Show symlinks properties
 

 Key: HDFS-1788
 URL: https://issues.apache.org/jira/browse/HDFS-1788
 Project: Hadoop HDFS
  Issue Type: Improvement
  Components: tools
Reporter: Jonathan Eagles
Assignee: John George
Priority: Minor
 Attachments: HDFS-1788.patch


 ls FsShell command implementation has been consistent with the linux 
 implementations of ls \-l. With the addition of symlinks, I would expect the 
 ability to show file type 'd' for directory, '\-' for file, and 'l' for 
 symlink. In addition, following the linkname entry for symlinks, I would 
 expect the ability to show \- link target. In linux, the default is to 
 the the properties of the link and not of the link target. In linux, '-L' 
 option allows for the dereferencing of symlinks to show link target 
 properties, but it is not the default. 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Commented] (HDFS-1788) FsShell ls: Show symlinks properties

2011-06-16 Thread Bochun Bai (JIRA)

[ 
https://issues.apache.org/jira/browse/HDFS-1788?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13050261#comment-13050261
 ] 

Bochun Bai commented on HDFS-1788:
--

Thanks daryn, your reviews encourage me a lot.
I will rewrite the patch and follow your advises.

But I got some difficult while keeping PathData maximum compatible: 
  Adds lstat, leaving fs, stat, exists.
  And fc should be added because HADOOP-6446. Further works should use 
FileContext instead of FileSystem.
  And lexists is requeired to identify broken links.

  The problem is fc should be initialized in ctor like fs, whether it is 
parameter or not, breaks compatible by requiring new parameter or throwing 
exceptions.
  If fc is not a field of PathData and initialized when item.lstat() is called. 
RPC to NN will increased.

To satisfies both compatible and feature, I suggest create a object named 
StatusData:
  contains fc, lstat and string.
  represent the link itself, not the real file.
  when cat/tail/stat is called, lstat.symlink will be resolved recursively and 
the real target is returned.
  FileStatus is recursively, and StatusData is independent to link or not.
  RPC to NN is decreased while listing a directory containing symlink. 
stat/read/write overhead to the symlink is the same, but lazy-inited. It should 
also improve GC activities to HADOOP-6732.

And I have noticed @eli created a serial issues about porting FileContext. I 
will submit next patch to HADOOP-6424.


 FsShell ls: Show symlinks properties
 

 Key: HDFS-1788
 URL: https://issues.apache.org/jira/browse/HDFS-1788
 Project: Hadoop HDFS
  Issue Type: Improvement
  Components: tools
Reporter: Jonathan Eagles
Assignee: John George
Priority: Minor
 Attachments: HDFS-1788.patch


 ls FsShell command implementation has been consistent with the linux 
 implementations of ls \-l. With the addition of symlinks, I would expect the 
 ability to show file type 'd' for directory, '\-' for file, and 'l' for 
 symlink. In addition, following the linkname entry for symlinks, I would 
 expect the ability to show \- link target. In linux, the default is to 
 the the properties of the link and not of the link target. In linux, '-L' 
 option allows for the dereferencing of symlinks to show link target 
 properties, but it is not the default. 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Updated] (HDFS-1788) FsShell ls: Show symlinks properties

2011-06-15 Thread Bochun Bai (JIRA)

 [ 
https://issues.apache.org/jira/browse/HDFS-1788?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Bochun Bai updated HDFS-1788:
-

Attachment: HDFS-1788.patch

A field fs.shell.PathData.statLink is added.
PathData.stat is renamed to statReal.

FsShell-ls uses statLink for all.
Other commands like -cat and -cp will use statReal.

 FsShell ls: Show symlinks properties
 

 Key: HDFS-1788
 URL: https://issues.apache.org/jira/browse/HDFS-1788
 Project: Hadoop HDFS
  Issue Type: Improvement
  Components: tools
Reporter: Jonathan Eagles
Assignee: John George
Priority: Minor
 Attachments: HDFS-1788.patch


 ls FsShell command implementation has been consistent with the linux 
 implementations of ls \-l. With the addition of symlinks, I would expect the 
 ability to show file type 'd' for directory, '\-' for file, and 'l' for 
 symlink. In addition, following the linkname entry for symlinks, I would 
 expect the ability to show \- link target. In linux, the default is to 
 the the properties of the link and not of the link target. In linux, '-L' 
 option allows for the dereferencing of symlinks to show link target 
 properties, but it is not the default. 

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira




[jira] [Created] (HDFS-2059) FsShell should support symbol links

2011-06-10 Thread Bochun Bai (JIRA)
FsShell should support symbol links
---

 Key: HDFS-2059
 URL: https://issues.apache.org/jira/browse/HDFS-2059
 Project: Hadoop HDFS
  Issue Type: New Feature
  Components: hdfs client
Affects Versions: 0.21.0
Reporter: Bochun Bai


bin/hadoop fs -cat sym_link
Above command is not working.


--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (HDFS-2059) FsShell should support symbol links

2011-06-10 Thread Bochun Bai (JIRA)

[ 
https://issues.apache.org/jira/browse/HDFS-2059?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13047145#comment-13047145
 ] 

Bochun Bai commented on HDFS-2059:
--

I will try current trunk and find out whether it still not working.

 FsShell should support symbol links
 ---

 Key: HDFS-2059
 URL: https://issues.apache.org/jira/browse/HDFS-2059
 Project: Hadoop HDFS
  Issue Type: New Feature
  Components: hdfs client
Affects Versions: 0.21.0
Reporter: Bochun Bai

 bin/hadoop fs -cat sym_link
 Above command is not working.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira