if all threads share same HConnection, it may
> has limitation to support high throughput, so a pool of Connections maybe
> better?
>
> Thanks,
> Ming
>
> -Original Message-
> From: Serega Sheypak [mailto:serega.shey...@gmail.com ]
> Sent: Wednesday, February 04,
: user
Subject: Re: managing HConnection
Hi, guys from group helped me a lot. I did solve pretty the same problem (CRUD
web-app)
1. Use single instance of HConnection per application.
2. Instantiate it once.
3. create HTable instance for each CRUD operation and safely close it
(try-catch-finally
In your scene, per servlet used a HConnecton object, so the response for 5
rpm is so easy.
If these servlets should share the only one HConnecton object, whether or not
the response latency for 5 rpm would increase?
Newrelic shows 50K RPM
each request to servlet == 1-3 put/get to HBase. I have mixed workload.
Is it strange :) ?
2015-02-16 10:37 GMT+03:00 David chen :
> 5 rpm? I am curious how the result is concluded?
It can. 5 rpm, no problem.
понедельник, 16 февраля 2015 г. пользователь David chen написал:
> Sorry for the unclear represent.
> My problem is that whether or not a sharing Honnection can bear too many
> query requests?
Sorry for the unclear represent.
My problem is that whether or not a sharing Honnection can bear too many query
requests?
That's true, we can share the connection, but the problem is, HConnection
implements Closeable, and hence its close method is public. If you share
the same connection in your api, you always have to check if the current
connection is closed before you return it to the client, check previous
emails
I don't understand you.
There is a single instance of servlet per application.
Servlet.init method called once. Here you can instantiate HConnection and
solve ANY concurrency problems. HConnection is tread-safe. Just don't close
it and reuse.
Then just use HConnection to get HTable.
What problem y
If sharing one HConnection for the whole application, when concurrency to
access servlets increases to a threshold, whether or not it will influence the
application performance? But if increasing the sharing HConnection number, the
problem will be relieved?
What's the problem to call HConnectionManager.getConnection in Servlet.init
method and pass it to your class responsible for HBase interaction?
2015-02-13 14:49 GMT+03:00 Sleiman Jneidi :
> a single HConnection
>
> On Fri, Feb 13, 2015 at 11:12 AM, Serega Sheypak >
> wrote:
>
> > What are you t
a single HConnection
On Fri, Feb 13, 2015 at 11:12 AM, Serega Sheypak
wrote:
> What are you trying to achieve?
>
> 2015-02-13 12:36 GMT+03:00 Sleiman Jneidi :
>
> > To be honest guys I am still confused, especially that that HConnection
> > implements Closeable and hence everyone has the right
What are you trying to achieve?
2015-02-13 12:36 GMT+03:00 Sleiman Jneidi :
> To be honest guys I am still confused, especially that that HConnection
> implements Closeable and hence everyone has the right to close the
> connection. I wrote this code to manage connections but I am not sure about
To be honest guys I am still confused, especially that that HConnection
implements Closeable and hence everyone has the right to close the
connection. I wrote this code to manage connections but I am not sure about
its correctness.
private static class HConnectionProvider {
private static HCo
Hi, really, I can share one Hconnection for the whole application.
It's done by design. I have several servlets. Each servlet has 1-2
controllers working with hbase internally (put/get/e.t.c)
Right now I don't see any reason to refactor code and share single
HConnection for all controllers in servl
Hi, guys from group helped me a lot. I did solve pretty the same problem
(CRUD web-app)
1. Use single instance of HConnection per application.
2. Instantiate it once.
3. create HTable instance for each CRUD operation and safely close it
(try-catch-finally). Use the same HConnection to create any H
Please see '61.1. Cluster Connections' under
http://hbase.apache.org/book.html#architecture.client
Cheers
On Tue, Feb 3, 2015 at 6:47 AM, sleimanjneidi
wrote:
> Hi all,
> I am using hbase-0.98.1-cdh5.1.4 client and I am a bit confused by the
> documentation of HConnection. The document says the
16 matches
Mail list logo