You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by Andrzej Bialecki <ab...@getopt.org> on 2006/02/09 23:09:03 UTC
Re: svn commit: r376449 - /lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java
cutting@apache.org wrote:
> Author: cutting
> Date: Thu Feb 9 14:02:45 2006
> New Revision: 376449
>
> URL: http://svn.apache.org/viewcvs?rev=376449&view=rev
> Log:
> Keep 'unzip' from prompting when overwriting (e.g., when archive
> contains same file twice). Also make it less verbose.
>
> Modified:
> lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java
>
> Modified: lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java
> URL: http://svn.apache.org/viewcvs/lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java?rev=376449&r1=376448&r2=376449&view=diff
> ==============================================================================
> --- lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java (original)
> +++ lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java Thu Feb 9 14:02:45 2006
> @@ -76,7 +76,7 @@
> JobConf job = new JobConf(t.getJobFile());
> String jar = job.getJar();
> if (jar != null) { // if jar exists, it into workDir
> - runChild(new String[] { "unzip", jar}, workDir);
> + runChild(new String[] { "unzip", "-o", "-q", jar}, workDir);
>
>
I think it would be better in this case to use the java.util.zip classes
to unpack the JAR rather than build yet another dependency on an
external utility... what do you think?
--
Best regards,
Andrzej Bialecki <><
___. ___ ___ ___ _ _ __________________________________
[__ || __|__/|__||\/| Information Retrieval, Semantic Web
___|||__|| \| || | Embedded Unix, System Integration
http://www.sigram.com Contact: info at sigram dot com
Re: svn commit: r376449 - /lucene/hadoop/trunk/src/java/org/apache/hadoop/mapred/TaskRunner.java
Posted by Doug Cutting <cu...@apache.org>.
Andrzej Bialecki wrote:
> I think it would be better in this case to use the java.util.zip classes
> to unpack the JAR rather than build yet another dependency on an
> external utility... what do you think?
Yes, that makes sense. I was trying to quickly fix the bug (tasks would
hang when a jar contained the same entry twice), but that would indeed
be a better solution.
Doug