[
https://issues.apache.org/jira/browse/PHOENIX-6834?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17639863#comment-17639863
]
Istvan Toth edited comment on PHOENIX-6834 at 11/28/22 8:38 AM:
----------------------------------------------------------------
I haven't added instrumentation, but I did a quick manual check to see if this
indeed works:
{noformat}
mvn clean verify -am -pl phoenix-core -Dit.test=UpsertSelectIT*
{noformat}
with the patch:
{noformat}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
63 693 14049
{noformat}
without the patch:
{noformat}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
78 858 17394
{noformat}
Then I patched testUpsertSelectRunOnServer() to run the upsert..select ten
times in a loop:
with the patch
{noformat}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
64 704 14272
{noformat}
without the patch:
{noformat}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
123 1353 27429{noformat}
was (Author: stoty):
I haven't added instrumentation, but I did a quick manual check to see if this
indeed works:
{code:java}
mvn clean verify -am -pl phoenix-core -Dit.test=UpsertSelectIT* {code}
with the patch:
{code:java}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
63 693 14049
{code}
without the patch:
{code:java}
grep "Initiating"
phoenix-core/target/failsafe-reports/org.apache.phoenix.end2end.UpsertSelectIT-output.txt
|wc
78 858 17394
{code}
> Use Pooled HConnection for Server Side Upsert Select
> ----------------------------------------------------
>
> Key: PHOENIX-6834
> URL: https://issues.apache.org/jira/browse/PHOENIX-6834
> Project: Phoenix
> Issue Type: Improvement
> Components: core
> Affects Versions: 5.2.0, 5.1.2
> Reporter: Istvan Toth
> Assignee: Istvan Toth
> Priority: Major
>
> We're creating a new HConnection every time we do a server side upsert select.
> We should be using QueryUtil.getConnectionOnServer() which provides pooling.
> Found by [~sergey.soldatov] .
--
This message was sent by Atlassian Jira
(v8.20.10#820010)