hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ted Yu <yuzhih...@gmail.com>
Subject Re: Batch method
Date Wed, 02 Oct 2013 23:51:54 GMT
You can take a look at HConnectionManager#processBatchCallback(), starting
line 1774 (0.94 branch).
Here is the relevant code:

      if (!exceptions.isEmpty()) {

        throw new RetriesExhaustedWithDetailsException(exceptions,

            actions,

            addresses);

      }

You should be able to extract failure information from
RetriesExhaustedWithDetailsException thrown.


Cheers


On Wed, Oct 2, 2013 at 4:15 PM, Renato Marroquín Mogrovejo <
renatoj.marroquin@gmail.com> wrote:

> Yeah, I am using such method, but if I get a null in the Objects array, how
> do I know which operation failed?
>
>
> 2013/10/2 Ted Yu <yuzhihong@gmail.com>
>
> > How about this method ?
> >
> >
> http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/client/HTable.html#batch(java.util.List
> > ,
> > java.lang.Object[])
> >
> >
> > On Wed, Oct 2, 2013 at 3:57 PM, Renato Marroquín Mogrovejo <
> > renatoj.marroquin@gmail.com> wrote:
> >
> > > Hi Ted,
> > >
> > > Thank you very much for answering! But I don't think HBASE-8112 is
> > related
> > > to my question. I saw that the signature of the method changed in order
> > to
> > > retrieve partial results. I am using HBase 0.94.10 so does this version
> > > will work like this?
> > > And anyway, my problem is to determine which operation failed within a
> > > batch of operations. Is this possible?
> > >
> > >
> > > Renato M.
> > >
> > >
> > > 2013/10/2 Ted Yu <yuzhihong@gmail.com>
> > >
> > > > Looks like this is related:
> > > > HBASE-8112 Deprecate HTable#batch(final List<? extends Row>)
> > > >
> > > >
> > > > On Wed, Oct 2, 2013 at 3:35 PM, Renato Marroquín Mogrovejo <
> > > > renatoj.marroquin@gmail.com> wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > I am using the batch method[1] and it states that I will get an
> array
> > > of
> > > > > objects containing possibly null values. So my question is if there
> > is
> > > a
> > > > > way on knowing which operation was the one that failed from this
> null
> > > > > value? Or any other way in which I could check for the failing
> > > operation?
> > > > > Thanks in advance.
> > > > >
> > > > >
> > > > > Renato M.
> > > > >
> > > > > [1]
> > > > >
> > > > >
> > > >
> > >
> >
> http://hbase.apache.org/apidocs/org/apache/hadoop/hbase/client/HTable.html#batch(java.util.List)
> > > > >
> > > >
> > >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message