Subject | Re: [Firebird-Java] Memory buildup |
---|---|
Author | Roman Rokytskyy |
Post date | 2004-10-26T13:27:55Z |
> We have found an explanation for the memory buildup.Yes, Statement.close() and even ResultSet.close() will help. This behavior
>
> First. It was not (only) the updates, but ordinary selects that made
> the buildup.
>
> The problem is that all statements get saved in
> "isc_tr_handle_impl.stmts" on "executeQuery()".
>
> This is done using
> "isc_tr_handle_impl.registerStatementWithTransaction(isc_stmt_handle
> stmt)".
>
> They all get released doing commit using
> "isc_tr_handle_impl.forgetResultSets()".
>
> I guess Statement.close() should clean itself from the list ?
is correct - result sets are automatically closed either on commit (feature
of Firebird) or when Statement is closed (JDBC specification). If you do not
do this, it will eat some system resources.
Please send a confirmation of this behavior to the list.
Roman