You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@phoenix.apache.org by alex kamil <al...@gmail.com> on 2014/03/09 06:26:47 UTC

how to clear statement cache

if I reuse PhoenixConnection to upsert a few million rows via
PreparedStatement the statements seem to be cached by the JDBC driver, and
it uses most of the available heap  until the client runs out of memory and
starts FullGC-ing to no avail
does phoenix JDBC driver allow to clear statement cache (as
clearStatementCache<http://docs.oracle.com/cd/E11035_01/wls100/jdbc_admin/manage.html#wp1048073>
in
webLogic)
I don't want to tear down and reestablish the connection on each upsert as
it would introduce latency

Thanks

Alex

how to clear statement cache

Posted by James Taylor <ja...@apache.org>.
Are you doing a statement.close() for each statement?

On Saturday, March 8, 2014, alex kamil
<alex.kamil@gmail.com<javascript:_e(%7B%7D,'cvml','alex.kamil@gmail.com');>>
wrote:

> if I reuse PhoenixConnection to upsert a few million rows via
> PreparedStatement the statements seem to be cached by the JDBC driver, and
> it uses most of the available heap  until the client runs out of memory and
> starts FullGC-ing to no avail
> does phoenix JDBC driver allow to clear statement cache (as
> clearStatementCache<http://docs.oracle.com/cd/E11035_01/wls100/jdbc_admin/manage.html#wp1048073> in
> webLogic)
> I don't want to tear down and reestablish the connection on each upsert as
> it would introduce latency
>
> Thanks
>
> Alex
>