Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Plain View
Pig >> mail # user >> PIG UDFs for parsing UserAgents


+
Niels Basjes 2013-04-20, 22:09
+
Prashant Kommireddi 2013-04-20, 22:29
Copy link to this message
-
Re: PIG UDFs for parsing UserAgents
Thanks Prashant, I'll have a look.
On Sun, Apr 21, 2013 at 12:29 AM, Prashant Kommireddi
<[EMAIL PROTECTED]>wrote:

> Hi Niels,
>
> To write unit tests you could take a look at TestBuiltin.java which has a
> tests for several UDFs -
>
> http://svn.apache.org/viewvc/pig/trunk/test/org/apache/pig/test/TestBuiltin.java
>
> Also, you can mock up input/ouput data using
>
> http://pig.apache.org/docs/r0.11.1/api/org/apache/pig/builtin/mock/Storage.html
> .
>
>
>
> On Sat, Apr 20, 2013 at 3:09 PM, Niels Basjes <[EMAIL PROTECTED]> wrote:
>
> > Hi,
> >
> > I created an addition to the ua-parser project (
> > https://github.com/tobie/ua-parser ) so that the methods for parsing a
> > useragent can be called as a UDF from Pig.
> >
> > https://github.com/nielsbasjes/ua-parser/tree/PIGSupport/pig
> >
> > One of the things I'm a bit worried about is that I have no idea on how
> to
> > create a junit test for this.
> > So I would really appreciate it if someone from the pig community could
> > have a look at it before I submit a pull request.
> >
> > Thanks.
> >
> > --
> > Best regards / Met vriendelijke groeten,
> >
> > Niels Basjes
> >
>

--
Best regards / Met vriendelijke groeten,

Niels Basjes