You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hbase.apache.org by Sznajder ForMailingList <bs...@gmail.com> on 2014/10/27 15:03:57 UTC

Connection via API to Hbase installation - java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils

Hi

I want to connect from my windows laptop to an installed HBASE

When running the code , I get the following error:

java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils
    at org.apache.hadoop.hbase.HConstants.<clinit>(HConstants.java:907)
    at
org.apache.hadoop.hbase.client.HConnectionKey.<clinit>(HConnectionKey.java:42)
    at
org.apache.hadoop.hbase.client.HConnectionManager.getConnection(HConnectionManager.java:265)
    at org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:192)


However, I added to the classpath the jar commons-lang3-3.3.2

Regards
Benjamin

Re: Connection via API to Hbase installation - java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils

Posted by Sean Busbey <bu...@cloudera.com>.
Hi Benjamin,

This is expected behavior. Commons Lang 3 is not backwards compatible with
Commons Lang 2.x. They use different java packages in an effort to ease
projects that have to rely on both while transitioning.

-Sean


On Mon, Oct 27, 2014 at 9:50 AM, Sznajder ForMailingList <
bs4mailinglist@gmail.com> wrote:

> Many thanks!
>
> Strangely, when adding commons-lang 3.2, it failed.
> Adding back the 2.6 it worked!
>
>
>
> On Mon, Oct 27, 2014 at 4:10 PM, Ted Yu <yu...@gmail.com> wrote:
>
> > Which release of HBase are you using ?
> > If 0.98.x, here is the dependency on commons-lang:
> >     <commons-lang.version>2.6</commons-lang.version>
> >
> > Cheers
> >
> > On Mon, Oct 27, 2014 at 7:03 AM, Sznajder ForMailingList <
> > bs4mailinglist@gmail.com> wrote:
> >
> > > Hi
> > >
> > > I want to connect from my windows laptop to an installed HBASE
> > >
> > > When running the code , I get the following error:
> > >
> > > java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils
> > >     at org.apache.hadoop.hbase.HConstants.<clinit>(HConstants.java:907)
> > >     at
> > >
> > >
> >
> org.apache.hadoop.hbase.client.HConnectionKey.<clinit>(HConnectionKey.java:42)
> > >     at
> > >
> > >
> >
> org.apache.hadoop.hbase.client.HConnectionManager.getConnection(HConnectionManager.java:265)
> > >     at
> > > org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:192)
> > >
> > >
> > > However, I added to the classpath the jar commons-lang3-3.3.2
> > >
> > > Regards
> > > Benjamin
> > >
> >
>



-- 
Sean

Re: Connection via API to Hbase installation - java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils

Posted by Sznajder ForMailingList <bs...@gmail.com>.
Many thanks!

Strangely, when adding commons-lang 3.2, it failed.
Adding back the 2.6 it worked!



On Mon, Oct 27, 2014 at 4:10 PM, Ted Yu <yu...@gmail.com> wrote:

> Which release of HBase are you using ?
> If 0.98.x, here is the dependency on commons-lang:
>     <commons-lang.version>2.6</commons-lang.version>
>
> Cheers
>
> On Mon, Oct 27, 2014 at 7:03 AM, Sznajder ForMailingList <
> bs4mailinglist@gmail.com> wrote:
>
> > Hi
> >
> > I want to connect from my windows laptop to an installed HBASE
> >
> > When running the code , I get the following error:
> >
> > java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils
> >     at org.apache.hadoop.hbase.HConstants.<clinit>(HConstants.java:907)
> >     at
> >
> >
> org.apache.hadoop.hbase.client.HConnectionKey.<clinit>(HConnectionKey.java:42)
> >     at
> >
> >
> org.apache.hadoop.hbase.client.HConnectionManager.getConnection(HConnectionManager.java:265)
> >     at
> > org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:192)
> >
> >
> > However, I added to the classpath the jar commons-lang3-3.3.2
> >
> > Regards
> > Benjamin
> >
>

Re: Connection via API to Hbase installation - java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils

Posted by Ted Yu <yu...@gmail.com>.
Which release of HBase are you using ?
If 0.98.x, here is the dependency on commons-lang:
    <commons-lang.version>2.6</commons-lang.version>

Cheers

On Mon, Oct 27, 2014 at 7:03 AM, Sznajder ForMailingList <
bs4mailinglist@gmail.com> wrote:

> Hi
>
> I want to connect from my windows laptop to an installed HBASE
>
> When running the code , I get the following error:
>
> java.lang.NoClassDefFoundError: org/apache/commons/lang/ArrayUtils
>     at org.apache.hadoop.hbase.HConstants.<clinit>(HConstants.java:907)
>     at
>
> org.apache.hadoop.hbase.client.HConnectionKey.<clinit>(HConnectionKey.java:42)
>     at
>
> org.apache.hadoop.hbase.client.HConnectionManager.getConnection(HConnectionManager.java:265)
>     at
> org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:192)
>
>
> However, I added to the classpath the jar commons-lang3-3.3.2
>
> Regards
> Benjamin
>