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

Switch to Plain View
Pig >> mail # user >> Unable to typecast fields loaded from HBase


+
Praveen Bysani 2013-03-27, 08:29
Copy link to this message
-
Re: Unable to typecast fields loaded from HBase
This is not about casting types. The scripts work sometime without any
issue and fails with the error as i specified before ? I have no clue of
what might be the issue ? Network probably ? I run my cluster on VPS
machines, running CDH 4.2 that is installed using cloudera Manager. I am
running pig version 0.10.1 which is installed as parcel.

On 27 March 2013 16:29, Praveen Bysani <[EMAIL PROTECTED]> wrote:

> Hi,
>
> I am unable to typecast fields loaded from my hbase to anything other than
> default bytearray. I tried both during the LOAD statement and using
> typecast after loading. Neither works. The script works when i load the
> data as below,
> records = LOAD 'hbase://hantu' USING
> org.apache.pig.backend.hadoop.hbase.HBaseStorage('v:member v:guest') as
> (member, guest);
> records_limit = LIMIT records 10;
> DUMP records_limit;
>
> But when i change the first line to ,
> records = LOAD 'hbase://hantu' USING
> org.apache.pig.backend.hadoop.hbase.HBaseStorage('v:member v:guest') as
> (member:chararray, guest:chararray);
>
> The pig script fails and the log is as below,
> Backend error message
> ---------------------
> Error: java.lang.ClassNotFoundException:
> org.apache.hadoop.hbase.mapreduce.TableInputFormat
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
>         at java.lang.ClassLoader.defineClass1(Native Method)
>         at java.lang.ClassLoader.defineClassCond(ClassLoader.java:632)
>         at java.lang.ClassLoader.defineClass(ClassLoader.java:616)
>         at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
>         at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
>         at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190
>
> Backend error message
> ---------------------
> Error: java.lang.ClassNotFoundException:
> org.apache.hadoop.hbase.mapreduce.TableInputFormat
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
>         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>         at java.lang.ClassLoader.defineClass1(Native Method)
>         at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
>         at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
>         at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
>         at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
>         at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190
>
> Error message from task (reduce) task_201303270642_0043_r_000000
> ----------------------------------------------------------------
> ERROR 6015: During execution, encountered a Hadoop error.
>
> org.apache.pig.backend.executionengine.ExecException: ERROR 6015: During
> execution, encountered a Hadoop error.
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:190)

Regards,
Praveen Bysani
http://www.praveenbysani.com
+
Bill Graham 2013-03-28, 04:54
+
Praveen Bysani 2013-03-28, 10:25
+
Bill Graham 2013-03-28, 14:48
+
Praveen Bysani 2013-04-01, 02:42