hbase-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ted Yu <yuzhih...@gmail.com>
Subject Re: How to manage HConnection instances in long running applications?
Date Thu, 16 Jan 2014 16:55:57 GMT
Miljan:
Please take a look at:
http://hbase.apache.org/book.html#client.connections


On Thu, Jan 16, 2014 at 7:57 AM, Jean-Marc Spaggiari <
jean-marc@spaggiari.org> wrote:

> Hi Miljan,
>
> Why do you want to keep the HConnection if you spend days not using it? Why
> not just get a connection when you need it? Any reason?
>
> JM
>
>
> 2014/1/16 Miljan Markovic <miljan.markovic@yoterra.com>
>
> > Hi everybody,
> >
> > I have an application that runs constantly as a service and ocassionaly
> > talks to hbase. It can have very long periods (day or two) when it
> doesn't
> > talk to hbase at all.
> >
> > What would be the best way to make sure that my application components
> have
> > active and available HConnection instance to use in this case? Resource
> > consumption is not a problem if HConnection iself doesn't accumulate
> > resources by just sitting idle... My main concern is what happens if
> > connection to hbase gets lost, or server closes the connection as idle.
> >
> > Do I have to manually reinitialize the connection in this case, or does
> > HConnection itself have a reconnect mechanism? Also, how do I detect
> those
> > conditions in runtime so I can react to them if I need to?
> >
> > Thanks
> >
>

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