Re: phoenix query server connection properties

2015-10-01 Thread James Taylor
Hi Jan,

I just commented on the Calcite thread. Phoenix needs to know the
connection properties and for each subsequent RPC, needs to know from which
connection you came. Otherwise we wouldn't know your tenant ID when the
statement is run. Something like a connection or session ID would need to
be passed through each RPC (which would perhaps originally be
generated and returned
from the hypothetical createConnection RPC).

Thanks for bringing this up.

  BJames

On Thursday, October 1, 2015, Jan Van Besien  wrote:

> Hi,
>
> We are working on a calcite/avatica based "thin" JDBC driver very
> similar to what Phoenix has done with for its QueryServer, and I am
> looking for some feedback/options.
>
> Avatica in its current state doesn't have an RPC call for "create
> connection". As a consequence, connection properties (i.e. the
> Properties instance passed through the
> DriverManager.getConnection(url, props)) are currently not RPC-ed from
> the client to the server.
>
> For Phoenix, this means properties such as TenantId, CurrentSCN etc do
> not work with the thin driver. I saw this question being asked in
> PHOENIX-1824, so I am not sure whether you were aware of this problem.
> I've tested it with the phoenix sandbox on master with a multi-tenant
> table to be sure.
>
> There currently is a discussion ongoing on the calcite dev mailing
> list on this topic as well (with subject "avatica jdbc URL connection
> properties").
>
> Our understanding of the problem is that we need to extend the RPC
> with a "create connection", but this doesn't seem to be
> straightforward in the current Avatica design.
>
> It would be interesting to hear your thoughts on this subject.
>
> Thanks
> Jan
>


phoenix query server connection properties

2015-10-01 Thread Jan Van Besien
Hi,

We are working on a calcite/avatica based "thin" JDBC driver very
similar to what Phoenix has done with for its QueryServer, and I am
looking for some feedback/options.

Avatica in its current state doesn't have an RPC call for "create
connection". As a consequence, connection properties (i.e. the
Properties instance passed through the
DriverManager.getConnection(url, props)) are currently not RPC-ed from
the client to the server.

For Phoenix, this means properties such as TenantId, CurrentSCN etc do
not work with the thin driver. I saw this question being asked in
PHOENIX-1824, so I am not sure whether you were aware of this problem.
I've tested it with the phoenix sandbox on master with a multi-tenant
table to be sure.

There currently is a discussion ongoing on the calcite dev mailing
list on this topic as well (with subject "avatica jdbc URL connection
properties").

Our understanding of the problem is that we need to extend the RPC
with a "create connection", but this doesn't seem to be
straightforward in the current Avatica design.

It would be interesting to hear your thoughts on this subject.

Thanks
Jan