Return-Path: X-Original-To: apmail-incubator-crunch-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-crunch-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 604D7E8E6 for ; Thu, 13 Dec 2012 15:34:16 +0000 (UTC) Received: (qmail 93426 invoked by uid 500); 13 Dec 2012 15:34:15 -0000 Delivered-To: apmail-incubator-crunch-dev-archive@incubator.apache.org Received: (qmail 93145 invoked by uid 500); 13 Dec 2012 15:34:14 -0000 Mailing-List: contact crunch-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: crunch-dev@incubator.apache.org Delivered-To: mailing list crunch-dev@incubator.apache.org Received: (qmail 92066 invoked by uid 99); 13 Dec 2012 15:34:13 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Dec 2012 15:34:13 +0000 Date: Thu, 13 Dec 2012 15:34:13 +0000 (UTC) From: "Dave Beech (JIRA)" To: crunch-dev@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CRUNCH-131) Input paths containing globs/wildcards are not accepted MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CRUNCH-131?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Dave Beech updated CRUNCH-131: ------------------------------ Attachment: CRUNCH-131.patch Here's a quick patch to add support for these paths. A couple of questions about the current version: - what's the reason for the throw and catch of FileNotFoundException? Can't you just log and return 0 inside the null check if-statement? - what's the logic behind returning -1 or 0 following different checks? (I've kept the -1 return so that unit tests still pass.) Thanks > Input paths containing globs/wildcards are not accepted > ------------------------------------------------------- > > Key: CRUNCH-131 > URL: https://issues.apache.org/jira/browse/CRUNCH-131 > Project: Crunch > Issue Type: Bug > Components: Core > Affects Versions: 0.4.0 > Reporter: Dave Beech > Assignee: Josh Wills > Attachments: CRUNCH-131.patch > > > Crunch fails to calculate the size of paths containing wildcards - example error below: > Exception in thread "main" java.lang.IllegalStateException: Input source SeqFile(/my/path/containing/wildcards*/part*) does not exist! > at org.apache.crunch.impl.mr.collect.InputCollection.getSizeInternal(InputCollection.java:53) > at org.apache.crunch.impl.mr.collect.PCollectionImpl.getSize(PCollectionImpl.java:253) > at org.apache.crunch.impl.mr.collect.DoCollectionImpl.getSizeInternal(DoCollectionImpl.java:43) > at org.apache.crunch.impl.mr.collect.PCollectionImpl.getSize(PCollectionImpl.java:253) > at org.apache.crunch.impl.mr.collect.DoTableImpl.getSizeInternal(DoTableImpl.java:47) > at org.apache.crunch.impl.mr.collect.PGroupedTableImpl.getSizeInternal(PGroupedTableImpl.java:75) > at org.apache.crunch.impl.mr.collect.PCollectionImpl.getSize(PCollectionImpl.java:253) > at org.apache.crunch.impl.mr.collect.PGroupedTableImpl.configureShuffle(PGroupedTableImpl.java:63) > at org.apache.crunch.impl.mr.plan.JobPrototype.build(JobPrototype.java:162) > at org.apache.crunch.impl.mr.plan.JobPrototype.getCrunchJob(JobPrototype.java:114) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira