Return-Path: X-Original-To: apmail-pig-dev-archive@www.apache.org Delivered-To: apmail-pig-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7857F9FBC for ; Tue, 6 Dec 2011 23:48:26 +0000 (UTC) Received: (qmail 65186 invoked by uid 500); 6 Dec 2011 23:48:26 -0000 Delivered-To: apmail-pig-dev-archive@pig.apache.org Received: (qmail 65151 invoked by uid 500); 6 Dec 2011 23:48:26 -0000 Mailing-List: contact dev-help@pig.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@pig.apache.org Delivered-To: mailing list dev@pig.apache.org Received: (qmail 65143 invoked by uid 99); 6 Dec 2011 23:48:26 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Dec 2011 23:48:26 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of russell.jurney@gmail.com designates 74.125.82.53 as permitted sender) Received: from [74.125.82.53] (HELO mail-ww0-f53.google.com) (74.125.82.53) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Dec 2011 23:48:21 +0000 Received: by wgbds1 with SMTP id ds1so6041008wgb.22 for ; Tue, 06 Dec 2011 15:47:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; bh=9VaXXrmmMsIAK3k2r99bjZWRQMvQC+/k0rgodSjcePA=; b=FtddjYwS1awkhAnseQ20RbWEgu6q/LO9eYm2jJ4Kb4vLguT+CVHezQPnEpUINApSfl GO8L4G2y/4dxnU8pr2BffrIe03VVtLvpkyyRQrzN5k4fxX/sJAHjb1NRuMJruKOkoXke k6ljYg/DLsgFW8sexCjOTonkV5e2Jyb4DbHA4= MIME-Version: 1.0 Received: by 10.216.133.197 with SMTP id q47mr76597wei.111.1323215278885; Tue, 06 Dec 2011 15:47:58 -0800 (PST) Received: by 10.216.39.9 with HTTP; Tue, 6 Dec 2011 15:47:58 -0800 (PST) Date: Tue, 6 Dec 2011 15:47:58 -0800 Message-ID: Subject: Wilbur, AvroStorage From: Russell Jurney To: dev@pig.apache.org Content-Type: multipart/alternative; boundary=00504502e1b3a8cb8604b3751034 --00504502e1b3a8cb8604b3751034 Content-Type: text/plain; charset=ISO-8859-1 I'm debugging the AvroStorage UDF in piggybank for this blog post: http://datasyndrome.com/post/13707537045/booting-the-analytics-application-events-ruby The script is: messages = LOAD '/tmp/messages.avro' USING AvroStorage(); user_groups = GROUP messages by user_id; per_user = FOREACH user_groups { sorted = ORDER messages BY message_id DESC; GENERATE group AS user_id, sorted AS messages; } DESCRIBE per_user > per_user: {user_id: int,messages: {(message_id: int,topic: chararray,user_id: int)}} STORE per_user INTO '/tmp/per_user.avro' USING AvroStorage(); The error is: Pig Stack Trace --------------- ERROR 1002: Unable to store alias per_user org.apache.pig.impl.logicalLayer.FrontendException: ERROR 1002: Unable to store alias per_user at org.apache.pig.PigServer$Graph.registerQuery(PigServer.java:1596) at org.apache.pig.PigServer.registerQuery(PigServer.java:584) at org.apache.pig.tools.grunt.GruntParser.processPig(GruntParser.java:942) at org.apache.pig.tools.pigscript.parser.PigScriptParser.parse(PigScriptParser.java:386) at org.apache.pig.tools.grunt.GruntParser.parseStopOnError(GruntParser.java:188) at org.apache.pig.tools.grunt.GruntParser.parseStopOnError(GruntParser.java:164) at org.apache.pig.tools.grunt.Grunt.run(Grunt.java:67) at org.apache.pig.Main.run(Main.java:487) at org.apache.pig.Main.main(Main.java:108) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.hadoop.util.RunJar.main(RunJar.java:156) Caused by: java.lang.NullPointerException at org.apache.pig.piggybank.storage.avro.AvroStorageUtils.isTupleWrapper(AvroStorageUtils.java:327) at org.apache.pig.piggybank.storage.avro.PigSchema2Avro.convert(PigSchema2Avro.java:82) at org.apache.pig.piggybank.storage.avro.PigSchema2Avro.convert(PigSchema2Avro.java:105) at org.apache.pig.piggybank.storage.avro.PigSchema2Avro.convertRecord(PigSchema2Avro.java:151) at org.apache.pig.piggybank.storage.avro.PigSchema2Avro.convert(PigSchema2Avro.java:62) at org.apache.pig.piggybank.storage.avro.AvroStorage.checkSchema(AvroStorage.java:502) at org.apache.pig.newplan.logical.rules.InputOutputFileValidator$InputOutputFileVisitor.visit(InputOutputFileValidator.java:65) at org.apache.pig.newplan.logical.relational.LOStore.accept(LOStore.java:77) at org.apache.pig.newplan.DepthFirstWalker.depthFirst(DepthFirstWalker.java:64) at org.apache.pig.newplan.DepthFirstWalker.depthFirst(DepthFirstWalker.java:66) at org.apache.pig.newplan.DepthFirstWalker.depthFirst(DepthFirstWalker.java:66) at org.apache.pig.newplan.DepthFirstWalker.depthFirst(DepthFirstWalker.java:66) at org.apache.pig.newplan.DepthFirstWalker.depthFirst(DepthFirstWalker.java:66) at org.apache.pig.newplan.DepthFirstWalker.walk(DepthFirstWalker.java:53) at org.apache.pig.newplan.PlanVisitor.visit(PlanVisitor.java:50) at org.apache.pig.newplan.logical.rules.InputOutputFileValidator.validate(InputOutputFileValidator.java:45) at org.apache.pig.backend.hadoop.executionengine.HExecutionEngine.compile(HExecutionEngine.java:292) at org.apache.pig.PigServer.compilePp(PigServer.java:1360) at org.apache.pig.PigServer.executeCompiledLogicalPlan(PigServer.java:1297) at org.apache.pig.PigServer.execute(PigServer.java:1286) at org.apache.pig.PigServer.access$400(PigServer.java:125) at org.apache.pig.PigServer$Graph.registerQuery(PigServer.java:1591) ... 13 more I need to fix this. Which means I need to commit a patch to get in the current piggybank? I've got some time... is it worthwhile to resurrect wilbur on github and move piggybank over? -- Russell Jurney twitter.com/rjurney russell.jurney@gmail.com datasyndrome.com --00504502e1b3a8cb8604b3751034--