You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Oliver Heger <ol...@oliver-heger.de> on 2012/03/01 22:03:32 UTC
[configuration] Replace DatabaseConfiguration with version from branch?
Hi,
the version of DatabaseConfiguration in the experimental branch strongly
differs from the trunk version. It uses a template approach for
executing JDBC operations thus avoiding the complex JDBC exception
handling plumbing code.
I prefer this style because IMHO it makes the implementations of the
operations clearer and more readable. So are there any objections
against replacing the trunk version?
Oliver
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org
Re: [configuration] Replace DatabaseConfiguration with version from
branch?
Posted by Oliver Heger <ol...@oliver-heger.de>.
Am 05.03.2012 18:14, schrieb Emmanuel Bourg:
> I reviewed the class on the branch, I'm probably biased but I found the
> original version easier to read despite the clever use of the
> JdbcOperation class to avoid code duplications. I also noticed that the
> internal classes increased the size of the code by a 2.5 factor in the
> final jar (+6K).
>
> This is not an objection, this class will have to be redesigned
> completely in the future to support caching anyway. So both
> implementations will probably be obsolete eventually.
With other words, there is not much point in changing this class now. I
don't have strong feelings about it.
I came up with this because of CONFIGURATION-483. Closing the result set
could be added to the JdbcOperation class, too. Otherwise, there would
be even more code duplication.
Oliver
>
> Emmanuel Bourg
>
>
>
> Le 01/03/2012 22:03, Oliver Heger a écrit :
>> Hi,
>>
>> the version of DatabaseConfiguration in the experimental branch strongly
>> differs from the trunk version. It uses a template approach for
>> executing JDBC operations thus avoiding the complex JDBC exception
>> handling plumbing code.
>>
>> I prefer this style because IMHO it makes the implementations of the
>> operations clearer and more readable. So are there any objections
>> against replacing the trunk version?
>>
>> Oliver
>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org
Re: [configuration] Replace DatabaseConfiguration with version from
branch?
Posted by Emmanuel Bourg <eb...@apache.org>.
I reviewed the class on the branch, I'm probably biased but I found the
original version easier to read despite the clever use of the
JdbcOperation class to avoid code duplications. I also noticed that the
internal classes increased the size of the code by a 2.5 factor in the
final jar (+6K).
This is not an objection, this class will have to be redesigned
completely in the future to support caching anyway. So both
implementations will probably be obsolete eventually.
Emmanuel Bourg
Le 01/03/2012 22:03, Oliver Heger a écrit :
> Hi,
>
> the version of DatabaseConfiguration in the experimental branch strongly
> differs from the trunk version. It uses a template approach for
> executing JDBC operations thus avoiding the complex JDBC exception
> handling plumbing code.
>
> I prefer this style because IMHO it makes the implementations of the
> operations clearer and more readable. So are there any objections
> against replacing the trunk version?
>
> Oliver