You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@phoenix.apache.org by Kevin Minder <km...@gmail.com> on 2018/05/21 22:39:44 UTC

Decrease HTTP chattiness?

It is possible to decrease the chattiness of the Phoenix JDBC driver
operating in HTTP mode?
We've tried using stmt.setFetchSize() but this appears to be ignored.
As it stands new we appear to be getting about 100 rows per POST which
presents a number of throughput issues when the results can be 100,000 rows.

Re: Decrease HTTP chattiness?

Posted by Josh Elser <el...@apache.org>.
Yeah, as Francis says, this should already be exposed via the expected 
JDBC APIs.

Kevin -- can you share more details about what version(s) you're 
running? A sample program?

If you're running a new enough version, you can set the following log 
level via Log4j

org.apache.calcite.avatica.remote.ProtobufTranslationImpl=TRACE

which will give you a client-side dump of all of the "RPC data" being 
sent and received. This will help you see the frame_max_size that 
Francis alluded to :)

On 5/21/18 6:55 PM, Francis Chuang wrote:
> I am not familiar with the JDBC driver, but Phoenix uses Avatica[1] 
> under the hood. The protobuf documentation does state that it's possible 
> to control the number of rows returned in each response. See 
> frame_max_size under the FetchRequest[2] message. This may be something 
> that you can set in the JDBC driver.
> 
> Francis
> 
> [1] https://calcite.apache.org/avatica
> [2] 
> https://calcite.apache.org/avatica/docs/protobuf_reference.html#fetchrequest 
> 
> 
> On 22/05/2018 8:39 AM, Kevin Minder wrote:
>> It is possible to decrease the chattiness of the Phoenix JDBC driver 
>> operating in HTTP mode?
>> We've tried using stmt.setFetchSize() but this appears to be ignored.
>> As it stands new we appear to be getting about 100 rows per POST which 
>> presents a number of throughput issues when the results can be 100,000 
>> rows.
> 
> 

Re: Decrease HTTP chattiness?

Posted by Francis Chuang <fr...@apache.org>.
I am not familiar with the JDBC driver, but Phoenix uses Avatica[1] 
under the hood. The protobuf documentation does state that it's possible 
to control the number of rows returned in each response. See 
frame_max_size under the FetchRequest[2] message. This may be something 
that you can set in the JDBC driver.

Francis

[1] https://calcite.apache.org/avatica
[2] 
https://calcite.apache.org/avatica/docs/protobuf_reference.html#fetchrequest

On 22/05/2018 8:39 AM, Kevin Minder wrote:
> It is possible to decrease the chattiness of the Phoenix JDBC driver 
> operating in HTTP mode?
> We've tried using stmt.setFetchSize() but this appears to be ignored.
> As it stands new we appear to be getting about 100 rows per POST which 
> presents a number of throughput issues when the results can be 100,000 
> rows.