Hi Lars,

I found the problem. Because I install the HBase using hbase 0.20.2, while
in my client side I use HBase_trunk.

It seems  a compatible problem.


Jeff Zhang


On Wed, Nov 11, 2009 at 6:23 PM, Lars George <[email protected]> wrote:

> Hi Jeff,
>
> No, this message is always printed, i.e. "connection from and unkown user".
> It's a bit worrying but nevertheless what you will always see. What is not
> right of course is the NPE you get. I have never seen the client throwing an
> exception at that point. The code does not reveal much, seems like the
> "call" object is null - but why I do not know.
>
> Could you enable DEBUG level logging and try again? Maybe it is collateral
> damage?
>
> Lars
>
> Jeff Zhang schrieb:
>
>  Hi all,
>>
>> I meet a problem that I can not connect the HBase using Java API.
>>
>> The is my simple Java code:
>>
>> HBaseConfiguration conf=new HBaseConfiguration();
>>        HBaseAdmin admin=new HBaseAdmin(conf);
>>
>>        HTableDescriptor[] tables=admin.listTables();
>>        for (HTableDescriptor table:tables){
>>            System.out.println(Bytes.toString(table.getName()));
>> }
>>
>>
>> And I put the hbase-site in classpath.  Here is the message:
>>
>> Exception in thread "IPC Client (47) connection to /10.148.224.11:60020from
>> an unknown user" java.lang.NullPointerException
>>    at
>>
>> org.apache.hadoop.hbase.ipc.HBaseClient$Connection.receiveResponse(HBaseClient.java:518)
>>    at
>>
>> org.apache.hadoop.hbase.ipc.HBaseClient$Connection.run(HBaseClient.java:448)
>>
>>
>> But I debug the program and found the exception is happend at line  518 of
>> file HBaseClient (the bold line):
>>
>>        boolean isError = in.readBoolean();     // read if error
>>        if (isError) {
>>          call.setException(new RemoteException(
>> WritableUtils.readString(in),
>>              WritableUtils.readString(in)));
>>        } else {
>>          Writable value = ReflectionUtils.newInstance(valueClass, conf);
>>          value.readFields(in);                 // read value
>>        *  call.setValue(value);*
>>        }
>>
>> Is this a bug or does it need any extra configuration to tell the hbase
>> cluster who is the client ?
>>
>>
>> Jeff Zhang
>>
>>
>>
>

Reply via email to