Github user yibter commented on the pull request:

    https://github.com/apache/incubator-metron/pull/62#issuecomment-202681193
  
    Nice @nickwallen! Just verified the -f on the -put totally works. And for 
fun, I looked at the hadoop code and you can see the 
[-copyFromLocal](https://github.com/apache/hadoop/blob/948b75807068c304ffe789e32f2b850c0d653e0a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/shell/CopyCommands.java#L290)
 is just an alias for put now...
    
    ```java
      public static class CopyFromLocal extends Put {
        public static final String NAME = "copyFromLocal";
        public static final String USAGE = Put.USAGE;
        public static final String DESCRIPTION = "Identical to the -put 
command.";
      }
    ```
    
    And the [-put 
](https://github.com/apache/hadoop/blob/948b75807068c304ffe789e32f2b850c0d653e0a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/shell/CopyCommands.java#L231)supports
 all kinds of nice undocumented flags...
    
    ```java
      public static class Put extends CommandWithDestination {
        public static final String NAME = "put";
        public static final String USAGE =
            "[-f] [-p] [-l] [-d] <localsrc> ... <dst>";
        public static final String DESCRIPTION =
          "Copy files from the local file system " +
          "into fs. Copying fails if the file already " +
          "exists, unless the -f flag is given.\n" +
          "Flags:\n" +
          "  -p : Preserves access and modification times, ownership and the 
mode.\n" +
          "  -f : Overwrites the destination if it already exists.\n" +
          "  -l : Allow DataNode to lazily persist the file to disk. Forces\n" +
          "       replication factor of 1. This flag will result in reduced\n" +
          "       durability. Use with care.\n" +
            "  -d : Skip creation of temporary file(<dst>._COPYING_).\n";
    ```
    
    I've updated this PR to use the -f instead of the ignore_errors, but it 
looks like Nick already has the fix in his other branch. Up to you guys on if 
you want to close this and/or wait for the other 
[commit](https://github.com/nickwallen/incubator-metron/commit/24e3688326d4764e7ef69cec9a7d9e1a40bafe46)
 to make its way over. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to